]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
5 months ago core: Make sure we handle DelegateSubgroup= in combo with cgroupns 36815/head
Daan De Meyer [Fri, 25 Apr 2025 10:40:52 +0000 (12:40 +0200)] 
 core: Make sure we handle DelegateSubgroup= in combo with cgroupns

Currently, if we use a cgroup namespace together with DelegateSubgroup=,
the subgroup becomes the root of the cgroup namespace because we move the
service process to the subgroup before we unshare the cgroup namespace, and
the current cgroup becomes the root of the cgroup namespace when we unshare
the cgroup namespace.

Let's fix the problem by not moving the service process to the subgroup until
we've unshared the cgroup namespace. Note that this doesn't break the primary use
case of CLONE_INTO_CGROUP since we still use it to immediately clone into the service
main cgroup, just not anymore into the subgroup, but this shouldn't matter in practice.

Additionally, we need special handling for control processes, as those *do*
need to get spawned into the subcgroup immediately if delegation is configured to
avoid violating the cgroupsv2 "no inner processes" rule.

Effectively, this leaves us with the following logic:
- In exec_spawn(), spawn into subgroup if we're spawning a control process
  that needs to be spawned into a subgroup immediately. Otherwise, spawn into
  main service cgroup.
- In exec_invoke(), move into subgroup early if we don't need a cgroup namespace.
  Otherwise, move into subgroup after we've unshared the cgroup namespace.

5 months agocore: Disable pid namespacing for control processes
Daan De Meyer [Fri, 21 Mar 2025 08:41:15 +0000 (09:41 +0100)] 
core: Disable pid namespacing for control processes

PID namespaces frankly don't make any sense for control processes, so
let's gracefully degrade to no pid namespaces for control processes.

5 months agomeson: Remove unnecessary deps from libsystemd-static build
Daan De Meyer [Thu, 5 Jun 2025 09:04:06 +0000 (11:04 +0200)] 
meson: Remove unnecessary deps from libsystemd-static build

blkid, libmount and openssl are not used in src/basic or src/libsystemd,
and so shouldn't be required as deps of libsystemd static, so let's drop
them.

5 months agoptyfwd: introduce pty_forward_set_window_title() helper function
Yu Watanabe [Thu, 5 Jun 2025 05:59:40 +0000 (14:59 +0900)] 
ptyfwd: introduce pty_forward_set_window_title() helper function

5 months agohwdb: add support for Loupedeck devices
tytan652 [Thu, 5 Jun 2025 09:26:58 +0000 (11:26 +0200)] 
hwdb: add support for Loupedeck devices

Razer has partnered with Loupedeck to develop some devices.

Add support for the following devices:
- Loupedeck CT
- Loupedeck Live
- Loupedeck Live S
- Razer Stream Controller
- Razer Stream Controller X

