Commit Graph
75378 Commits
Author SHA1 Message Date
Yu Watanabe 175cdefd33 man: suggest to enable global IPv6Forwarding= setting to make IPv6 packets forwarded
Closes #33414.
2024-07-31 09:53:18 +02:00
Yu Watanabe acda1b3f2a NEWS: mention that udevadm test and test-builtin are now non-destructive
Follow-up for 089bef6631.
Prompted by https://github.com/systemd/systemd/issues/33619#issuecomment-2257576579.
2024-07-31 10:06:25 +09:00
Yu Watanabe dd87ad8e19 network: mention that IPv4 ACD is enabled by default for 169.254.0.0/16
Prompted by #33824.
2024-07-31 10:06:25 +09:00
Yu Watanabe e2becab085 network: request non-NULL SSID when a wlan interface is configured as station
To avoid conflicts with user .network file for the wlan interface with Bond=.
See https://github.com/systemd/systemd/issues/19832#issuecomment-857661200.
2024-07-31 10:06:04 +09:00
Yu Watanabe 6d0cdbe0bc Merge pull request #33878 from yuwata/network-bind-carrier
network: several cleanups for BindCarrier= setting
2024-07-31 10:05:43 +09:00
Yu Watanabe 356f25ab85 Merge pull request #33875 from yuwata/network-link-get-address
network: several fixlets related to link_get_address()
2024-07-31 10:05:11 +09:00
Yu Watanabe ba7c4bd6f2 network: shorten code a bit 2024-07-31 06:47:33 +09:00
Yu Watanabe 36b8ad085c network: call link_handle_bound_by_list() before trying to reconfigure interface
Otherwise, when an interface gained its carrier, the interface may not
have matching .network file yet, then link_reconfigure_impl() returns
zero, and link_handle_bound_by_list() is skipped.

Fixes #33837.
2024-07-31 06:47:11 +09:00
Ivan Shapovalov 7767896d12 Revert "network/ndisc: ignore most fields of RA header when lifetime is zero"
This reverts commit ffef01acdd.

