1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-18 10:04:04 +03:00

75871 Commits

Author SHA1 Message Date
Yu Watanabe
7f66a94ecf network/routing-policy-rule: introduce a generic conf-parser for [RoutingPolicyRule] sectin
This introduce config_parse_routing_policy_rule(), which wraps existing
conf parsers. With this, we can drop many custom conf parsers for
[RoutingPolicyRule], and can reuse generic conf parsers in conf-parser.[ch].
2024-08-25 06:19:51 +09:00
Yu Watanabe
f7a1e57e1f conf-parser: move config_parse_ip_protocol() from network/netdev/fou-tunnel.c
The function is generic enough. Currently it is used at only one place.
But it will be used at another place.
2024-08-25 06:18:46 +09:00
Yu Watanabe
6db311fdc8 conf-parser: introduce config_parse_uint32_flag()
This is not used currently, but will be used later.
2024-08-25 06:18:37 +09:00
Yu Watanabe
f4810fe237 conf-parser: return 1 on success
Typically, conf parsers will ignore most errors during parsing strings
and return 0. Let's return 1 on success. Otherwise it is hard to reused
these function in another conf parser.
2024-08-25 06:18:30 +09:00
Yu Watanabe
83c187f585 parse-util: drop unused parse_ip_prefix_length() 2024-08-25 06:18:30 +09:00
Yu Watanabe
74601abcdd network/routing-policy-rule: merge two conf parsers
Both conf parsers takes an integer. Only difference is the maximum
value. Let's merge them, and pass the maximum value through ltype.
2024-08-25 06:17:05 +09:00
Yu Watanabe
78ff6156d1 network/routing-policy-rule: trivial cleanups for conf-parsers
No functional change, just refactoring.
2024-08-25 06:16:29 +09:00
Yu Watanabe
e0978eb8cf network/routing-policy-rule: rename n -> rule 2024-08-25 05:38:05 +09:00
Sam James
dde6f1d745 meson: search for 'bpf-unknown-none' too
We currently search for 'bpf-gcc' and 'bpf-none-gcc'. Gentoo's
sys-devel/bpf-toolchain package uses 'bpf-unknown-none-gcc', as does Fedora's
cross-binutils. Search for this name too.
2024-08-25 02:31:59 +09:00
Yu Watanabe
07561ff414
Merge pull request #34115 from weblate/weblate-systemd-main
Translations update from Fedora Weblate
2024-08-25 02:14:37 +09:00
Temuri Doghonadze
cf4dbc97ce po: Translated using Weblate (Georgian)
Currently translated at 100.0% (253 of 253 strings)

Co-authored-by: Temuri Doghonadze <temuri.doghonadze@gmail.com>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/ka/
Translation: systemd/main
2024-08-24 12:36:53 +02:00
Yuri Chornoivan
3982d2f960 po: Translated using Weblate (Ukrainian)
Currently translated at 100.0% (253 of 253 strings)

Co-authored-by: Yuri Chornoivan <yurchor@ukr.net>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/uk/
Translation: systemd/main
2024-08-24 12:36:53 +02:00
Piotr Drąg
542165f94d po: Translated using Weblate (Polish)
Currently translated at 100.0% (253 of 253 strings)

Co-authored-by: Piotr Drąg <piotrdrag@gmail.com>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/pl/
Translation: systemd/main
2024-08-24 12:36:52 +02:00
김인수
dffe2e4e80 po: Translated using Weblate (Korean)
Currently translated at 100.0% (253 of 253 strings)