5 months agosd-daemon: add sd_pidfd_get_inode_id() (#37679)
Lennart Poettering [Thu, 5 Jun 2025 07:31:48 +0000 (09:31 +0200)] 
sd-daemon: add sd_pidfd_get_inode_id() (#37679)

5 months agovmspawn: fix call to GetUnitByPID
Sam Leonard [Mon, 2 Jun 2025 15:13:13 +0000 (16:13 +0100)] 
vmspawn: fix call to GetUnitByPID

This commit also adds a handler for SIGRTMIN+4 which is another signal
used to shutdown systemd.

5 months agotest-daemon: add test case for sd_pidfd_get_inode_id() 37679/head
Mike Yuan [Tue, 3 Jun 2025 15:15:00 +0000 (17:15 +0200)] 
test-daemon: add test case for sd_pidfd_get_inode_id()

5 months agosd-daemon: add sd_pidfd_get_inode_id()
Mike Yuan [Sun, 1 Jun 2025 07:12:13 +0000 (09:12 +0200)] 
sd-daemon: add sd_pidfd_get_inode_id()

We nowadays expose pidfdid at various places, e.g. envvars
and dbus properties. Also the sd_notify() MAINPID= message
has been complemented with MAINPIDFDID=. But acquiring
pidfdid is actually non-trivial especially considering
the 32-bit case, hence let's introduce a public helper
in sd-daemon specifically for that purpose.

5 months agopidfd-util: extract pidfd_get_inode_id_impl() and make it thread safe
Mike Yuan [Sun, 1 Jun 2025 06:57:49 +0000 (08:57 +0200)] 
pidfd-util: extract pidfd_get_inode_id_impl() and make it thread safe

Preparation for later commits.

5 months agopidfd-util: open an internal pidfd if none is passed in pidfd_check_pidfs()
Mike Yuan [Sun, 1 Jun 2025 06:55:50 +0000 (08:55 +0200)] 
pidfd-util: open an internal pidfd if none is passed in pidfd_check_pidfs()

I'd like to introduce a libsystemd helper for acquiring pidfd
inode id, which however means the fd passed to pidfd_check_pidfs()
can no longer be trusted. Let's add back the logic of allocating
a genuine pidfd allocated internally, which was remove in
5dc9d5b4eacbe32f58ad6ca18d70931ab89ea409.

5 months agoman/sd_pid_get_owner_uid: don't limit -EBADF to socket fds
Mike Yuan [Sun, 1 Jun 2025 07:06:36 +0000 (09:06 +0200)] 
man/sd_pid_get_owner_uid: don't limit -EBADF to socket fds

5 months agosd-login: reject invalid pidfd with -EBADF consistently
Mike Yuan [Sun, 1 Jun 2025 07:04:27 +0000 (09:04 +0200)] 
sd-login: reject invalid pidfd with -EBADF consistently

We got it mostly right except for one function, fix it.

5 months agosd-login: various modernizations (#37728)
Lennart Poettering [Wed, 4 Jun 2025 20:24:57 +0000 (22:24 +0200)] 
sd-login: various modernizations (#37728)

5 months agoio-util: protect against INT_MAX overflow in flush_fd()
Lennart Poettering [Wed, 4 Jun 2025 14:05:41 +0000 (16:05 +0200)] 
io-util: protect against INT_MAX overflow in flush_fd()

5 months agojournal: make journal_file_copy_entry() robust towards copying invalid/half-written...
Lennart Poettering [Wed, 4 Jun 2025 18:51:24 +0000 (20:51 +0200)] 
journal: make journal_file_copy_entry() robust towards copying invalid/half-written source journal files (#37732)

5 months agojournal-file: let's make journal_file_copy_entry() robust against concurrent writing... 37732/head
Lennart Poettering [Wed, 4 Jun 2025 15:00:29 +0000 (17:00 +0200)] 
journal-file: let's make journal_file_copy_entry() robust against concurrent writing of the source

As usual, we need to protect ourselves against concurrent modification
of journal files. We a pretty good at that these days when reading
journal files. But journal_file_copy_entry() so far wasn't too good with
that. journal_file_append_data() so far returned EINVAL when you pass
invalid data to it. Since we pass the source data as-is in there, it's
going to fail if the journal source file is slightly invalid due to a
concurrent update.

Hence, we need to validate data gracefully here that we think comes from
a safe place, because actually it doesn't, it's directly copied from an
unsafe journal file.

Hence, let's introduce a clear error code here, and look for it in
journal_file_copy_entry(), and handle it gracefully.

Pretty sure this fixes #33372, but it's a race, so I don't know for
sure. If this remains reproducible we need to look at this again.

Fixes: #33372
5 months agocompress: get rid of a bunch of 'else'
Lennart Poettering [Wed, 4 Jun 2025 15:00:21 +0000 (17:00 +0200)] 
compress: get rid of a bunch of 'else'

5 months agosd-login: port sd_peer_get_cgroup() to SO_PEERPIDFD 37728/head
Lennart Poettering [Wed, 4 Jun 2025 09:45:20 +0000 (11:45 +0200)] 
sd-login: port sd_peer_get_cgroup() to SO_PEERPIDFD

5 months agosd-login: place inner part of sd_login_monitor_new() by a table
Lennart Poettering [Wed, 4 Jun 2025 09:40:45 +0000 (11:40 +0200)] 
sd-login: place inner part of sd_login_monitor_new() by a table

5 months agosd-login: modernize return parameter handling
Lennart Poettering [Wed, 4 Jun 2025 09:38:40 +0000 (11:38 +0200)] 
sd-login: modernize return parameter handling

Let's rename the return parameters as "ret_xyz" systematically in
sd-login.

Also, let's make the return parameters systematically optional, like we
typically do these days. So far some where optional, other's weren't.
Let's clean this up.

5 months agotest-network: extend comments how to run the test
Yu Watanabe [Wed, 4 Jun 2025 15:22:14 +0000 (00:22 +0900)] 
test-network: extend comments how to run the test

5 months agoSeveral follow-ups for userdb lookup from udevd and networkd (#37719)
Yu Watanabe [Wed, 4 Jun 2025 14:32:24 +0000 (23:32 +0900)] 
Several follow-ups for userdb lookup from udevd and networkd (#37719)

5 months agoupdate TODO
Lennart Poettering [Wed, 4 Jun 2025 14:05:09 +0000 (16:05 +0200)] 
update TODO

5 months agodoc: tweaks to root storage daemon docs (#37727)
Yu Watanabe [Wed, 4 Jun 2025 13:34:28 +0000 (22:34 +0900)] 
doc: tweaks to root storage daemon docs (#37727)

5 months agoBugprone argument comment 9 (#37712)
Yu Watanabe [Wed, 4 Jun 2025 13:33:51 +0000 (22:33 +0900)] 
Bugprone argument comment 9 (#37712)

Follow up from https://github.com/systemd/systemd/pull/37678

5 months agocopy: return immediately on fs-verity failures
Allison Karlitskaya [Thu, 20 Mar 2025 12:13:13 +0000 (13:13 +0100)] 
copy: return immediately on fs-verity failures

Since 8065d02e263a ("copy: Fix error handling in fd_copy_directory()")
we immediately abort recursive copy operations on ENOSPC.  Let's also
abort on the common case of filesystems not supporting fs-verity: if
it's unsupported for one file, it's unlikely to work for the 1000s that
follow it.

We do this by mapping the two fs-verity "not supported" errors (ENOTTY,
EOPNOTSUPP) to ESOCKTNOSUPPORT as a special "fs-verity not supported
here" error.  When we see that error at the top level we exit
immediately.

This prevents us from having to see the same error message literally
thousands of time when using fsverity=copy with systemd-repart on a
filesystem which lacks the proper support.

Adjust the test-copy test case to expect the new errno.  Previously this
test case would output multiple failure lines per `copy_tree_at()`
invocation (for the failing cases) but now it only outputs one.

5 months agodoc: clarify that root storage daemons need unit files 37727/head
Lennart Poettering [Wed, 4 Jun 2025 12:50:11 +0000 (14:50 +0200)] 
doc: clarify that root storage daemons need unit files

Fixes: #37700
5 months agodoc: mention 'exitrd' term
Lennart Poettering [Wed, 4 Jun 2025 12:50:07 +0000 (14:50 +0200)] 
doc: mention 'exitrd' term

5 months agoRevert "github/mkosi: tentatively disable mkosi(opensuse) job" 37719/head
Yu Watanabe [Wed, 14 May 2025 16:46:16 +0000 (01:46 +0900)] 
Revert "github/mkosi: tentatively disable mkosi(opensuse) job"

This reverts commit 48a092afbb27b03daaeb2db938917eb98c82e366.

5 months agomkosi: install util-linux-systemd in SUSE
Luca Boccassi [Tue, 3 Jun 2025 17:54:52 +0000 (18:54 +0100)] 
mkosi: install util-linux-systemd in SUSE

Some tools (findmnt, logger, lsblk, lslogins) got moved to a
new util-linux-systemd package in Tumbleweed so install it explicitly

5 months agoTEST-17-UDEV: acquire SYS_UID_MAX/SYS_GID_MAX from userdbctl
Yu Watanabe [Tue, 3 Jun 2025 20:38:35 +0000 (05:38 +0900)] 
TEST-17-UDEV: acquire SYS_UID_MAX/SYS_GID_MAX from userdbctl

Suse build systemd with -Dsystem-uid-max=499 -Dsystem-gid-max=499,
and seems to not provide /etc/login.defs file. See
https://github.com/bmwiedemann/openSUSE/blob/2dc224ae5d446e928519315f4d46f76d1e34b8a8/packages/s/systemd/systemd.spec

5 months agonetwork: skip loading /etc/shadow
Yu Watanabe [Tue, 3 Jun 2025 20:29:16 +0000 (05:29 +0900)] 
network: skip loading /etc/shadow

We only require UID/GID, hence not necessary to load information from shadow.

5 months agoudev-rules: skip loading /etc/shadow
Yu Watanabe [Tue, 3 Jun 2025 20:27:34 +0000 (05:27 +0900)] 
udev-rules: skip loading /etc/shadow

We only require UID/GID, hence not necessary to load information from shadow.

5 months agouserdb: make ENOEXEC wins over ESRCH
Yu Watanabe [Wed, 4 Jun 2025 09:14:52 +0000 (18:14 +0900)] 
userdb: make ENOEXEC wins over ESRCH

Both ENOEXEC and ESRCH is a kind of error that indicate successful
lookup. ENOEXEC means the server found an entry but it does not
pass filter. ESRCH means the server could not find an entry.
Hence, ENOEXEC should have more information, and should be propagated to
the caller.

5 months agouserdb: use RET_GATHER() at one more place and update comment
Yu Watanabe [Wed, 4 Jun 2025 09:14:02 +0000 (18:14 +0900)] 
userdb: use RET_GATHER() at one more place and update comment

5 months agouserdb: fix definition of USERDB_SYNTHESIZE_NUMERIC
Yu Watanabe [Tue, 3 Jun 2025 20:20:21 +0000 (05:20 +0900)] 
userdb: fix definition of USERDB_SYNTHESIZE_NUMERIC

Otherwise, we always synthesize numeric IDs.

Follow-up for e4d07d1a2d66fd200abdd977b70fc6ac69a369ce.

5 months agoresolved: honour SD_RESOLVED_NO_CNAME flag when processing cache
Lennart Poettering [Wed, 4 Jun 2025 08:53:50 +0000 (10:53 +0200)] 
resolved: honour SD_RESOLVED_NO_CNAME flag when processing cache

Fixes: #33300
Replaces: #35102

5 months agotreewide: correct argument comments for sd_event_add_time 37712/head
Jelle van der Waa [Wed, 4 Jun 2025 09:24:21 +0000 (11:24 +0200)] 
treewide: correct argument comments for sd_event_add_time

5 months agotreewide: correct argument comments for sd_netlink_call
Jelle van der Waa [Wed, 4 Jun 2025 09:15:52 +0000 (11:15 +0200)] 
treewide: correct argument comments for sd_netlink_call

5 months agotreewide: correct argument comment to 'ret' where applicable
Jelle van der Waa [Tue, 3 Jun 2025 13:58:24 +0000 (15:58 +0200)] 
treewide: correct argument comment to 'ret' where applicable

For functions with one return argument prefer 'ret' as argument comment.

5 months agoask-password-api: correct argument comment
Jelle van der Waa [Tue, 3 Jun 2025 13:37:30 +0000 (15:37 +0200)] 
ask-password-api: correct argument comment

5 months agoRevert "coredump: lock down EnterNamespace= mount even more"
Michal Sekletar [Fri, 14 Mar 2025 08:16:17 +0000 (09:16 +0100)] 
Revert "coredump: lock down EnterNamespace= mount even more"

This reverts commit 4c9c8b8d09eff18df71ba4aa910df4201f9890a0.

Reverted change broke EnterNamespace= completely. For example, libdw
tries to access libc in /lib64 which points to usr/lib64 and that fails.
Similarly for binaries, we need to be able to resolve /bin to usr/bin
and /sbin to usr/sbin at the very least.

5 months agorepart: correct argument comment
Jelle van der Waa [Tue, 3 Jun 2025 13:32:49 +0000 (15:32 +0200)] 
repart: correct argument comment

5 months agonsresourced: correct argument comments
Jelle van der Waa [Tue, 3 Jun 2025 12:07:21 +0000 (14:07 +0200)] 
nsresourced: correct argument comments

5 months agosd-varlink: correct argument comment
Jelle van der Waa [Tue, 3 Jun 2025 12:01:13 +0000 (14:01 +0200)] 
sd-varlink: correct argument comment

5 months agohomectl: rename 'emphasize_current' -> 'emphasize_current_password'
Jelle van der Waa [Tue, 3 Jun 2025 11:40:39 +0000 (13:40 +0200)] 
homectl: rename 'emphasize_current' -> 'emphasize_current_password'

Other functions in this file use the same parameter naming.

5 months agogenerator: rename 'password' -> 'key_file'
Jelle van der Waa [Tue, 3 Jun 2025 09:14:22 +0000 (11:14 +0200)] 
generator: rename 'password' -> 'key_file'

Makes the header declaration and implementation consistent.

5 months agocgroup-util: rename 'fsfd' -> 'cgroups_fd'
Jelle van der Waa [Tue, 3 Jun 2025 08:49:17 +0000 (10:49 +0200)] 
cgroup-util: rename 'fsfd' -> 'cgroups_fd'

Makes the header and implementation consistent.

5 months agoman/pcrlock: fix typo
Yu Watanabe [Wed, 4 Jun 2025 04:12:42 +0000 (13:12 +0900)] 
man/pcrlock: fix typo

Follow-up for ccd2bf48b2d736e335f217d5621a817aa1b6beeb.

5 months agouserdbctl: Label dynamic greeter users
Adrian Vovk [Fri, 30 May 2025 18:27:29 +0000 (14:27 -0400)] 
userdbctl: Label dynamic greeter users

5 months agodoc: fix integration tests guide reference
Emmanuel Ferdman [Mon, 2 Jun 2025 19:19:26 +0000 (12:19 -0700)] 
doc: fix integration tests guide reference

5 months agocore/varlink: use forward.h at two more places (#37716)
Mike Yuan [Tue, 3 Jun 2025 21:11:17 +0000 (23:11 +0200)] 
core/varlink: use forward.h at two more places (#37716)

5 months agocore/varlink: use forward.h at two more places 37716/head
Yu Watanabe [Tue, 3 Jun 2025 19:57:29 +0000 (04:57 +0900)] 
core/varlink: use forward.h at two more places

5 months agocompress: avoid a bunch of div-by-zeroes
Lennart Poettering [Tue, 3 Jun 2025 14:26:17 +0000 (16:26 +0200)] 
compress: avoid a bunch of div-by-zeroes

Follow-up for #37706. Implements the same logic for all compression
algorithms we have.

5 months agotpm2: various smaller fixes, mostly about better error messages and support checking...
Lennart Poettering [Tue, 3 Jun 2025 16:26:36 +0000 (18:26 +0200)] 
tpm2: various smaller fixes, mostly about better error messages and support checking (#37690)

Fixes: #35187
Fixes: #36743
Fixes: #37607
5 months agotpm2-util: guarantee that verb_has_tpm2_generic() returns usable exit status 37690/head
Lennart Poettering [Tue, 3 Jun 2025 14:11:57 +0000 (16:11 +0200)] 
tpm2-util: guarantee that verb_has_tpm2_generic() returns usable exit status

5 months agotpm2-util: use BIT_FOREACH() more
Lennart Poettering [Tue, 3 Jun 2025 14:11:35 +0000 (16:11 +0200)] 
tpm2-util: use BIT_FOREACH() more

5 months agotpm2: add a clear error message for all errors that suggest a PCR violation
Lennart Poettering [Mon, 2 Jun 2025 11:13:17 +0000 (13:13 +0200)] 
tpm2: add a clear error message for all errors that suggest a PCR violation

Fixes: #35187
5 months agotpm2-util: add a brief summary of tpm2_unseal() return values in a comment
Lennart Poettering [Mon, 2 Jun 2025 11:13:59 +0000 (13:13 +0200)] 
tpm2-util: add a brief summary of tpm2_unseal() return values in a comment

5 months agotpm2-util: also generate recognizable error if PolicyAuthorizeNV fails
Lennart Poettering [Mon, 2 Jun 2025 11:12:28 +0000 (13:12 +0200)] 
tpm2-util: also generate recognizable error if PolicyAuthorizeNV fails

5 months agopcrlock: also refuse lacking SHA-256 support early when creating policy
Lennart Poettering [Mon, 2 Jun 2025 10:32:33 +0000 (12:32 +0200)] 
pcrlock: also refuse lacking SHA-256 support early when creating policy

This will fail eventually, but let's be explicit early here.

5 months agopcrlock: make error messages more useful if PCR state doesn't match policy during...
Lennart Poettering [Mon, 2 Jun 2025 10:23:51 +0000 (12:23 +0200)] 
pcrlock: make error messages more useful if PCR state doesn't match policy during PolicyOR

Fixes: #35187
5 months agomeasure: generate a more useful error in case SHA1 support is disabled by distro
Lennart Poettering [Mon, 2 Jun 2025 09:49:33 +0000 (11:49 +0200)] 
measure: generate a more useful error in case SHA1 support is disabled by distro

Fixes: #36743
5 months agopcrlock: add "is-supported" verb that checks if the local TPM supports the commands...
Lennart Poettering [Mon, 2 Jun 2025 09:20:52 +0000 (11:20 +0200)] 
pcrlock: add "is-supported" verb that checks if the local TPM supports the commands we need for pcrlock

systemd-pcrlock requires support for the PolicyAuthorizeNV command,
which is not implemented in the first TPM2 releases. We also strictly
require SHA-256 support. Hence add a tool for checking for both of
these.

This is a tighter version of "systemd-analyze has-tpm2", that checks for
the precise feature that systemd-pcrlock needs, on top of basic TPM2
functionality.

Fixes: #37607
5 months agotpm2-util: correct copy/pasted error message
Lennart Poettering [Mon, 2 Jun 2025 11:13:34 +0000 (13:13 +0200)] 
tpm2-util: correct copy/pasted error message

5 months agobus-unit-util: warn and ignore assignment of deprecated properties
Yu Watanabe [Fri, 30 May 2025 19:30:43 +0000 (04:30 +0900)] 
bus-unit-util: warn and ignore assignment of deprecated properties

With 5da476ac7728b91ad3a49c1b126b3559b4fbeed8, we refused to set the
properties, but this relaxes the behavior, and now commands warn and
ignore the assignment.

Also, assignment of CPUAccounting property is now warned and ignored,
which is deprecated by 29da53dde32a0097134f6c3ba5fb5220dd6e5423.

Prompted by https://github.com/systemd/systemd/pull/37665#discussion_r2115676993

5 months agorepart: if partition already exists, required size may not be multiple of grain size
Yu Watanabe [Fri, 18 Apr 2025 18:41:45 +0000 (03:41 +0900)] 
repart: if partition already exists, required size may not be multiple of grain size

See partition_min_size_with_padding().
Fixes #37178.

5 months agovmspawn: do not preserve access permissions and xattrs of template OVMF vars
Arian van Putten [Sun, 1 Jun 2025 10:02:55 +0000 (12:02 +0200)] 
vmspawn: do not preserve access permissions and xattrs of template OVMF vars

This makes vmspawn work when /usr/share/qemu/edk2-i386-vars.fd is on
disk with 0444 permissions as is the case on NixOS.

The nix package manager does not store any access permissions, ownership,
timestamps, or extended attributes in its package format to increase
reproducibility. The only meta-data that is stored is the executable bit.

Thus when unpacking a nix package, the executable bit is preserved, but no other
access permissions are preserved and all files in /nix/store end up as
read-only.

This causes the template OVMF vars file to have 0444 permissions. If we preserve
those permissions when copying the template file to /tmp that means QEMU can not
write to the file and fails.

So lets not preserve permissions and keep the 0600 permissions that are set by
default.

5 months agorepart: Add ratelimitting for progress updates
Daan De Meyer [Mon, 2 Jun 2025 14:34:59 +0000 (16:34 +0200)] 
repart: Add ratelimitting for progress updates

Same logic as in systemd-import, this is especially important when
systemd-repart is not run from a tty as currently we'll get something
like this:

```
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  98%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G  99%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G 100%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G 100%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G 100%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G 100%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G 100%
/var/tmp/.#repartc256fb6b9dc517af → /work/var/tmp/mkosi-workspace-2ek2c3n1/repart-definitions/10-root.conf 1.7G/1.7G 100%
```

5 months agorepart: Improve logging in resolve_copy_blocks_auto()
Daan De Meyer [Mon, 2 Jun 2025 14:02:58 +0000 (16:02 +0200)] 
repart: Improve logging in resolve_copy_blocks_auto()

5 months agoBugprone argument comment 8 (#37678)
Yu Watanabe [Tue, 3 Jun 2025 01:58:52 +0000 (10:58 +0900)] 
Bugprone argument comment 8 (#37678)

Follow up from https://github.com/systemd/systemd/pull/37556

5 months agotest: send monotonic timestamp rather than unix seconds for MONOTONIC_USEC= argument
Luca Boccassi [Mon, 2 Jun 2025 18:45:02 +0000 (19:45 +0100)] 
test: send monotonic timestamp rather than unix seconds for MONOTONIC_USEC= argument

Follow-up for 3998b30a040d1494918e11c78ef3eae72532bbca

5 months agocompress: prevent divide-by-zero when no data is read (#37706)
Alex [Tue, 3 Jun 2025 01:51:00 +0000 (21:51 -0400)] 
compress: prevent divide-by-zero when no data is read (#37706)

If the first call to `loop_read()` returns 0 (no input), `total_in`
remains 0, causing `total_out/total_in` to potential divide by zero.

We add a check before logging the compression ratio to skip the
percentage calculation when total_in is zero.

Co-authored-by: jinyaoguo <guo846@purdue.edu>
5 months agonetwork: fix a potential divide-by-zero (#37705)
Alex [Mon, 2 Jun 2025 22:47:49 +0000 (18:47 -0400)] 
network: fix a potential divide-by-zero (#37705)

In function `tc_init`, hz is parsed from the content of file
`"/proc/net/psched"` and can be 0.
In function `hierarchy_token_bucket_class_verify`, hz is directly used
as a divisor in
`htb->buffer = htb->rate / hz + htb->mtu;` without any check. This adds a check on hz before using it as a divisor.

Co-authored-by: jinyaoguo <guo846@purdue.edu>
5 months agoman/systemd-creds: fix documentation typo in systemd.exec.xml
Anton Ryzhov [Mon, 2 Jun 2025 22:20:30 +0000 (00:20 +0200)] 
man/systemd-creds: fix documentation typo in systemd.exec.xml

5 months agohwdb: fix touchpad for ASUS X1504ZA (#37696)
Michał Moczulski [Mon, 2 Jun 2025 20:12:07 +0000 (22:12 +0200)] 
hwdb: fix touchpad for ASUS X1504ZA (#37696)

Added udev rule generated by `libinput measure fuzz --fuzz=8`, which
fixes my touchpad.

5 months agoshared/install.h: rename 'flags' -> 'file_flags' 37678/head
Jelle van der Waa [Mon, 2 Jun 2025 15:55:53 +0000 (17:55 +0200)] 
shared/install.h: rename 'flags' -> 'file_flags'

Make it consistent with the implementation.

5 months agoio-util: rename 'nfds' -> 'n_fds'
Jelle van der Waa [Mon, 2 Jun 2025 15:42:08 +0000 (17:42 +0200)] 
io-util: rename 'nfds' -> 'n_fds'

5 months agouid-range: correct argument comment
Jelle van der Waa [Sun, 1 Jun 2025 08:18:38 +0000 (10:18 +0200)] 
uid-range: correct argument comment

5 months agosd-varlink: fix argument naming
Jelle van der Waa [Wed, 28 May 2025 18:57:33 +0000 (20:57 +0200)] 
sd-varlink: fix argument naming

5 months agosd-journal: rename sd_journal_get_monotonic_usec ret argument
Jelle van der Waa [Sun, 25 May 2025 17:53:24 +0000 (19:53 +0200)] 
sd-journal: rename sd_journal_get_monotonic_usec ret argument

Rename ret to ret_monotonic to distinguish from ret_boot_id and
according to existing argument comments.

5 months agomount-util: correct argument comment
Jelle van der Waa [Sun, 25 May 2025 17:46:47 +0000 (19:46 +0200)] 
mount-util: correct argument comment

5 months agonspawn: correct argument comments
Jelle van der Waa [Sun, 25 May 2025 17:45:37 +0000 (19:45 +0200)] 
nspawn: correct argument comments

5 months agoenv-util: rename 'n' -> 'length'
Jelle van der Waa [Sun, 25 May 2025 17:43:45 +0000 (19:43 +0200)] 
env-util: rename 'n' -> 'length'

5 months agonss-systemd/userdb drop-ins: various doc updates (#37693)
Lennart Poettering [Mon, 2 Jun 2025 15:02:20 +0000 (17:02 +0200)] 
nss-systemd/userdb drop-ins: various doc updates (#37693)

This mostly adds crosslinks from various bits and pieces of userdb docs
to each other, and adds some clarifications.

Fixes: #27208
5 months agoDeduplicate error string patterns (#37676)
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jun 2025 13:34:17 +0000 (15:34 +0200)] 
Deduplicate error string patterns (#37676)

I wanted to see if moving moving out constant string arguments our of
error messages results in smaller binary sizes. Turns out it does, but
the savings are not consistent. Sometimes we get a few kB in a single
binary, sometimes there is no size change.

5 months agoman: emphasize that systemd-userdb-load-credentials.service doesn't do UID/GID allocation 37693/head
Lennart Poettering [Mon, 2 Jun 2025 13:15:33 +0000 (15:15 +0200)] 
man: emphasize that systemd-userdb-load-credentials.service doesn't do UID/GID allocation

5 months agoman: add reference from userdbctl man page to nss-systemd regarding user record drop-ins
Lennart Poettering [Mon, 2 Jun 2025 13:15:11 +0000 (15:15 +0200)] 
man: add reference from userdbctl man page to nss-systemd regarding user record drop-ins

5 months agoman: mention systemd-userdb-load-credentials.service when discussing /run/userdb...
Lennart Poettering [Mon, 2 Jun 2025 13:14:43 +0000 (15:14 +0200)] 
man: mention systemd-userdb-load-credentials.service when discussing /run/userdb/ drop-ins

5 months agorepart: fix generation of UUID= line for vfat in fstab entries (#37689)
Lennart Poettering [Mon, 2 Jun 2025 10:25:14 +0000 (12:25 +0200)] 
repart: fix generation of UUID= line for vfat in fstab entries (#37689)

Fixes: #36735
5 months agoDefine uid range for greeter
Adrian Vovk [Wed, 21 May 2025 21:32:03 +0000 (17:32 -0400)] 
Define uid range for greeter

In multi-seat scenarios, a display manager might need to start multiple
greeter sessions. But systemd allows at most one graphical session per
user. So, display managers now have a range of UIDs to dynamically
allocate users for their greeter sessions.

5 months agovarious: do not include file names directly in error messages 37676/head
Zbigniew Jędrzejewski-Szmek [Mon, 2 Jun 2025 08:30:34 +0000 (10:30 +0200)] 
various: do not include file names directly in error messages

git grep -l 'Failed to open /'|xargs sed -r -i 's|"Failed to open (/[^ ]+): %m"|"Failed to open %s: %m", "\1"|g'
git grep -l $'Failed to open \'/'|xargs sed -r -i $'s|"Failed to open \'(/[^ ]+)\': %m"|"Failed to open %s: %m", "\\1"|g'
git grep -l "Failed to open /"|xargs sed -r -i $'s|"Failed to open (/[^ ]+), ignoring: %m"|"Failed to open %s, ignoring: %m", "\\1"|g'
+ some manual fixups.

5 months agobuild(deps): bump github/codeql-action from 3.28.10 to 3.28.18
dependabot[bot] [Sun, 1 Jun 2025 09:12:40 +0000 (09:12 +0000)] 
build(deps): bump github/codeql-action from 3.28.10 to 3.28.18

Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.10 to 3.28.18.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/b56ba49b26e50535fa1e7f7db0f4f7b4bf65d80d...ff0a06e83cb2de871e5a09832bc6a81e7276941f)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.28.18
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agoudevadm: allow to specify device by device ID (#37636)
Yu Watanabe [Mon, 2 Jun 2025 09:02:36 +0000 (18:02 +0900)] 
udevadm: allow to specify device by device ID (#37636)

5 months agorepart: set a useful access mode file for generated fstab files 37689/head
Lennart Poettering [Mon, 2 Jun 2025 08:12:33 +0000 (10:12 +0200)] 
repart: set a useful access mode file for generated fstab files

We create these as temporary files with 0600 access mode. Let's adjust
this before we install the files.

5 months agorepart: fix generation of UUID= line for vfat in fstab entries
Lennart Poettering [Mon, 2 Jun 2025 08:12:10 +0000 (10:12 +0200)] 
repart: fix generation of UUID= line for vfat in fstab entries

Fixes: #36735
5 months agobuild(deps): bump meson from 1.6.1 to 1.8.1 in /.github/workflows
dependabot[bot] [Sun, 1 Jun 2025 09:30:36 +0000 (09:30 +0000)] 
build(deps): bump meson from 1.6.1 to 1.8.1 in /.github/workflows

Bumps [meson](https://github.com/mesonbuild/meson) from 1.6.1 to 1.8.1.
- [Release notes](https://github.com/mesonbuild/meson/releases)
- [Commits](https://github.com/mesonbuild/meson/compare/1.6.1...1.8.1)

---
updated-dependencies:
- dependency-name: meson
  dependency-version: 1.8.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agobuild(deps): bump super-linter/super-linter from 7.3.0 to 7.4.0
dependabot[bot] [Sun, 1 Jun 2025 09:12:31 +0000 (09:12 +0000)] 
build(deps): bump super-linter/super-linter from 7.3.0 to 7.4.0

Bumps [super-linter/super-linter](https://github.com/super-linter/super-linter) from 7.3.0 to 7.4.0.
- [Release notes](https://github.com/super-linter/super-linter/releases)
- [Changelog](https://github.com/super-linter/super-linter/blob/main/CHANGELOG.md)
- [Commits](https://github.com/super-linter/super-linter/compare/4e8a7c2bf106c4c766c816b35ec612638dc9b6b2...12150456a73e248bdc94d0794898f94e23127c88)

---
updated-dependencies:
- dependency-name: super-linter/super-linter
  dependency-version: 7.4.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agoUpdate TODO
Lennart Poettering [Mon, 2 Jun 2025 07:34:59 +0000 (09:34 +0200)] 
Update TODO