Similar to 2d393b1b6d ("network: IPv6 Compliance: Router Advertisement
Processing, Reachable Time [v6LC.2.2.15]"),

Extract from: https://www.ietf.org/rfc/rfc4861.html#section-4.2, p.21,
first paragraph:

    The Router Lifetime applies only to
    the router's usefulness as a default router; it
    does not apply to information contained in other
    message fields or options.

So it does not make sense to prevent DHCPv6 when Router Lifetime is 0.

Fixes #33357.
2024-07-30 22:42:56 +02:00
Daniel P. Berrangé 9d7be044ca Fix detection of TDX confidential VM on Azure platform
The original CVM detection logic for TDX assumes that the guest can see
the standard TDX CPUID leaf. This was true in Azure when this code was
originally written, however, current Azure now blocks that leaf in the
paravisor. Instead it is required to use the same Azure specific CPUID
leaf that is used for SEV-SNP detection, which reports the VM isolation
type.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2024-07-30 22:39:20 +02:00
Yu Watanabe f320c0777a test-network: add test case for preferred source with peer
For issue #31950.
2024-07-31 05:36:14 +09:00
Yu Watanabe 56f91e2d0b network: make link_get_address() provide matching address with peer
As all callers do not care if the address has peer address.
This also drops prefixlen argument as it is always zero.

Fixes a bug introduced by 42f8b6a808.
Fixes #31950.
2024-07-31 05:36:14 +09:00
Yu Watanabe d9ef1cc407 network/ipv4acd: manage ACD engines with Address object
IPv4 addresses are managed with local and peer addresses and prefix
length. So, potentially, the same address with different prefix length
can be assigned on a link, e.g. 192.168.0.1/24 and 192.168.0.1/26.
If one of the address is configured with ACD but the other is not,
then previously ACD might be unexpectedly disabled or enabled on them,
as we managed ACD engines with only local addresses.

This makes ACD engines managed with the corresponding Address objects.
2024-07-31 05:35:20 +09:00
Yu Watanabe e8eaed0240 network: do not bring down bound interfaces immediately
Even if a timespan specified to IgnoreCarrierLoss= for an interface,
when the carrier of the interface lost, bound interfaces might be bring
down immediately.

Let's also postpone bringing down bound interfaces with the specified
timespan.
2024-07-31 05:27:19 +09:00
Arian van Putten a55d1b29a4 document how TimeoutStartSec= affects notify-reload (#33653)
* document how TimeoutStartSec=  affects notify-reload
2024-07-30 12:35:52 +01:00
Yu Watanabe 1bfa47418e nspawn: remove macvlan interfaces before network namespace died
This is similar to what we do for veth interfaces in remove_veth_links().

When a container rebooted, macvlan interfaces created by the previous
boot may still exist in the kernel, and that causes -EADDRINUSE after
reboot.

Hopefully fixes #680.
2024-07-30 12:38:50 +02:00
Daan De Meyer b56920e36c kernel-install: Try some more initrd variants in 90-loaderentry.install
On CentOS/Fedora, dracut is configured to write the initrd to
/boot/initramfs-$KERNEL_VERSION...img so let's check for that as well
if no initrds were supplied.
2024-07-29 18:57:43 +02:00
Daan De Meyer 35c01ec59e kernel-install: Only read cmdline from /proc/cmdline when not in container
If we're running from within a container, we're very likely not going
to want to use the kernel command line from /proc/cmdline, so let's add
a check to see if we're running from a container to decide whether we'll
use the kernel command line from /proc/cmdline.
2024-07-29 18:56:30 +02:00
Daan De Meyer 7fe0ea2ead Merge pull request #33857 from DaanDeMeyer/mkosi
Two small improvements
2024-07-29 15:40:48 +02:00
Daan De Meyer ecfdecfd6a docs: Simplify hacking instructions a bit
We enable RuntimeBuildSources=yes by default so let's drop it from
the documentation.
2024-07-29 13:42:28 +02:00
Daan De Meyer 578ee05155 test: Don't mount build sources into image when running non-interactively 2024-07-29 13:40:42 +02:00
Martin Srebotnjak be2ad93af3 po: Translated using Weblate (Slovenian)
Currently translated at 100.0% (233 of 233 strings)

Co-authored-by: Martin Srebotnjak <miles@filmsi.net>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/sl/
Translation: systemd/main
2024-07-29 10:16:40 +01:00
Luca Boccassi 0fa53f5dd7 Merge pull request #33853 from NickCao/l3mdev
network: Fixup Table when L3MasterDevice is set on routing policy rule
2024-07-29 10:15:52 +01:00
Nick Cao 615af2c77d network: Fixup Table when L3MasterDevice is set on routing policy rule 2024-07-28 14:02:07 -04:00
Nick Cao 034b7dfc08 man: network: move note about L3MasterDevice to the correct section 2024-07-28 13:51:36 -04:00
Vladimir Panteleev 3f24fa57df man: clarify systemd-path variable source 2024-07-28 10:33:49 +01:00
Vladimir Panteleev 6c1e0823b0 man: improve ManagerEnvironment documentation
- Improve wording for explanation when these variables are inherited

- Clarify that these variables are not placed in the process environment block,
  so /proc/PID/environ cannot be used as a debugging tool
2024-07-28 10:33:17 +01:00
Luca Boccassi 0462e902bf Merge pull request #33848 from weblate/weblate-systemd-main
Translations update from Fedora Weblate
2024-07-27 11:27:29 +01:00
Weblate Translation Memory 7f8b46724f po: Translated using Weblate (Slovenian)
Currently translated at 100.0% (233 of 233 strings)

Co-authored-by: Weblate Translation Memory <noreply-mt-weblate-translation-memory@weblate.org>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/sl/
Translation: systemd/main
2024-07-26 16:38:49 +02:00
Martin Srebotnjak 3607e0cf52 po: Translated using Weblate (Slovenian)
Currently translated at 100.0% (233 of 233 strings)

Co-authored-by: Martin Srebotnjak <miles@filmsi.net>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/sl/
Translation: systemd/main
2024-07-26 16:38:49 +02:00
Jose Ignacio Tornos Martinez eef4cd51f9 kernel-install: remove depmod generated file modules.weakdep
The new file, modules.weakdep, generated by depmod to get the weak
dpendencies information can be present
(https://github.com/kmod-project/kmod/commit/05828b4a6e9327a63ef94df544a042b5e9ce4fe7),
so remove it like the other similar files.

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-07-26 14:02:14 +01:00
Luca Boccassi 85c7a9a2f5 Merge pull request #27855 from Werkov/test-delegate-useraddfixup
Delegate/cgroup test refactor
2024-07-26 14:01:38 +01:00
Zbigniew Jędrzejewski-Szmek e520b1258c Merge pull request #30307 from bluca/enforce_inhibitors
logind: always check for inhibitor locks
2024-07-26 13:52:34 +02:00
Ronan Pigott cd2ce31adb resolved: Don't retry queries that indicate net error
This probably rarely helped anyway, but it also in some cases interferes
with auxiliary dnssec queries where the authoritative nameserver does
not support EDNS0/DNSSEC.

Fixes: ac6844460c ("resolved: support RFC 8914 EDE error codes")
2024-07-26 10:04:36 +01:00
Luca Boccassi 281b0bfbed Merge pull request #33842 from DaanDeMeyer/test
Two fixes
2024-07-26 10:04:20 +01:00
Michal Koutný 3e6e3e6d40 test: Fail cgroup delegation test when user cannot be created
It means: a) user cannot be created, something's wrong in the
test environment -> fail the test; b) user already exists, we shall not
continue and delete (foreign) user.
2024-07-26 10:44:10 +02:00
Daan De Meyer ae07feb401 resize-fs: Put minimal ext4 size in the same ballpark as the other filesystems
TEST-46-HOMED fails on ext4 because the filesystem is deemed to small
for activation by cryptsetup. Let's bump the minimal filesystem size for
ext4 a bit to be in the same ballpark as ext4 and btrfs to avoid weird
errors due to impossibly small filesystems.

Also use U64_MB while we're touching this.
2024-07-26 08:27:24 +02:00
Michal Koutný 4f0541dc59 test: Reorganize testcase of cgroup delegation
There are multiple subtests, just move them around into functions
(leveraging the testcase_* convention) to make space for new related
subtests.
2024-07-25 17:29:42 +02:00
Luca Boccassi 7020fa8feb Merge pull request #33825 from DaanDeMeyer/chattr
repart: Create disk image file with copy-on-write disabled on btrfs
2024-07-25 14:11:11 +01:00
Luca Boccassi 9ce9dece4f shell completion: add support for sd-analyze capability --mask
Follow-up for 3e7a029c28
2024-07-25 13:22:27 +01:00
Luca Boccassi a6bcab05df Merge pull request #33840 from bluca/test_locale_dbus
test: fix D-Bus policy override for TEST-73-LOCALE
2024-07-25 13:18:53 +01:00
Luca Boccassi a1f427ab41 NEWS: mention logind inhibitors change 2024-07-25 12:22:37 +01:00
Luca Boccassi 804874d26a logind: always check for inhibitor locks
Currently inhibitors are bypassed unless an explicit request is made to
check for them, or even in that case when the requestor is root or the
same uid as the holder of the lock.

But in many cases this makes it impractical to rely on inhibitor locks.
For example, in Debian there are several convoluted and archaic
workarounds that divert systemctl/reboot to some hacky custom scripts
to try and enforce blocking accidental reboots, when it's not expected
that the requestor will remember to specify the command line option
to enable checking for active inhibitor locks.

Also in many cases one wants to ensure that locks taken by a user are
respected by actions initiated by that same user.

Change logind so that inhibitors checks are not skipped in these
cases, and systemctl so that locks are checked in order to show a
friendly error message rather than "permission denied".

Add new block-weak and delay-weak modes that keep the previous
behaviour unchanged.
2024-07-25 12:22:36 +01:00
Daan De Meyer ebe17e3f9e TEST-54-CREDS: Specify SMBIOS creds via corresponding mkosi option
This allows mkosi to combine fstab.extra with its own fstab.extra so
that it doesn't override the one we pass for the test.
2024-07-25 13:12:16 +02:00
David Tardon 7a64c5f23e sd-event: do not assert on invalid signal
The signalfd_siginfo struct is received from outside via a FD, hence
assert() is not appropriate way to check it. Just do a normal runtime
check.
2024-07-25 11:57:05 +01:00
David Tardon 639719e010 logind-dbus: check auth. for all inhibitor operations
Fixes #33834
2024-07-25 11:55:39 +01:00
Jeffrey Bosboom f7fa632682 docs/CONTROL_GROUP_INTERFACE.md: document accounting information available via D-Bus 2024-07-25 11:46:18 +01:00
Luca Boccassi 3bf483fc4f Merge pull request #33727 from intelfx/work/analyze-capability-masks
analyze: capability: add support for decoding capability masks
2024-07-25 11:08:21 +01:00
Mike Yuan 268f58076f basic/log: do not treat all negative errnos as synthetic
Currently, IS_SYNTHETIC_ERRNO() evaluates to true for all negative errnos,
because of the two's-complement negative value representation.
Subsequently, ERRNO= is not logged for most of our own code.
Let's fix this, by formatting all synthetic errnos as positive.
Then, treat all negative values as non-synthetic.

While at it, mark the evaluation order explicitly, and remove
unneeded comment.

Fixes #33800
2024-07-25 12:03:59 +02:00
Daan De Meyer 42e9288180 tree-wide: Don't explicity disable copy-on-write when copying images
Since the copy helpers now copy file attributes as well, let's not
explicitly disable copy-on-write anymore when we copy an image. If
the source already has copy-on-write disabled, the copy will have it
disabled as well. Otherwise, the copy will also have copy-on-write
enabled.

This makes sure that reflinks always work as reflink is only supported
if both source and target are copy-on-write or both source and target
are not copy-on-write.
2024-07-25 11:56:07 +02:00