diff --git a/SOURCES/0095-fstab-add-hint-about-systemd-reload.patch b/SOURCES/0095-fstab-add-hint-about-systemd-reload.patch new file mode 100644 index 0000000..7104bdc --- /dev/null +++ b/SOURCES/0095-fstab-add-hint-about-systemd-reload.patch @@ -0,0 +1,35 @@ +From e85fb0785608ce9f9b7d1e4b61813eb2693501f8 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Thu, 10 Aug 2023 12:34:49 +0200 +Subject: fstab: add hint about systemd reload + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2117355 +Upstream: http://github.com/util-linux/util-linux/commit/9105d3cdd819a499f5029d1009952acf6f51b7d9 +Signed-off-by: Karel Zak +--- + sys-utils/fstab.5 | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/sys-utils/fstab.5 b/sys-utils/fstab.5 +index a9e9f8c54..c1af2b347 100644 +--- a/sys-utils/fstab.5 ++++ b/sys-utils/fstab.5 +@@ -53,6 +53,15 @@ sequentially iterate through + .B fstab + doing their thing. + ++The file is not read by ++.BR mount (8) ++only but often is used by many other tools ++and daemons, and proper functionality may require additional steps. For ++example, on systemd-based systems, it's recommended to use 'systemctl ++daemon-reload' after ++.B fstab ++modification. ++ + Each filesystem is described on a separate line. + Fields on each line are separated by tabs or spaces. + Lines starting with '#' are comments. Blank lines are ignored. +-- +2.40.1 + diff --git a/SOURCES/0096-libuuid-backport-cache-handling-from-upstream.patch b/SOURCES/0096-libuuid-backport-cache-handling-from-upstream.patch new file mode 100644 index 0000000..a4ce914 --- /dev/null +++ b/SOURCES/0096-libuuid-backport-cache-handling-from-upstream.patch @@ -0,0 +1,84 @@ +From 494ee71afa6bf732f73484c9e2f4a9f4595371ef Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Wed, 9 Aug 2023 13:30:49 +0200 +Subject: libuuid: backport cache handling from upstream + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2184728 +Upstream: http://github.com/util-linux/util-linux/commit/104dc2e092058489a4be17d5b15902e58ca56804 +Upstream: http://github.com/util-linux/util-linux/commit/2fa4168c8bc9d5438bc1dfadda293c7c21b6fa59 +Signed-off-by: Karel Zak +--- + libuuid/src/gen_uuid.c | 33 ++++++++++++++++++++++++++++----- + 1 file changed, 28 insertions(+), 5 deletions(-) + +diff --git a/libuuid/src/gen_uuid.c b/libuuid/src/gen_uuid.c +index 8dc38559f..a06ddfd11 100644 +--- a/libuuid/src/gen_uuid.c ++++ b/libuuid/src/gen_uuid.c +@@ -528,18 +528,37 @@ int __uuid_generate_time_cont(uuid_t out, int *num, uint32_t cont_offset) + */ + static int uuid_generate_time_generic(uuid_t out) { + #ifdef HAVE_TLS ++ /* thread local cache for uuidd based requests */ ++ const int cs_min = (1<<6); ++ const int cs_max = (1<<18); ++ const int cs_factor = 2; + THREAD_LOCAL int num = 0; ++ THREAD_LOCAL int cache_size = cs_min; ++ THREAD_LOCAL int last_used = 0; + THREAD_LOCAL struct uuid uu; + THREAD_LOCAL time_t last_time = 0; + time_t now; + +- if (num > 0) { ++ if (num > 0) { /* expire cache */ + now = time(NULL); +- if (now > last_time+1) ++ if (now > last_time+1) { ++ last_used = cache_size - num; + num = 0; ++ } + } +- if (num <= 0) { +- num = 1000; ++ if (num <= 0) { /* fill cache */ ++ /* ++ * num + OP_BULK provides a local cache in each application. ++ * Start with a small cache size to cover short running applications ++ * and adjust the cache size over the runntime. ++ */ ++ if ((last_used == cache_size) && (cache_size < cs_max)) ++ cache_size *= cs_factor; ++ else if ((last_used < (cache_size / cs_factor)) && (cache_size > cs_min)) ++ cache_size /= cs_factor; ++ ++ num = cache_size; ++ + if (get_uuid_via_daemon(UUIDD_OP_BULK_TIME_UUID, + out, &num) == 0) { + last_time = time(NULL); +@@ -547,9 +566,11 @@ static int uuid_generate_time_generic(uuid_t out) { + num--; + return 0; + } ++ /* request to daemon failed, reset cache */ + num = 0; ++ cache_size = cs_min; + } +- if (num > 0) { ++ if (num > 0) { /* serve uuid from cache */ + uu.time_low++; + if (uu.time_low == 0) { + uu.time_mid++; +@@ -558,6 +579,8 @@ static int uuid_generate_time_generic(uuid_t out) { + } + num--; + uuid_pack(&uu, out); ++ if (num == 0) ++ last_used = cache_size; + return 0; + } + #else +-- +2.40.1 + diff --git a/SOURCES/0097-swapon-man-fix-priority-description.patch b/SOURCES/0097-swapon-man-fix-priority-description.patch new file mode 100644 index 0000000..6efb87c --- /dev/null +++ b/SOURCES/0097-swapon-man-fix-priority-description.patch @@ -0,0 +1,43 @@ +From 0035da01a9acdb547c3162e3a98a2d265bcc11e7 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Thu, 10 Aug 2023 13:13:04 +0200 +Subject: swapon: (man) fix --priority description + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2188894 +Upstream: http://github.com/util-linux/util-linux/commit/85d15200e840d4fd150801e635ee5c1b7da84737 +Signed-off-by: Karel Zak +--- + sys-utils/swapon.8 | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/sys-utils/swapon.8 b/sys-utils/swapon.8 +index 3c66c8188..301a232fc 100644 +--- a/sys-utils/swapon.8 ++++ b/sys-utils/swapon.8 +@@ -137,18 +137,18 @@ command line options. + .RE + .TP + .BR \-p , " \-\-priority " \fIpriority\fP +-Specify the priority of the swap device. ++Specify the priority of the swap device. + .I priority +-is a value between \-1 and 32767. Higher numbers indicate +-higher priority. See ++is a value between 0 and 32767. Higher numbers indicate higher priority. See + .BR swapon (2) +-for a full description of swap priorities. Add ++for a full description of swap priorities. Add + .BI pri= value + to the option field of + .I /etc/fstab + for use with + .BR "swapon -a" . +-When no priority is defined, it defaults to \-1. ++When no priority is defined, Linux kernel defaults to negative numbers. ++ + .TP + .BR \-s , " \-\-summary" + Display swap usage summary by device. Equivalent to "cat /proc/swaps". +-- +2.40.1 + diff --git a/SOURCES/0098-wall-do-not-error-for-ttys-that-do-not-exist.patch b/SOURCES/0098-wall-do-not-error-for-ttys-that-do-not-exist.patch new file mode 100644 index 0000000..6779218 --- /dev/null +++ b/SOURCES/0098-wall-do-not-error-for-ttys-that-do-not-exist.patch @@ -0,0 +1,34 @@ +From 9ab804e580e767640eae3d9189f8c6de2e673143 Mon Sep 17 00:00:00 2001 +From: Mike Gilbert +Date: Sat, 29 Jul 2023 17:32:57 -0400 +Subject: wall: do not error for ttys that do not exist + +Some wayland display managers (GDM) put strings like "seat0" in the +ut_line field of utmp entries. These are not valid tty devices. + +Avoid writing a confusing error message for ttys that do not exist. + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2227097 +Bug: https://bugs.gentoo.org/911336 +Upstream: http://github.com/util-linux/util-linux/commit/7d3713a6d541be0bac0bb78cc8fea1620583fd08 +Signed-off-by: Mike Gilbert +--- + term-utils/ttymsg.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/term-utils/ttymsg.c b/term-utils/ttymsg.c +index 2aab69f10..e53506520 100644 +--- a/term-utils/ttymsg.c ++++ b/term-utils/ttymsg.c +@@ -100,7 +100,7 @@ ttymsg(struct iovec *iov, size_t iovcnt, char *line, int tmout) { + * if not running as root; not an error. + */ + if ((fd = open(device, O_WRONLY|O_NONBLOCK, 0)) < 0) { +- if (errno == EBUSY || errno == EACCES) ++ if (errno == EBUSY || errno == EACCES || errno == ENOENT) + return NULL; + + len = snprintf(errbuf, sizeof(errbuf), "%s: %m", device); +-- +2.40.1 + diff --git a/SPECS/util-linux.spec b/SPECS/util-linux.spec index d68abc2..4f73a0c 100644 --- a/SPECS/util-linux.spec +++ b/SPECS/util-linux.spec @@ -2,7 +2,7 @@ Summary: A collection of basic system utilities Name: util-linux Version: 2.32.1 -Release: 42%{?dist} +Release: 43%{?dist} License: GPLv2 and GPLv2+ and LGPLv2+ and BSD with advertising and Public Domain Group: System Environment/Base URL: http://en.wikipedia.org/wiki/Util-linux @@ -283,6 +283,14 @@ Patch92: 0092-last-use-full-size-of-the-username.patch # 2180413 - Backport hint about systemd daemon-reload Patch93: 0093-include-c-add-cmp_timespec-and-cmp_stat_mtime.patch Patch94: 0094-mount-add-hint-about-systemctl-daemon-reload.patch +# 2117355 - Add additional documentation for fstab. +Patch95: 0095-fstab-add-hint-about-systemd-reload.patch +# 2184728 - libuuid - downport cache related patch +Patch96: 0096-libuuid-backport-cache-handling-from-upstream.patch +# 2188894 - The swapon man page of -p(priority) option shows incorrect. +Patch97: 0097-swapon-man-fix-priority-description.patch +# 2227097 - wall(1) fails when trying to use seat0 +Patch98: 0098-wall-do-not-error-for-ttys-that-do-not-exist.patch %description @@ -1132,6 +1140,12 @@ fi %{_libdir}/python*/site-packages/libmount/ %changelog +* Thu Aug 10 2023 Karel Zak 2.32.1-43 +- fix #2117355 - Add additional documentation for fstab +- fix #2184728 - libuuid - downport cache related patch +- fix #2188894 - The swapon man page of -p(priority) option shows incorrect. +- fix #2227097 - wall(1) fail when trying to use seat0 + * Wed Jul 26 2023 MSVSphere Packaging Team - 2.32.1-42 - Rebuilt for MSVSphere 8.8