Auto sync2gitlab import of procps-ng-3.3.15-8.el8.src.rpm

This commit is contained in:
CentOS Sources 2022-08-02 20:12:55 +00:00
parent a19bb6b583
commit f44aed6bd6
3 changed files with 252 additions and 1 deletions

View File

@ -0,0 +1,96 @@
diff -up ./NEWS.ori ./NEWS
diff -up ./sysctl.8.ori ./sysctl.8
--- ./sysctl.8.ori 2018-03-03 07:59:18.064843718 +0100
+++ ./sysctl.8 2022-07-29 16:33:02.906648974 +0200
@@ -6,7 +6,7 @@
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
.\" GNU General Public License for more details."
-.TH SYSCTL "8" "2018-02-19" "procps-ng" "System Administration"
+.TH SYSCTL "8" "2020-02-27" "procps-ng" "System Administration"
.SH NAME
sysctl \- configure kernel parameters at runtime
.SH SYNOPSIS
@@ -81,10 +81,10 @@ directories in the following list in giv
Once a file of a given filename is loaded, any file of the same name
in subsequent directories is ignored.
.br
-/run/sysctl.d/*.conf
-.br
/etc/sysctl.d/*.conf
.br
+/run/sysctl.d/*.conf
+.br
/usr/local/lib/sysctl.d/*.conf
.br
/usr/lib/sysctl.d/*.conf
@@ -152,6 +152,16 @@ echo 256 > /proc/sys/net/ipv6/neigh/eth0
.SH FILES
.I /proc/sys
.br
+.I /etc/sysctl.d/*.conf
+.br
+.I /run/sysctl.d/*.conf
+.br
+.I /usr/local/lib/sysctl.d/*.conf
+.br
+.I /usr/lib/sysctl.d/*.conf
+.br
+.I /lib/sysctl.d/*.conf
+.br
.I /etc/sysctl.conf
.SH SEE ALSO
.BR sysctl.conf (5)
diff -up ./sysctl.conf.5.ori ./sysctl.conf.5
--- ./sysctl.conf.5.ori 2017-12-22 05:13:14.771653252 +0100
+++ ./sysctl.conf.5 2022-07-29 16:33:02.907648980 +0200
@@ -51,22 +51,22 @@ to list all possible parameters. The des
.RE
.PP
.SH FILES
-.TP
-/run/sysctl.d/*.conf
-.TQ
-/etc/sysctl.d/*.conf
-.TQ
-/usr/local/lib/sysctl.d/*.conf
-.TQ
-/usr/lib/sysctl.d/*.conf
-.TQ
-/lib/sysctl.d/*.conf
-.TQ
-/etc/sysctl.conf
+.I /etc/sysctl.d/*.conf
+.br
+.I /run/sysctl.d/*.conf
+.br
+.I /usr/local/lib/sysctl.d/*.conf
+.br
+.I /usr/lib/sysctl.d/*.conf
+.br
+.I /lib/sysctl.d/*.conf
+.br
+.I /etc/sysctl.conf
+
The paths where
-sysctl
+.B sysctl
preload files usually exist. See also
-sysctl
+.B sysctl
option
.IR \-\-system .
.SH SEE ALSO
diff -up ./sysctl.c.ori ./sysctl.c
--- ./sysctl.c.ori 2018-05-17 13:23:41.574213737 +0200
+++ ./sysctl.c 2022-07-29 16:33:02.907648980 +0200
@@ -614,8 +614,8 @@ static int PreloadSystem(void)
{
unsigned di, i;
const char *dirs[] = {
- "/run/sysctl.d",
"/etc/sysctl.d",
+ "/run/sysctl.d",
"/usr/local/lib/sysctl.d",
"/usr/lib/sysctl.d",
"/lib/sysctl.d",

View File

@ -0,0 +1,147 @@
diff --git a/vmstat.8 b/vmstat.8
index fa0938c..fd1078f 100644
--- a/vmstat.8
+++ b/vmstat.8
@@ -87,6 +87,9 @@ Display version information and exit.
.TP
\fB\-h\fR, \fB\-\-help\fR
Display help and exit.
+.TP
+\fB\-y\fR, \fB\-\-no-first\fR
+Omits first report with statistics since system boot.
.PD
.SH "FIELD DESCRIPTION FOR VM MODE"
.SS
diff --git a/vmstat.c b/vmstat.c
index f2aa2f4..07496cd 100644
--- a/vmstat.c
+++ b/vmstat.c
@@ -75,6 +75,9 @@ static int a_option;
/* "-w" means "wide output" */
static int w_option;
+/* "-y" means "skip first output" */
+static int y_option;
+
/* "-t" means "show timestamp" */
static int t_option;
@@ -104,6 +107,7 @@ static void __attribute__ ((__noreturn__))
fputs(_(" -S, --unit <char> define display unit\n"), out);
fputs(_(" -w, --wide wide output\n"), out);
fputs(_(" -t, --timestamp show timestamp\n"), out);
+ fputs(_(" -y, --no-first skips first line of output\n"), out);
fputs(USAGE_SEPARATOR, out);
fputs(USAGE_HELP, out);
fputs(USAGE_VERSION, out);
@@ -304,43 +308,47 @@ static void new_format(void)
cpu_zzz, pgpgin, pgpgout, pswpin, pswpout, intr, ctxt, &running,
&blocked, &dummy_1, &dummy_2);
- if (t_option) {
- (void) time( &the_time );
- tm_ptr = localtime( &the_time );
- strftime(timebuf, sizeof(timebuf), "%Y-%m-%d %H:%M:%S", tm_ptr);
- }
+ if (y_option == 0) {
+ if (t_option) {
+ (void) time( &the_time );
+ tm_ptr = localtime( &the_time );
+ strftime(timebuf, sizeof(timebuf), "%Y-%m-%d %H:%M:%S", tm_ptr);
+ }
- duse = *cpu_use + *cpu_nic;
- dsys = *cpu_sys + *cpu_xxx + *cpu_yyy;
- didl = *cpu_idl;
- diow = *cpu_iow;
- dstl = *cpu_zzz;
- Div = duse + dsys + didl + diow + dstl;
- if (!Div) Div = 1, didl = 1;
- divo2 = Div / 2UL;
- printf(w_option ? wide_format : format,
- running, blocked,
- unitConvert(kb_swap_used), unitConvert(kb_main_free),
- unitConvert(a_option?kb_inactive:kb_main_buffers),
- unitConvert(a_option?kb_active:kb_main_cached),
- (unsigned)( (unitConvert(*pswpin * kb_per_page) * hz + divo2) / Div ),
- (unsigned)( (unitConvert(*pswpout * kb_per_page) * hz + divo2) / Div ),
- (unsigned)( (*pgpgin * hz + divo2) / Div ),
- (unsigned)( (*pgpgout * hz + divo2) / Div ),
- (unsigned)( (*intr * hz + divo2) / Div ),
- (unsigned)( (*ctxt * hz + divo2) / Div ),
- (unsigned)( (100*duse + divo2) / Div ),
- (unsigned)( (100*dsys + divo2) / Div ),
- (unsigned)( (100*didl + divo2) / Div ),
- (unsigned)( (100*diow + divo2) / Div ),
- (unsigned)( (100*dstl + divo2) / Div )
- );
+ duse = *cpu_use + *cpu_nic;
+ dsys = *cpu_sys + *cpu_xxx + *cpu_yyy;
+ didl = *cpu_idl;
+ diow = *cpu_iow;
+ dstl = *cpu_zzz;
+ Div = duse + dsys + didl + diow + dstl;
+ if (!Div) Div = 1, didl = 1;
+ divo2 = Div / 2UL;
+ printf(w_option ? wide_format : format,
+ running, blocked,
+ unitConvert(kb_swap_used), unitConvert(kb_main_free),
+ unitConvert(a_option?kb_inactive:kb_main_buffers),
+ unitConvert(a_option?kb_active:kb_main_cached),
+ (unsigned)( (unitConvert(*pswpin * kb_per_page) * hz + divo2) / Div ),
+ (unsigned)( (unitConvert(*pswpout * kb_per_page) * hz + divo2) / Div ),
+ (unsigned)( (*pgpgin * hz + divo2) / Div ),
+ (unsigned)( (*pgpgout * hz + divo2) / Div ),
+ (unsigned)( (*intr * hz + divo2) / Div ),
+ (unsigned)( (*ctxt * hz + divo2) / Div ),
+ (unsigned)( (100*duse + divo2) / Div ),
+ (unsigned)( (100*dsys + divo2) / Div ),
+ (unsigned)( (100*didl + divo2) / Div ),
+ (unsigned)( (100*diow + divo2) / Div ),
+ (unsigned)( (100*dstl + divo2) / Div )
+ );
- if (t_option) {
- printf(" %s", timebuf);
- }
+ if (t_option) {
+ printf(" %s", timebuf);
+ }
- printf("\n");
+ printf("\n");
+ }
+ else
+ num_updates++;
/* main loop */
for (i = 1; infinite_updates || i < num_updates; i++) {
@@ -865,6 +873,7 @@ int main(int argc, char *argv[])
{"timestamp", no_argument, NULL, 't'},
{"help", no_argument, NULL, 'h'},
{"version", no_argument, NULL, 'V'},
+ {"no-first", no_argument, NULL, 'y'},
{NULL, 0, NULL, 0}
};
@@ -877,7 +886,7 @@ int main(int argc, char *argv[])
atexit(close_stdout);
while ((c =
- getopt_long(argc, argv, "afmnsdDp:S:wthV", longopts,
+ getopt_long(argc, argv, "afmnsdDp:S:wthVy", longopts,
NULL)) != EOF)
switch (c) {
case 'V':
@@ -946,6 +955,11 @@ int main(int argc, char *argv[])
case 't':
t_option = 1;
break;
+ case 'y':
+ /* Don't display stats since system restart */
+ y_option = 1;
+ break;
+
default:
/* no other aguments defined yet. */
usage(stderr);

View File

@ -4,7 +4,7 @@
Summary: System and process monitoring utilities Summary: System and process monitoring utilities
Name: procps-ng Name: procps-ng
Version: 3.3.15 Version: 3.3.15
Release: 7%{?dist} Release: 8%{?dist}
License: GPL+ and GPLv2 and GPLv2+ and GPLv3+ and LGPLv2+ License: GPL+ and GPLv2 and GPLv2+ and GPLv3+ and LGPLv2+
Group: Applications/System Group: Applications/System
URL: https://sourceforge.net/projects/procps-ng/ URL: https://sourceforge.net/projects/procps-ng/
@ -22,6 +22,8 @@ Patch3: procps-ng-3.3.15-vmstat-watch-manpage.patch
Patch4: procps-ng-3.3.15-pidof-kernel-workers-option.patch Patch4: procps-ng-3.3.15-pidof-kernel-workers-option.patch
Patch5: procps-ng-3.3.15-pidof-separator-option-backport.patch Patch5: procps-ng-3.3.15-pidof-separator-option-backport.patch
Patch6: procps-ng-3.3.15-uptime-pretty-mod.patch Patch6: procps-ng-3.3.15-uptime-pretty-mod.patch
Patch7: procps-ng-3.3.15-vmstat-omit-first-report.patch
Patch8: procps-ng-3.3.15-sysctl-config-dir-order.patch
BuildRequires: ncurses-devel BuildRequires: ncurses-devel
BuildRequires: libtool BuildRequires: libtool
@ -164,6 +166,12 @@ ln -s %{_bindir}/pidof %{buildroot}%{_sbindir}/pidof
%files i18n -f %{name}.lang %files i18n -f %{name}.lang
%changelog %changelog
* Wed Jul 20 2022 Jan Rybar <jrybar@redhat.com> - 3.3.15-8
- vmstat: added -y option to omit first report
- Resolves: rhbz#2027350
- sysctl: backport config directory order, align with systemd
- Resolves: rhbz#2111915
* Wed Mar 23 2022 Jan Rybar <jrybar@redhat.com> - 3.3.15-7 * Wed Mar 23 2022 Jan Rybar <jrybar@redhat.com> - 3.3.15-7
- uptime: human readable data not shown if 364 days up - uptime: human readable data not shown if 364 days up
- Resolves: rhbz#1772999 - Resolves: rhbz#1772999