procps/procps-v3.3.3-read-sysctls-also-from-boot-sysctl.conf-kernelversion.diff

52 lines
1.2 KiB
Diff
Raw Permalink Normal View History

Accepting request 418010 from Base:System - Avoid fillup and insserv on modern systems (bsc#992845) - Use test suite but avoid the w command due dummy utmp * This requires dejagnu for the runtest command * This requires screen to be able to provide a tty - Add patch procps-ng-3.3.12-strtod.patch to fix missed extern declaration of strtod_nol_or_err() - Update to procps-ng-3.3.12 * libprocps API 6:0:0 * build: formerly optional --enable-oomem unconditional * free: man document rewritten for shared Debian #755233 * free: interpret intervals in non-locale way Debian #692113 * kill: report error if cannot kill process Debian #733172 * library: refine calculation of 'cached' memory * library: find tty quicker Debian #770215 * library: eliminate threads display inconsistencies Redhat #1284091 * pidof: check cmd if space found in argv0 * pmap: fixed detail parsing on long mapping lines * pmap: fix occasional incorrect memory usage values Redhat #1262864 * ps: sort by cgroup Debian #692279 * ps: display control group name with -o cgname * ps: fallback to attr/current for context Debian #786956 * ps: enabled broken 'thcount' option Redhat #1174313 * tests: conditionally add prctl Debian #816237 * top: displays the 3 new linux-4.5 RES memory fields * top: man page memory fields corrected + new narrative * top: added display of CGNAME (control group name) * top: is now more responsive to cpus brought online * top: namespace cols use suppressible zero OBS-URL: https://build.opensuse.org/request/show/418010 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/procps?expand=0&rev=99
2016-08-18 09:15:06 +02:00
---
sysctl.8 | 2 ++
sysctl.c | 12 ++++++++++++
2 files changed, 14 insertions(+)
--- sysctl.8
+++ sysctl.8 2021-02-10 10:05:27.781748090 +0000
@@ -81,6 +81,8 @@ 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
+/boot/sysctl.conf-<kernelversion>
+.br
/etc/sysctl.d/*.conf
Accepting request 871141 from Base:System - Add /usr/share/man/uk dir to file list for lang sub package - Fix directory for Ukrainian man pages translations. - Move localized man pages to lang package. - Remove obsolete conditionals. - Remove obsolete --enable-oomem option. - Run spec-cleaner. - Update to procps-ng-3.3.17 * library: Incremented to 8:3:0 (no removals or additions, internal changes only) * all: properly handle utf8 cmdline translations issue #176 * kill: Pass int to signalled process merge #32 * pgrep: Pass int to signalled process merge #32 * pgrep: Check sanity of SG_ARG_MAX issue #152 * pgrep: Add older than selection merge #79 * pidof: Quiet mode merge #83 * pidof: show worker threads Redhat #1803640 * ps.1: Mention stime alias issue #164 * ps: check also match on truncated 16 char comm names * ps: Add exe output option Redhat #1399206 * ps: A lot more sorting available merge #99 * pwait: New command waits for a process merge #97 * sysctl: Match systemd directory order Debian #950788 * sysctl: Document directory order Debian #951550 * top: ensure config file backward compatibility Debian #951335 * top: add command line 'e' for symmetry with 'E' issue #165 * top: add '4' toggle for two abreast cpu display issue #172 * top: add '!' toggle for combining multiple cpus * top: fix potential SEGV involving -p switch merge #114 OBS-URL: https://build.opensuse.org/request/show/871141 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/procps?expand=0&rev=119
2021-02-16 22:36:06 +01:00
.br
/run/sysctl.d/*.conf
--- sysctl.c
+++ sysctl.c 2021-02-10 10:04:25.290952318 +0000
@@ -39,6 +39,7 @@
#include <string.h>
#include <sys/stat.h>
#include <sys/types.h>
+#include <sys/utsname.h>
#include <unistd.h>
#include "c.h"
@@ -621,6 +622,7 @@ static int sortpairs(const void *A, cons
static int PreloadSystem(void)
{
unsigned di, i;
+ struct utsname uts;
const char *dirs[] = {
"/etc/sysctl.d",
Accepting request 871141 from Base:System - Add /usr/share/man/uk dir to file list for lang sub package - Fix directory for Ukrainian man pages translations. - Move localized man pages to lang package. - Remove obsolete conditionals. - Remove obsolete --enable-oomem option. - Run spec-cleaner. - Update to procps-ng-3.3.17 * library: Incremented to 8:3:0 (no removals or additions, internal changes only) * all: properly handle utf8 cmdline translations issue #176 * kill: Pass int to signalled process merge #32 * pgrep: Pass int to signalled process merge #32 * pgrep: Check sanity of SG_ARG_MAX issue #152 * pgrep: Add older than selection merge #79 * pidof: Quiet mode merge #83 * pidof: show worker threads Redhat #1803640 * ps.1: Mention stime alias issue #164 * ps: check also match on truncated 16 char comm names * ps: Add exe output option Redhat #1399206 * ps: A lot more sorting available merge #99 * pwait: New command waits for a process merge #97 * sysctl: Match systemd directory order Debian #950788 * sysctl: Document directory order Debian #951550 * top: ensure config file backward compatibility Debian #951335 * top: add command line 'e' for symmetry with 'E' issue #165 * top: add '4' toggle for two abreast cpu display issue #172 * top: add '!' toggle for combining multiple cpus * top: fix potential SEGV involving -p switch merge #114 OBS-URL: https://build.opensuse.org/request/show/871141 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/procps?expand=0&rev=119
2021-02-16 22:36:06 +01:00
"/run/sysctl.d",
@@ -685,6 +687,16 @@ static int PreloadSystem(void)
}
qsort(cfgs, ncfgs, sizeof(struct cfg *), sortpairs);
+ if (uname(&uts) == 0) {
+ char buf[PATH_MAX];
+ snprintf(buf, sizeof(buf), "/boot/sysctl.conf-%s", uts.release);
+ if (access(buf, R_OK) == 0) {
+ if (!Quiet)
+ printf("* Applying %s ...\n", buf);
+ Preload(buf);
+ }
+ }
+
for (i = 0; i < ncfgs; ++i) {
if (!Quiet)
printf(_("* Applying %s ...\n"), cfgs[i]->value);