1
0
mirror of https://github.com/systemd/systemd.git synced 2025-02-04 21:47:31 +03:00

71548 Commits

Author SHA1 Message Date
Sam Leonard
b0dc766852
vmspawn: support machined registration 2024-02-28 17:49:00 +00:00
Lennart Poettering
6aa14b283b
Merge pull request #31514 from CodethinkLabs/ptyfwd_issues
ptyfwd/terminal-util: improve edge case handling
2024-02-28 18:36:50 +01:00
Lennart Poettering
f0ecff8506 dissect: condition usespace verity keyring via kernel cmdline option + env var 2024-02-28 16:18:22 +01:00
Lennart Poettering
f4a63ce25f dissect-image: add flag for explicitly enabling userspace verity signature checking
let's make userspace verity signature checking optional. This adds a
dissection flag to enable the logic and patches through all our users to
enable it by default, thus effectively not changing anything from the
status quo ante. However, know we have a knob to turn this off in
certain scenarios.
2024-02-28 16:17:40 +01:00
Lennart Poettering
dbe253aa9d env-util: also rename getenv_uint64_secure() → secure_getenv_uint64()
As in the previous commit, let's not change the order of the words
compared to the underlying glibc API.
2024-02-28 15:38:00 +01:00
Lennart Poettering
efb9b3bab2 env-util: rename getenv_bool_secure() → secure_getenv_bool()
The glibc API is behind the wrapper is called "secure_getenv()", hence
our wrapper really should keep the order too, otherwise things are just
too confusing.
2024-02-28 15:38:00 +01:00
Lennart Poettering
dc9a56d83e man: add a few missing entries to kernel-command-line man page 2024-02-28 15:33:51 +01:00
Lennart Poettering
78266a54f1 tree-wide: use "_" rather than "-" as separator in kernel cmdline options
Most of our kernel cmdline options use underscores as word separators in
kernel cmdline options, but there were some exceptions. Let's fix those,
and also use underscores.

Since our /proc/cmdline parsers don't distinguish between the two
characters anyway this should not break anything, but makes sure our own
codebase (and in particular docs and log messages) are internally
consistent.
2024-02-28 15:33:51 +01:00
Frantisek Sumsal
78816ce72e
Merge pull request #31444 from bluca/semaphore
semaphore: set upstream build profile and set default branch to debian/master
2024-02-28 15:03:11 +01:00
Luca Boccassi
0cad991c4c
Merge pull request #31293 from ragazenta/netdev_rps
udevd: Add ReceivePacketSteeringCPUMask for systemd.link
2024-02-28 13:37:28 +00:00
Lennart Poettering
6a145157eb resolved: exit function if varlink_dispatch() returns > 0
varlink_dispatch() returns > 0 if it already replied to the method call,
hence this is reason to return from the handler function, and not
proceed.
2024-02-28 13:35:47 +00:00
Lennart Poettering
f9f5ce61fa userbdb: pass log level from main daemon to worker 2024-02-28 12:42:06 +00:00
Susant Sahani
de736b9658 test-network: Add test for bond peer_notif_delay 2024-02-28 17:34:54 +05:30
Susant Sahani
00386d5b3f netdev: bond - add support for peer_notif_delay
Specify the delay, in milliseconds, between each peer
notification (gratuitous ARP and unsolicited IPv6
Neighbor Advertisement) when they are issued after
a failover event. This delay should be a multiple of
the MII link monitor interval (miimon).

 The valid range is 0 - 300s. The default value is 0,
which means to match the value of the MII link monitor interval.
2024-02-28 17:31:02 +05:30
Sam Leonard
d848a94998
shared/ptyfwd: detect String Terminator or BEL when parsing an OSC sequence 2024-02-28 11:50:18 +00:00
Sam Leonard
9eb118eea7
shared/ptyfwd: allow window title but not background color as a valid state
Previously if a PTYForward instance had the window title set but no
background color set then it would crash in an assertion as
pty_forward_ansi_process didn't require both to be present.

systemd-vmspawn could get into this state if it failed to get the
terminal tint color.

Now any method that would have called background_color_sequence now
becomes just a NOP if the background color is not set.