Co-authored-by: 김인수 <simmon@nplob.com>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/ko/
Translation: systemd/main
2024-08-24 12:36:52 +02:00
Yu Watanabe
4e03518b16
Merge pull request #34111 from yuwata/log_section_full_errno
network: introduce log_section_full_errno() and friends, and use them
2024-08-24 08:31:02 +09:00
Yu Watanabe
b0e6c3261c
Merge pull request #34110 from yuwata/network-routing-policy-cleanups
network/routing-policy-rule: assorted trivial cleanups
2024-08-24 08:30:48 +09:00
Yu Watanabe
4388efca4a network/routing-policy-rule: use log_section_warning_errno() 2024-08-24 00:05:49 +09:00
Yu Watanabe
75f59c6ea5 conf-parser: introduce log_section_full_errno() and friends 2024-08-24 00:05:49 +09:00
Yu Watanabe
5dc74c6667 test-network: check one more rule we configure 2024-08-23 23:57:17 +09:00
Yu Watanabe
361f70f707 network/routing-policy-rule: read FRA_PROTOCOL afer reading other properties
No functional change, just refactoring.
2024-08-23 23:57:17 +09:00
Yu Watanabe
21719d67c1 network/routing-policy-rule: add more assertions 2024-08-23 23:57:17 +09:00
Yu Watanabe
18c9e9acd5 network/routing-policy-rule: sort conf-parser prototypes 2024-08-23 23:57:13 +09:00
Yu Watanabe
407d91d872 labeler: support varlink tag 2024-08-23 16:46:16 +02:00
Lennart Poettering
a3f17a8f88 varlinkctl: output an expressive error message in case invalid method/interface names are specified
Inspired by #34098 → let's make it easier for users to understand and
correct the mistakes they made: let's early refuse invalid
interface/method names.
2024-08-23 23:10:58 +09:00
Yu Watanabe
5537e4417c updatectl: fix typo and drop space in empty lines
Follow-ups for ec15bb71c2ccd57702325a6e6626053a343f3511 (#32363).
2024-08-23 23:10:24 +09:00
Yu Watanabe
a4db21c856
Merge pull request #34108 from mrc0mmand/update-translation-files
po: update translation files
2024-08-23 23:07:57 +09:00
Frantisek Sumsal
fe82469a82 po: drop placeholders and re-add SPDX line
Follow-up for ecce45cd3f1b4d1fd7f6a6d893f7c12c47c70455.
2024-08-23 15:37:23 +02:00
Frantisek Sumsal
8516c2eeba po: update translation files 2024-08-23 15:36:10 +02:00
Yu Watanabe
d8e298c497
Merge pull request #34102 from yuwata/udev-net_id
udev/net_id: trivial cleanups
2024-08-23 18:06:06 +09:00
Yu Watanabe
b9142e2ba7 udevadm/test,test-builtin: enable debugging logs by default again
The lines were mistakenly dropped by
aa976d87889ae22b7347787a1ebd03a31dcc0a9e.
2024-08-23 17:34:14 +09:00
Yu Watanabe
02b88d6c62 udev/net_id: update log messages
This also downgrades the log level of a message to debug.
2024-08-23 10:21:11 +09:00
Yu Watanabe
8c6f484595 udev/net_id: move naming scheme check
We usually do not set r = -1 when a functionality is disabled or not
supported. Even though the error code is not used, let's set a negative
errno in such case.

No functional change, just refactoring.

Follow-up for 0a4ecc54cb9f2d3418b970c51bfadb69c34ae9eb.
2024-08-23 10:20:56 +09:00
Yu Watanabe
ab61b8865b test: use ASSERT_EQ_ID128() and ASSERT_NE_ID128() 2024-08-23 10:18:08 +09:00
Etienne Champetier
448f9f81fd udev-builtin-net_id: ignore firmware_node/sun == 0
Since ID_NET_NAME_SLOT was introduced we ignore slot == 0
0035597a30/src/udev/udev-builtin-net_id.c (L139)

Qemu sets _SUN to PCI_SLOT() for all NICs, so _SUN is not unique.
https://gitlab.com/qemu-project/qemu/-/issues/2530

In my tests with libvirt I can only set 'slot="0x00"' in interface definition,
so all NICs end up with _SUN == 0, and this commit is enough to avoid the issue.

Fixes 0a4ecc54cb9f2d3418b970c51bfadb69c34ae9eb
2024-08-23 09:30:49 +09:00
Yu Watanabe
b6b9ddb2b5
Merge pull request #34087 from DaanDeMeyer/nspawn-init-revert
Revert "nspawn: Allow specifying custom init program"
2024-08-23 07:42:16 +09:00
Yu Watanabe
6b0561d86a
Merge pull request #34092 from poettering/ambient-caps-fixup
minor tweaks to the recent ambient caps rework
2024-08-23 06:41:45 +09:00
Yu Watanabe
a3b571b2cc
Merge pull request #34096 from YHNdnzj/logind-followup-256
logind: two follow-ups
2024-08-23 05:38:18 +09:00
Lennart Poettering
167808c6fc boot: use MAX() where appropriate 2024-08-23 05:26:35 +09:00
Yu Watanabe
ce4c4f4c32
Merge pull request #34097 from YHNdnzj/journal-browse-prepare
shared/logs-show: introduce journal_browse_prepare()
2024-08-23 05:25:19 +09:00
Daan De Meyer
615226abd8 Revert "nspawn: Allow specifying custom init program"
I don't actually need this anymore since we're going with a
unit based approach for the containers stuff internally so
let's just revert it.

Fixes #34085

This reverts commit ce2291730d5f91190e97e7c515ac772ae4970062.
2024-08-22 22:20:42 +02:00
Daan De Meyer
6a30e66df5 Revert "nspawn: fix settings leak for init parameter"
This reverts commit 1e2aa88bb238299cd982f9e3f14812a6c7211d31.
2024-08-22 22:20:36 +02:00
Adrian Vovk
e7416c9d42
sysupdate: Add tests for incomplete versions
To make sure we don't regress on #33339
2024-08-22 16:00:47 -04:00
Adrian Vovk
631803cccd
sysupdate: Repair incomplete versions in-place
A previous commit made sysupdate recognize installed versions where some
transfers are missing. This commit teaches sysupdate how to correctly
repair these incomplete versions.

Previously, if you had a incomplete installation of the OS booted, and
ran sysupdate in an attempt to repair it, sysupdate would make things
worse by creating copies of the currently-booted partitions in the
inactive slots. Then at boot you have two identical partitions, with
identical labels an UUIDs, and end up with a mess.

With this commit, sysupdate is able to recognize situations where it can
simply download the missing transfers and leave the rest of the system
undistrubed.

Partial fix for https://github.com/systemd/systemd/issues/33339
2024-08-22 16:00:46 -04:00
Adrian Vovk
57ada07e7a
sysupdate: Track incompletely-installed versions
When enumerating what versions exist for a given target, sysupdate would
completely throw out any version that's incomplete (where some of the
transfers in the target have that version installed or available, and
other transfers do not).

