| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
format_timestamp_relative currently returns the plural form of
years and months no matter the quantity, and in many cases (for
durations > 1 week) this is the same with days.
This patch changes this so that the function takes the quantity into account,
returning "1 month 1 week ago" instead of "1 months 1 weeks ago".
(cherry picked from commit 45eb4d2261ed0d943fd503a6d79ee3b7b7558c09)
|
|
|
|
|
|
|
| |
Text currently refers to `/etc/nsswitch.conf` where it should refer to `/etc/resolv.conf`.
This is in the context of defining a nameserver IP and search domains.
(cherry picked from commit e83580bfc6e74359ba242d5176d933ea1e723f89)
|
|
|
|
|
|
| |
fixing https://github.com/systemd/systemd/issues/19689
(cherry picked from commit 682e043c42fe3ac0fee4ce727458aaeb0e638589)
|
|
|
|
|
|
|
|
|
| |
Show message "Deactivated successfully" in debug mode (when manager is
user) rather than in info mode. This message has low information value
for regular users and it might be a bit overwhelming on a system with
a lot of devices.
(cherry picked from commit edf2ee22f54005d76b2fb8fdcc9c60974feb88bc)
|
|
|
|
| |
(cherry picked from commit f4c48492fe3dfa268b6d2457c9ae425b685ca4e0)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the light of https://lwn.net/Articles/859679/ let's drop
quotactl_path() again from the filter set list, as it got backed out
again in 5.13-rc3.
It's likely going to be replaced by quotactl_fd() eventually, but that
hasn't made its way into the tree yet, hence let's not replace the entry
for now.
This partially reverts 34254e599a28529bdb89f91571adeaf7c76d9f43.
(cherry picked from commit 8156422c8f0d94d3444043282f01551084271b22)
|
|
|
|
| |
(cherry picked from commit d34e3b76e515af99b97a2b96c799c6889ffe6f71)
|
|
|
|
| |
(cherry picked from commit 5156e6804db9deaf1abe641b0563ee1110b4187c)
|
|
|
|
|
|
| |
Fixes #19920.
(cherry picked from commit 0f97b7c338bb7440572c454558efb8fee395896a)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Cgroups may be unnecessarily realized when they are not needed. This
happens, e.g. for mount units parsed from /proc/$PID/mountinfo, check
touch /run/ns_mount
unshare -n sh -c "mount --bind /proc/self/ns/net /run/ns_mount"
# no cgroup exists
file /sys/fs/cgroup/system.slice/run-ns_mount.mount
systemctl daemon-reload
# the vain cgroup exists
file /sys/fs/cgroup/system.slice/run-ns_mount.mount
. (Such cgroups can account to a large number with many similar mounts.)
The code already accounts for "lazy" realization (see various checks for
Unit.cgroup_realized) but the unit_deserialize() in the reload/reexec
path performs unconditional realization.
Invalidate (and queue) the units for realization only if we know that
they were already realized in the past. This is a safe thing to do even
in the case the reload brings some new cgroup setting (controllers, BPF)
because units that aren't realized will use the updated setting when the
time for their realization comes. (It's not even needed to add a code
comment because the current formulation suggests the changed behavior.)
(cherry picked from commit cc815b7fea0ade5331e8dd22ef6b5183edb77608)
|
|
|
|
|
|
|
|
| |
interfaces
Fixes #19257.
(cherry picked from commit dbb3b26f1b347f9d7b9fd56aa4ef4a92253e6f2e)
|
|
|
|
|
|
|
|
|
|
| |
Instead of ordering non-pending before pending we should order
"non-pending OR ratelimited" before "pending AND not-ratelimited".
This fixes a bug where ratelimited events were ordered at the end of the
priority queue and could be stuck there for an indeterminate amount of
time.
(cherry picked from commit 81107b8419c39f726fd2805517a5b9faab204e59)
|
|
|
|
| |
(cherry picked from commit 9dfb429a44b0c7e4c50f35f888ac8ba3c677a994)
|
|
|
|
| |
(cherry picked from commit c48bc311a57aff76b592cc1569ca758b84438ef5)
|
|
|
|
| |
(cherry picked from commit 3c3335c7146a43137c46acfa18417cca101cb088)
|
|
|
|
|
|
| |
Fixes #19869.
(cherry picked from commit c3006a485c9c35c0ab947479ff1dd7149fda9750)
|
|
|
|
| |
(cherry picked from commit 85bc4c080d8264c7d7e233c9e0f304c8d650f126)
|
|
|
|
|
|
|
| |
In #19771 there were a few missing markdown tags a few style issue.
Signed-off-by: Peter Morrow <pemorrow@linux.microsoft.com>
(cherry picked from commit dbb8b5bcf78a86020287f98a8d96780af0203672)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
hash feature
When suppressing duplicate fields between files we so far tried to reuse
the already known hash value of the data fields between files. This was
fine as long as we used the same hash function everywhere. However,
since addition of the keyed hash feature for journal files this doesn't
work anymore, since the hashes will be different for different files.
Fixes: #19172
(cherry picked from commit 2e1a8a5dab8b5519c079c9bed54fc682aa4095b0)
|
|
|
|
| |
(cherry picked from commit d8671b1c6f036ce270b9631973314e7de24e74b1)
|
|
|
|
| |
(cherry picked from commit 34254e599a28529bdb89f91571adeaf7c76d9f43)
|
|
|
|
|
|
|
| |
the main journald instance
Fixes: #18951
(cherry picked from commit e68778a3ac30932a5fa86d08605b423d711ddb7c)
|
|
|
|
|
|
|
|
|
| |
a few times
Inspired by
https://fedoraproject.org/wiki/Changes/yescrypt_as_default_hashing_method_for_shadow.
(cherry picked from commit 7ff9d99e9e8b75930aa05b45eb21889eac8af014)
|
|
|
|
|
|
|
|
|
|
|
|
| |
In dns_server_unlink_marked() and dns_server_mark_all() we done recursively.
People might have dozens of servers defined, and it's better to avoid recursion
when a simple loop suffices.
dns_server_unlink_marked() would only unmark the first marked server.
Fixes #19651.
(cherry picked from commit a77f9dfbaed2e49269b42222da0d1c8680057fa6)
|
|
|
|
|
|
|
|
|
|
|
| |
on deserialization
Otherwise, if a socket address is duplicated, then the previous fd is
closed.
Fixes #19843.
(cherry picked from commit 3da0caf5bbf3c8cab716c4d7adf0eb25907dc951)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When e.g. tmp.mount is present in the initrd, and we serialize it, switch root,
and deserialize, the new systemd is confused because it thinks /tmp is mounted.
In general, it doesn't make sense to serialize anything that refers to paths in
the old root file system.
This fixes two errors for me:
1. tmp.mount was not mounted properly before local-fs.target. It would be
mounted as some point (I guess when we re-read /proc/self/mountinfo for some
other reason). In effect systemd-tmpfiles-setup.service would see one fs, and
some other units started later a different one. In particular gdm.service would
fail because the pre-created /tmp/.X11-unix with proper permissions would not
exist at time it was started.
2. # systemd[1]: proc-sys-fs-binfmt_misc.automount: Got hangup/error on autofs pipe from kernel. Likely our automount point has been unmounted by someone or something else?
# systemd[1]: proc-sys-fs-binfmt_misc.automount: Failed with result 'unmounted'.
# systemd[1]: Mounting proc-sys-fs-binfmt_misc.mount...
# systemd[1]: Mounted proc-sys-fs-binfmt_misc.mount.
# systemd[1]: Starting systemd-binfmt.service...
# systemd[1]: Finished systemd-binfmt.service.
# systemd[1]: proc-sys-fs-binfmt_misc.automount: Path /proc/sys/fs/binfmt_misc is already a mount point, refusing start.
# systemd[1]: Failed to set up automount proc-sys-fs-binfmt_misc.automount.
# systemd[1]: proc-sys-fs-binfmt_misc.automount: Path /proc/sys/fs/binfmt_misc is already a mount point, refusing start.
# systemd[1]: Failed to set up automount proc-sys-fs-binfmt_misc.automount.
# systemd[1]: proc-sys-fs-binfmt_misc.automount: Path /proc/sys/fs/binfmt_misc is already a mount point, refusing start.
# systemd[1]: Failed to set up automount proc-sys-fs-binfmt_misc.automount.
# systemd[1]: Stopping systemd-binfmt.service...
# systemd[1]: systemd-binfmt.service: Deactivated successfully.
# systemd[1]: Stopped systemd-binfmt.service.
I couldn't understand the error here, but in retrospect the first line is entirely
correct: "someone or something else" was the old systemd unmounting the old root.
(cherry picked from commit 755021d43448011ef169f20ec3a08d4e92c824af)
|
|
|
|
|
|
|
|
|
| |
When using top level drop-ins it isn't immediately obvious that one can
make use of symlinking to disable a top-level drop in for a specific
unit.
Signed-off-by: Peter Morrow <pemorrow@linux.microsoft.com>
(cherry picked from commit 90a404f5d490eb4981851966f6a01f210fd5eb0d)
|
|
|
|
|
|
|
|
| |
We were effectively doing all post-upgrade scripts twice in Fedora. We got this
wrong, so it's likely other people will get it wrong too. So let's explain
what is actually needed to make this work, but also when it's not useful.
(cherry picked from commit f75420a43a4dc3c69210f887b38f5df23660ea16)
|
|
|
|
|
|
| |
Updating documentation for systemd to reflect that logging is done in the console.
(cherry picked from commit 9f40351f77963efc304473830a431c424fd976b1)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes #19437.
As reported in the bug:
> # drkonqi-coredump-processor@.service
> ...
> [Install]
> WantedBy=systemd-coredump@.service
>
> The plan here is to have a systemd-coredump@ instance start the same %i for
> drkonqi-coredump-processor@. Works perfectly when creating the symlink manually
> ln -sv /usr/lib/systemd/system/drkonqi-coredump-processor@.service
> /etc/systemd/system/systemd-coredump@.service.wants/.
When DefaultInstance is set, we replace template references with
template@default-inst. But in this case we want to create a symlink for the
template name, so that systemd will fill in the instance from the
wanting/requiring unit. This is only possible for those units that actually
have an instance set, so we create the symlink only from .requires/ or .wants
of an instantiated unit (then this specific instance will be used), or a
template (than some instance will be inherited later).
Specifically:
...
[Install]
WantedBy=other@.service, fixed.service
DefaultInstance=inst
→ enable foo@.service creates other@.service.wants/foo@inst.service, and
other@a.service will want foo@inst.service, and other@b.service will want foo@inst.service,
and fixed.service will want foo@inst.service.
Without DefaultInstance,
→ enable foo@.service creates other@.service.wants/foo@.service, and
other@a.service would want foo@a.service, and other@b.service would want foo@b.service,
but enablement fails because no dependency can be created for fixed.service:
Failed to enable unit, unit fixed.service is a non-template unit.
(cherry picked from commit b0ec372a9665dab6bb00066bc0fed667940f343e)
|
|
|
|
| |
(cherry picked from commit d27e6aee5050da17bc9531fb62ac11aba4b15ceb)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Initially I wanted to add ConditionPathExists=!/etc/initrd-release in various
units (ldconfig.service, systemd-sysusers.service, systemd-hwdb-update.service,
systemd-journal-catalog-update, systemd-update-done.service), but I think it's
better to just disable the mechanism in the initrd altogether. Initrd images
are put together in a very particular way, and there is not need to do
post-update steps on them. If a unit from some other package winds up in the
initrd, we wouldn't want to invoke it either.
Also, any modifications are ephemeral, so any update would happen on every
use. And finally, initrd images are all about speed, and we shouldn't invoke
any unneeded services.
(cherry picked from commit 294eace024b0e6c34cb64e3bb4f8958bb98ee00b)
|
|
|
|
|
|
|
| |
This is currently our only .automount unit. We wouldn't want to trigger it
accidentally during shutdown, so let's stop it too.
(cherry picked from commit dc16846c26287fd2081eb3c4a73487c9b186e2b7)
|
|
|
|
|
|
|
| |
We support that tmp.mount being masked, and this should not be considered an
error.
(cherry picked from commit b2c7d1bbc2243a425d9b825859bbd0647eecd050)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With the previous commit, we would not complain about the not-found path, but
the check is still not useful. We use a libc function to resolve the glob, and
it has no notion of treating autofs specially. So we can't avoid touching
autofs when resolving globs. But usually the glob is found in the last
component of the path, so if we strip the glob part, we can still do a useful
check in many cases. (E.g. if /var/tmp is on autofs, something like
"/var/tmp/<glob>" is much more likely than "/var/<glob-that-matches-tmp>/<something>".)
With the system config in F34, we check the following prefixes:
/var/tmp/abrt/* → /var/tmp/abrt/
/run/log/journal/08a5690a2eed47cf92ac0a5d2e3cf6b0/*.journal* → /run/log/journal/08a5690a2eed47cf92ac0a5d2e3cf6b0/
/var/lib/systemd/coredump/.#core*.21e5c6c28c5747e6a4c7c28af9560a3d* → /var/lib/systemd/coredump/
/tmp/podman-run-* → /tmp/
/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-*/tmp → /tmp/
/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-* → /tmp/
/tmp/containers-user-* → /tmp/
/var/tmp/beakerlib-* → /var/tmp/
/var/tmp/dnf*/locks/* → /var/tmp/
/var/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-*/tmp → /var/tmp/
/var/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-* → /var/tmp/
/var/tmp/abrt/* → /var/tmp/abrt/
/var/tmp/beakerlib-* → /var/tmp/
/var/tmp/dnf*/locks/* → /var/tmp/
/tmp/podman-run-* → /tmp/
/tmp/containers-user-* → /tmp/
/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-* → /tmp/
/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-*/tmp → /tmp/
/var/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-* → /var/tmp/
/var/tmp/systemd-private-21e5c6c28c5747e6a4c7c28af9560a3d-*/tmp → /var/tmp/
/var/lib/systemd/coredump/.#core*.21e5c6c28c5747e6a4c7c28af9560a3d* → /var/lib/systemd/coredump/
/run/log/journal/08a5690a2eed47cf92ac0a5d2e3cf6b0/*.journal* → /run/log/journal/08a5690a2eed47cf92ac0a5d2e3cf6b0/
(cherry picked from commit bd6d28f21ad212e141b5e74bd0b7ad517f64a711)
|
|
|
|
| |
(cherry picked from commit 1e472a6ce4747a1f10954fb239df73580c8e7411)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
systemd-tmpfiles[328]: Failed to determine whether '/run/cryptsetup' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/etc/resolv.conf' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/lock/subsys' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/setrans' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/console' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/faillock' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/sepermit' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/motd.d' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/motd.d' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/motd' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/run/nologin' is below autofs, ignoring: No such file or directory
systemd-tmpfiles[328]: Failed to determine whether '/var/lib/systemd/pstore' is below autofs, ignoring: No such file or directory
... and so on and so on.
(cherry picked from commit 16eff8271b402f2705d4329fa4cf5a0435e65996)
|
|
|
|
|
|
|
|
|
| |
We might get EPERM on certain clone() flag combinations. Apparently in
Docker for example.
Prompted by: https://github.com/systemd/systemd/pull/19800#issuecomment-854196491
(cherry picked from commit d414f415358846717c2260a1d931fe75d6c5f0e3)
|
|
|
|
| |
(cherry picked from commit d0fd114929d3c8d5781e10e408ec178722d2f672)
|
|
|
|
|
|
|
| |
This mimics what we do for device units: if there's a device we cannot
synthesize a good swap unit name for, then proceed without failure.
(cherry picked from commit e82c6e8b6230b237c838f053d52baa3297668eaa)
|
|
|
|
|
|
|
|
| |
If the name of the old device didn#t work for us, we don't have to clean
anything up, since we know for sure that there won't be a device unit
for it. hence downgrade log message about it.
(cherry picked from commit 4d94c74fae21f7ef02a5f14b8296a4522d6b51df)
|
|
|
|
|
|
|
|
| |
This basically does what 2c905207db37c691d4abef868165ad5ea2dd0f4f did
for mount units
Fixes: #16161
(cherry picked from commit ad172d19d5ef8b5a3631a8484cc3d1a28dba26c2)
|
|
|
|
|
|
|
| |
This reverts 72dc626b3d6905b105ae61ca2c60f51a6f74070e and replace glibc
specific macros with compiler's pre-defined macros.
(cherry picked from commit ffc36c276c47a9b3f21e83947090f11039628676)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The value is set dynamically when sd_device_get_subsystem() is called
first time.
Fixes the following issue:
```
$ build/udevadm test /sys/class/block/dm-1
...
Assertion '_subsystem' failed at src/libsystemd/sd-device/sd-device.c:767, function device_set_subsystem(). Aborting.
Program received signal SIGABRT, Aborted.
```
(cherry picked from commit 2255e8adee37c490bf8cf2daab791b6f746bb0a0)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I always found this a bit annoying.
With the patch:
$ SYSTEMD_LOG_LEVEL=debug build/udevadm test /sys/class/block/dm-1
...
Loaded timestamp for '/etc/systemd/network'.
Loaded timestamp for '/usr/lib/systemd/network'.
Parsed configuration file /usr/lib/systemd/network/99-default.link
Parsed configuration file /etc/systemd/network/10-eth0.link
Created link configuration context.
Loaded timestamp for '/etc/udev/rules.d'.
Loaded timestamp for '/usr/lib/udev/rules.d'.
...
(cherry picked from commit 0d5a24beaedb161d4f7fe07361d2a5abdbd6e736)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We had:
systemd[1]: varlink-36: New incoming message: {"method":"io.systemd.UserDatabase.GetMemberships","parameters":{"userName":"gdm","service":"io.systemd.DynamicUser"},"more":true}
systemd[1]: varlink-36: varlink: changing state idle-server → processing-method-more
systemd[1]: varlink-36: Sending message: {"error":"io.systemd.UserDatabase.NoRecordFound","parameters":{}}
systemd[1]: varlink-36: varlink: changing state processing-method-more → processed-method
systemd[1]: varlink-36: varlink: changing state processed-method → idle-server
systemd[1]: varlink-36: Got POLLHUP from socket.
systemd[1]: varlink-36: varlink: changing state idle-server → pending-disconnect
systemd[1]: varlink-36: varlink: changing state pending-disconnect → processing-disconnect
systemd[1]: varlink-36: varlink: changing state processing-disconnect → disconnected
So let's drop the "varlink:" prefix and use capitalized sentences like in other messages.
(cherry picked from commit 953394e3bb1f1ead3c1d80237b97b71835b0755a)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For new connections, we log something like this:
systemd[1]: n/a: New incoming connection.
systemd[1]: n/a: Connections of user 997: 0 (of 1024 max)
systemd[1]: varlink-22: varlink: setting state idle-server
systemd[1]: varlink-22: New incoming message: ...
This "n/a" is not very pretty, and without context it would be hard to even
figure out this is a varlink connection.
(cherry picked from commit f35e9b101d80c05d5a5eaece6e62e8eeb5743691)
|
|
|
|
|
|
| |
See #19788.
(cherry picked from commit 6be1feb1d7e30c0e7591121b74d4c3c7079de6b3)
|
|
|
|
|
|
| |
The macro __BYTE_ORDER__ is defined in endian.h.
(cherry picked from commit 72dc626b3d6905b105ae61ca2c60f51a6f74070e)
|
|
|
|
|
|
|
|
| |
It is already removed from glibc. See,
https://sourceware.org/git/?p=glibc.git;a=commit;h=16396c41deab45f715ffd813280d9d685b3b281e
https://sourceware.org/git/?p=glibc.git;a=commit;h=09a596cc2cf4e0f9f8e9f3bba4b1a97efcb13bcb
(cherry picked from commit 959ab90bbc08855ad5824efecbc03d37b3f9c982)
|