This allows keeping the functionality to set window titles even if the
terminal doesn't support the background coloring.
2024-02-28 11:50:18 +00:00
Sam Leonard
73a72e3a7b
basic/terminal-util: accept ST or BEL to end escape sequence queries
Currently scan_background_color_response only accepts BEL (\x07) to end
a response, however some terminals (namely kitty in my case) will reply
with the string terminator (ST - https://en.wikipedia.org/wiki/ANSI_escape_code).

This commit changes the behaviour to now accept either ending.
2024-02-28 11:50:18 +00:00
Sam Leonard
9924d3c595
basic/terminal-util: add check for poll timeout in get_default_background_color
Currently the return value 0 is not checked for, this indicates a
timeout and should be handled to prevent doing a blocking read on a file
descriptor with no data ready.
2024-02-28 11:50:17 +00:00
Yu Watanabe
39af486a7f network/ndisc: drop redundant sd_ndisc_router_get_icmp6_ratelimit()
This effectively reverts 9175002864d8876f375e0df089d142d239282528.

The retrans time field in RA message is for neighbor solicitation,
and the commit d4c8de21a07d015f2f2c787e0735be5e4d02fb3c makes the value
assigned to the correct sysctl property.

Let's deprecate the option, and drop the redundant functions.
2024-02-28 11:05:00 +00:00
Lennart Poettering
29eddf0ea4 nspawn: minor coding style tweaks to nspawn-register.c 2024-02-28 11:07:58 +01:00
Zbigniew Jędrzejewski-Szmek
ab95ba1558
Merge pull request #31511 from jamacku/prepare-for-diff-shellcheck
Prepare for new version of Differential ShellCheck & scanning of shell completion scripts
2024-02-28 10:28:56 +01:00
Yu Watanabe
9398ef0786 cgroup-setup: clarify '<=' is evaluated earlier
Follow-up for 31323f21bb0ae7c712f43500c42997c91a6d20bf.

The code is correct, but let's silence Coverity.

Closes CID#1534787.
2024-02-28 14:11:43 +08:00
Renjaya Raga Zenta
a6f5673c99 test-network: Add test for rps_cpu_mask option 2024-02-28 11:37:18 +07:00
Renjaya Raga Zenta
0f30bf5886 udevd: Add ReceivePacketSteeringCPUMask for systemd.link
Takes a list of CPU indices or ranges separated by either whitespace or commas. Alternatively,
takes the special value "all" in which will include all available CPUs in the mask.
CPU ranges are specified by the lower and upper CPU indices separated by a dash (e.g. "2-6").
This option may be specified more than once, in which case the specified CPU affinity masks are merged.
If an empty string is assigned, the mask is reset, all assignments prior to this will have no effect.
Defaults to unset and RPS CPU list is unchanged. To disable RPS when it was previously enabled, use the
special value "disable".

Currently, this will set CPU mask to all `rx` queue of matched device (if it has multiple queues).

The `/sys/class/net/<dev>/queues/rx-<n>/rps_cpus` only accept cpu bitmap mask in hexadecimal.

Fix: #30323
2024-02-28 11:35:36 +07:00
Yu Watanabe
630023e2e4 TODO: fix typo
Follow-up for 666a348d1c98873c55115924751e6f2d3bdb7435.
2024-02-28 11:46:21 +09:00
Yu Watanabe
c4047829bb test-network: fix typo
Follow-up for a663ddc04e43a9234e00e47aed98bf2bbeb1573a.
2024-02-28 11:44:20 +09:00
Yu Watanabe
25413fbfc7 sd-ndisc: ignore Router Advertisement messages sent by the same interface 2024-02-28 11:40:50 +09:00
Yu Watanabe
c34cb1d645 sd-ndisc: use ICMP6Packet and ndisc_option_parse() 2024-02-28 11:37:36 +09:00
Yu Watanabe
45edf75c61 sd-ndisc: introduce ndisc_option_parse() helper function 2024-02-28 11:26:52 +09:00
Yu Watanabe
07db3ac66c icmp6-packet: introduce ICMP6Packet and several relevant functions 2024-02-28 11:26:39 +09:00
Luca Boccassi
d6e98b3d16 semaphore: set upstream build profile and set default branch to debian/master
Leave TEST_UPSTREAM=1 for now in case we switch branches via the hook
2024-02-28 01:08:57 +00:00
Luca Boccassi
4117a0d5e6 semaphore: enable backports to get new dependencies
Required due to building with debian/master branch
2024-02-28 01:08:57 +00:00
Luca Boccassi
132f785429 test/README: document how to add a new empty release to the PPA to migrate the CI to a new version 2024-02-28 01:08:57 +00:00
Luca Boccassi
f6387e7e3f test/README: update ubuntu IRC channel for CI help 2024-02-28 01:08:57 +00:00
Luca Boccassi
8040fa55a1 install: fix compiler warning about empty directive argument
On ppc64el with gcc 13.2 on Ubuntu 24.04:

3s In file included from ../src/basic/macro.h:386,
483s                  from ../src/basic/alloc-util.h:10,
483s                  from ../src/shared/install.c:12:
483s ../src/shared/install.c: In function ‘install_changes_dump’:
483s ../src/shared/install.c:432:64: error: ‘%s’ directive argument is null [-Werror=format-overflow=]
483s   432 |                         err = log_error_errno(changes[i].type, "Failed to %s unit, unit %s does not exist.",
483s       |                                                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
483s ../src/shared/install.c:432:75: note: format string is defined here
483s   432 |                         err = log_error_errno(changes[i].type, "Failed to %s unit, unit %s does not exist.",
2024-02-28 01:08:56 +00:00
Luca Boccassi
47c2a6e958
Merge pull request #31515 from keszybz/small-cleanups-after-review-of-stable-batch
Small cleanups after review of stable batch
2024-02-27 20:07:18 +00:00
Luca Boccassi
5b0addafab
Merge pull request #31442 from YHNdnzj/towards-cgroup-v1-deprecation
core: refuse cgroupv1 unless SYSTEMD_CGROUP_ENABLE_LEGACY_FORCE
2024-02-27 19:21:35 +00:00
Štěpán Němec
0f1a5ecc1a tmpfiles.d: avoid deprecated, undocumented syntax (s/F/f+/)
Fixes: eccebf4b0dcb ("systemd-tmpfiles: deprecate F for f+")
2024-02-27 19:21:06 +00:00
Antonio Alvarez Feijoo
532de87f74 core: remove duplicate serialization of cpu_sched_reset_on_fork
`c->cpu_sched_reset_on_fork` is serialized using
`exec-context-cpu-sched-reset-on-fork` and
`exec-context-cpu-scheduling-reset-on-fork`. Let's keep only the second one, to
serialize the value only if `cpu_sched_set` is true.
2024-02-27 19:20:44 +00:00
Jan Engelhardt
4094130b6f test: drop route from test-functions
I do not see `route` being exercised anywhere else, everything seems
to be on `ip route` already.
2024-02-27 17:51:56 +00:00
Zbigniew Jędrzejewski-Szmek
f7364e1a51 shared/pam-util: fix awkward tense in log message 2024-02-27 18:32:51 +01:00
Zbigniew Jędrzejewski-Szmek
2dc65c32b2 virt: wrap comment, add missing punctuation 2024-02-27 18:32:21 +01:00
Zbigniew Jędrzejewski-Szmek
3e6b040bec man/sd_bus_service_reconnect.c: normalize whitespace
For man pages, we generally indent with 2 spaces and wrap to ~80 columns.
2024-02-27 18:15:51 +01:00
Štěpán Němec
c959e17823 man, shell-completion: fix a few typos/language issues 2024-02-27 16:57:33 +00:00
Lennart Poettering
b96df6fa09 bootspec: don't complain about valid loader.conf settings
Let's not complain about various valid loader.conf settings we more
recently added. At the same time let's remove the half-assed userspace
parsers for the fields we actually do support but don't actually really
care about in userspace. There's really no point in storing strings away
that we are not using at all, hence just don#t.

Fixes: #31487
2024-02-27 16:57:19 +00:00
Jan Macku
c1631d4e49 ci(labeler): add rule for shell-completion label 2024-02-27 15:26:45 +00:00
Frantisek Sumsal
cc48d93870 test: use socat in unidirectional mode
By default socat open a separate r/w channel for each specified address,
and terminates the connection after .5s from receiving EOF on _either_
side. And since one side of that connection is an empty stdin, we reach
that EOF pretty quickly. Let's avoid this by using socat in
"reversed unidirectional" mode, where the first address is used only for
writing, and the second one is used only for reading.

Addresses:
  - https://github.com/systemd/systemd/issues/31500
  - https://github.com/systemd/systemd/issues/31493

Follow-up for 3456c89ac26.
2024-02-27 15:24:23 +00:00
Mike Yuan
6b19d5f021
NEWS: announce cgroup v1 deprecation 2024-02-27 23:10:50 +08:00
Mike Yuan
31323f21bb
meson: drop default-hierarchy= option, always use unified 2024-02-27 23:10:49 +08:00
Mike Yuan
f2512de82d
core: refuse cgroupv1 unless SYSTEMD_CGROUP_ENABLE_LEGACY_FORCE
Also, add a 30s sleep even if cgroup v1 is forced.

Closes #30852
2024-02-27 23:10:49 +08:00