If we're trying to find what versions we can offer for download, this is
great behavior. If the server side is advertising a partial update to
download, we shouldn't present it to the user.

On the other hand, if we're enumerating what versions we have currently
installed, this is a bad behavior. It makes sysupdate fragile. For
example, if a sysext introduces a new .conf file into
/usr/lib/sysupdate.d, suddenly the currently-installed OS stops being a
version that we've enumerated. Since it's not enumerated, it's not
protected, and so sysupdate will wipe the booted OS.

So if we're looking for installed versions, we now loosen the
restrictions and enumerate incomplete installations.

Partial fix for https://github.com/systemd/systemd/issues/33339
2024-08-22 16:00:45 -04:00
Adrian Vovk
0402bf682f
sysupdate: Check that --instances-max is in bounds
Otherwise user can pass in --instances-max=0 and crash sysupdate with an
assertion failure.
2024-08-22 16:00:44 -04:00
Adrian Vovk
7934803634
sysupdate: Fix resource_find_instance
The current implementation will never find a match, because in the event
of a match instance_cmp falls through to comparing paths and the key
we're matching against will always have a path of NULL.

So let's just use a separate compare function, just to make sure future
updates to instance_cmp don't break resource_find_instance again.
2024-08-22 16:00:43 -04:00
Mike Yuan
fad3feec12
shared/logs-show: introduce journal_browse_prepare()
which combines sigbus_install() and bumping fd limit.
2024-08-22 20:33:22 +02:00
Mike Yuan
d71f138156
basic/sigbus: use FOREACH_ELEMENT where appropriate, assert >= 0 for success 2024-08-22 20:14:25 +02:00
Mike Yuan
26f78eff69
logind-session: downgrade user@.service dep to Wants=
This partially reverts 52bcc872b5f97a14a9b4e4e383f45bb3066e1643.

We explicitly support running without user manager,
hence only user-runtime-dir@.service should be
required.

Fixes #33405
2024-08-22 20:07:47 +02:00
Mike Yuan
1aeea8a60a
logind: DesignatedMaintenanceTime is added in v257 and constant
Follow-up for 0e10c3d8724b0a5d07871c9de71565ac91dd55b7

Addresses https://github.com/systemd/systemd/pull/25049#discussion_r1647513862
2024-08-22 20:06:31 +02:00