1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-03-10 00:58:20 +03:00

49181 Commits

Author SHA1 Message Date
Julia Cartwright
afe6a9c48e man: fix misspellings of "NameSeviceSwitch"
Fixup NameSeviceSwitch -> NameServiceSwitch spelling error in
documentation.

Found through inspection of documentation.
2021-02-06 00:00:44 +00:00
Weblate (bot)
33c85738ee
Translations update from Weblate (#18485)
* Translated using Weblate (Swedish)

Currently translated at 100.0% (189 of 189 strings)

Translation: systemd/main
Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/sv/

Co-authored-by: Göran Uddeborg <goeran@uddeborg.se>
2021-02-05 23:54:58 +00:00
Lennart Poettering
5055b51ee1 github: ask for systemd version in RFE form
It happens too often that what people ask for already is implemented.
Let's help cut the noise a bit, and make people check things first
hopefully, and at least make it either for us to detect such cases.
2021-02-05 23:42:47 +00:00
Lennart Poettering
f8f5b8d864 resolved: suppress ifindex info in varlink JSON responses if zero
If we don't have ifindex info, don't set the field for it.

We already do that for parsed IP address replies, let's do it for all
cases: it's a bit nicer to suppress the ifindex prop if it doesn't apply
than to pass it invalid.

This is the other side of #18482, i.e. fixes things so that the parser
doesn't get tripped up by this.

(This too makes a problem go away we should track down properly, i.e.
figure out how the ifindex got lost in
https://github.com/systemd/systemd/pull/17823#issuecomment-742439422 )
2021-02-06 00:17:10 +01:00
Lennart Poettering
9c09454dce
Merge pull request #18482 from poettering/resolved-nss-varlink-ifindex-fix
nss-resolve: handle zero ifindex reply from server
2021-02-06 00:16:28 +01:00
Lennart Poettering
425ed13991 nss-resolve: shortcut fixing of ifindex if it's zero anyway 2021-02-05 18:46:18 +01:00
Lennart Poettering
6da52ca861 nss-resolve: accept zero ifindex when parsing resolved reply
Sometimes a reply isn't associated to any specific interface, it might
be a general truth (for example served from /etc/hosts or so). In this
case the server might pass ifindex == 0. Accept that.

https://github.com/systemd/systemd/pull/17823#issuecomment-742439422
2021-02-05 18:44:22 +01:00
Lennart Poettering
cb3363ef7a
Merge pull request #18318 from yuwata/network-route-table-name
network: RouteTable= improvements
2021-02-05 18:08:56 +01:00
Ali Abdallah
3deed59afd PATCH] Always free deserialized_subscribed on reload
Otherwise, it will keep consuming memory on systemctl daemon-reload.
2021-02-05 18:04:55 +01:00
Lennart Poettering
ca9fab8896 Revert "resolvectl: Add show-multicast verb to show discovered LLMNR/mDNS hosts" 2021-02-05 09:23:05 +09:00
Lennart Poettering
a24fb9b2ce
Merge pull request #18472 from poettering/conservative-rename-fix
fix conservative_renameat()
2021-02-04 22:08:47 +01:00
Yu Watanabe
7bac23e8af man: fix typo 2021-02-04 19:17:50 +01:00
Zbigniew Jędrzejewski-Szmek
29eb0eefd1 core: map io.bfq.weight to 1..1000
Aaargh. See the comment in the code.

Apparently the range is like that:
$ sudo bash -c 'echo "default 1001" >/sys/fs/cgroup/user.slice/io.bfq.weight'
bash: line 0: echo: write error: Numerical result out of range

$ uname -r
5.11.0-0.rc4.129.fc34.x86_64
2021-02-04 19:15:03 +01:00
Lennart Poettering
06fed305d4 test-fs-util: beef up test for conservative_renameat()
Instead of using a short fixed string, let's use a huge blob for
testing, with randomized size and contents, that definitely is above the
16K buffer size conservative_renameat() uses internally.
2021-02-04 18:25:25 +01:00
Lennart Poettering
eff57d1c2f fs-util: make sure conservative_renameat() properly detects identity of longer files
The old code got confused with files with a size >16K. Let's fix that.

Noticed by @benjarobin

Replaces: #18442
2021-02-04 18:25:25 +01:00
David Edmundson
84c46fb03c xdg-autostart: Generate autostart services with templated name
The "XDG standardization for applications" specification states that
services should be in the form:

app[-<launcher>]-<ApplicationID>[@<RANDOM>].service or
app[-<launcher>]-<ApplicationID>-<RANDOM>.scope

In this case "autostart" takes the place of [RANDOM] to provide a unique
identifier if the same app is launched elsewhere. As it is a service
that means it should be set as a template not using a hyphen delimiter.
2021-02-04 16:41:22 +01:00
Daan De Meyer
bcea93326b boot: Replace efivar_set() persistent argument with flags argument
To add secure-boot enrolling support, we need to be able to specify
the EFI_VARIABLE_APPEND_WRITE flag so let's make the efivar_set()
methods more generic so we can set that flag.
2021-02-04 16:38:22 +01:00
Zbigniew Jędrzejewski-Szmek
a7a1887869 man: reword the description of "main conf file"
While not really "wrong", the text we had could use a little editing.

Fixes #18458.
2021-02-04 14:32:28 +01:00
Zbigniew Jędrzejewski-Szmek
3d0112878f
Merge pull request #18444 from anitazha/proprename
oom: parse properties with 1/10000 precision instead of 1/100
2021-02-04 12:53:10 +01:00
Zbigniew Jędrzejewski-Szmek
5623600c6e
Merge pull request #18355 from DaanDeMeyer/resolved-discover
resolvectl: Add show-multicast verb to show discovered LLMNR/mDNS hosts
2021-02-04 10:37:21 +01:00
Yu Watanabe
436cde839f
Merge pull request #18462 from poettering/copy-time
timestamp fixes in copy.c
2021-02-04 14:04:37 +09:00
Lennart Poettering
d8f9686c0f import: use +i (immutable) chattr flag for marking OS images read-only
This is what nspawn and machine-image.[ch] actually look for, hence us
it here too.
2021-02-04 14:03:03 +09:00
Lennart Poettering
5d80583d5d import: fix etag detection support
Let's make sure we still look at the etags reported by http 304 (i.e.
the cache management code). Otherwise we won't properly realize we
already downloaded this before.

This fixes a bug introduced in 6792cbbcf84b730f465decbeaf247c6b1ccf1c18
2021-02-04 14:00:11 +09:00
Yu Watanabe
245f4b384d
Merge pull request #18459 from poettering/discover-image
shared: rename machine-image.[ch] → discover-image.[ch]
2021-02-04 13:57:37 +09:00
Lennart Poettering
2ef2376d83 path-util: tighten path_is_valid() checks
This tightens the path_is_valid() checking: it now tests whether each
component in the path is bound by FILENAME_MAX in its size.
2021-02-03 23:36:55 +01:00
Lennart Poettering
150dcaf248 copy: simplify futimens() invocation 2021-02-03 23:25:02 +01:00
Lennart Poettering
fb934d53f9 copy: also attempt to copy atime/mtime when copying symlinks, device nodes, fifos 2021-02-03 23:24:55 +01:00
Lennart Poettering
99d97afcec discover-image: don't mix two types of stack allocation in one line 2021-02-03 23:13:11 +01:00
Lennart Poettering
57f1b61b76 shared: rename machine-image.[ch] → discover-image.[ch]
The old name originates when this was used to discover "machine" images,
as managed by machined/machinectl. But nowadays this is also used by
portable services and system extensions, hence let's use a more generic
name for this API. Taking inspiration from "dissect-image.[ch]", let's call
this "discover-image.[ch]".

This is pure renaming, no other changes.
2021-02-03 23:12:57 +01:00
Yu Watanabe
0fb613000d test-network: disable NDISC on veth-peer
This should speed the tests up.
2021-02-03 22:09:07 +00:00
Zbigniew Jędrzejewski-Szmek
9afd5e7b97 Deprecate builds with split-usr, prepare for removal
There is no technical reason to support systems with split-usr, except for
backwards compatibility. Even though systemd itself makes an effort to support
this, many other tools aren't as careful. Despite those efforts, we
(collectively) get it wrong often, because doing it "wrong" on systems with
merged-usr has no consequences. Since almost all developers are on such
systems, any issues are only discovered late. Supporting this split-usr mode
makes both code and documentation more complicated. The split is purely
artificial and has no justification except to allow old installation to not
update. Mechanisms to update existing systems are available though: Fedora
did that in https://fedoraproject.org/wiki/Features/UsrMove, Debian has
the usrmerge package.

The next version of Debian will only support systems with split-usr=false,
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=978636#178:

  The Technical Committee resolves that Debian 'bookworm' should
  support only the merged-usr root filesystem layout, dropping support
  for the non-merged-usr layout.

Let's start warning if split-usr mode is used, in preparation to removing the
split in one of the future releases.
2021-02-03 22:08:35 +00:00
Weblate (bot)
33e71ade3b
Translated using Weblate (Swedish) (#18457)
Currently translated at 94.1% (178 of 189 strings)

Co-authored-by: Göran Uddeborg <goeran@uddeborg.se>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/sv/
Translation: systemd/main
2021-02-04 06:08:24 +09:00
Kevin P. Fleming
e65c4c4a96 network: correct name of parameter in function prototype
The output parameter of `sd_rtnl_message_neigh_get_ifindex` is called `index`,
not `family`.
2021-02-03 14:19:48 +00:00
Yu Watanabe
27897cecff
Merge pull request #18319 from yuwata/udev-move-tx-rx-queues
network,udev: move TransmitQueues=/ReceiveQueues= from .network to .link
2021-02-03 18:18:57 +09:00
Lennart Poettering
3ecafb1f5b logind: simplify flags handling a bit
Let's split out the two codepaths a bit, and emphasize which ones it the
new-style and which the old-style codepath, and let's clearly convert
the params of the old-stye into the new style for further processing, so
that the old style path is brief and isolated.

No change in behaviour.

Follow-up for: 8885fed4e3a52cf1bf105e42043203c485ed9d92
2021-02-03 17:22:59 +09:00
Yu Watanabe
89d2da287b
Merge pull request #18423 from DaanDeMeyer/sd-boot-no-include
More sd-boot cleanups
2021-02-03 15:04:26 +09:00
Yu Watanabe
face9fcc16 network,udev: move TransmitQueues=/ReceiveQueues= from .network to .link
As the settings are mostly hardware setup, and merely see from network
layer.

See also discussions in
https://github.com/systemd/systemd/pull/18170#issuecomment-758807497
https://github.com/orgs/systemd/teams/systemd/discussions/1
2021-02-03 14:44:51 +09:00
Yu Watanabe
1f8dc96c06 udev: rename TxQueueLength= -> TransmitQueueLength=
As we usually (unfortunately not always though) do not use abbreviations.

Tx may be standard abbreviation, but we already have e.g.
TransmitChecksumOffload=. So, let's use Transmit instead of Tx.

Follow-up for ef4a91a7e8d8337a9d65177b09eb7580b25b8f5d.
2021-02-03 14:43:49 +09:00
Yu Watanabe
d96d8a81ef test: add tests for RouteTable= setting 2021-02-03 14:39:25 +09:00
Yu Watanabe
552b90a2f2 network: use defined route table name in debug logs
And rename route_table_from_string_full() to
manager_get_route_table_from_string().
2021-02-03 14:36:50 +09:00
Yu Watanabe
310eff7274 network: make RouteTable= setting can take multiple name:number pairs in a line
Follow-up for c038ce4606f93d9e58147f87703125270fb744e2.
2021-02-03 14:32:26 +09:00
Anita Zhang
0a9f93443b oom: rework *MemoryPressureLimit= properties to have 1/10000 precision
Requested in
https://github.com/systemd/systemd/pull/15206#discussion_r505506657,
preserve the full granularity for memory pressure limits (permyriad)
instead of capping out at percent.
2021-02-02 17:52:48 -08:00
Frantisek Sumsal
e3f87b07bc ci: build with -Werror on Fedora
Prompted by: https://github.com/systemd/systemd/pull/18400#issuecomment-771602705
2021-02-02 23:17:15 +00:00
Lennart Poettering
3cdcbdd32f path-util: tighten path_extract_filename()
Let's tighten the logic behind path_extract_filename() a bit: first of
all, refuse all cases of invalid paths with -EINVAL. More importantly
though return a recognizable error when a valid path is specified that
does not contain any filename. Specifically, "/" will now result in
-EADDRNOTAVAIL.

This changes API, but none of the existing callers care about the return
value, hence the change should be fine.
2021-02-02 23:16:38 +00:00
Luca Boccassi
23cfef7bb1
Merge pull request #18435 from keszybz/oomd-readiness-and-other-tweaks
Mark oomd as supported and other tweaks
2021-02-02 23:15:19 +00:00
Daan De Meyer
cb347d263d boot: Add startswith() and endswith() functions with no_case variants
Adapted from string-util
2021-02-02 22:53:31 +00:00
Daan De Meyer
fffd5e8ee3 boot: Drop unnecessary braces 2021-02-02 21:15:24 +00:00
Daan De Meyer
d47b7c5720 boot: Fix void pointer arithmetic warning 2021-02-02 21:15:24 +00:00
Daan De Meyer
c8af7dab21 boot: Replace raw efivar gets with typed variants 2021-02-02 21:15:21 +00:00
Daan De Meyer
987d0a1250 boot: Add efivar_get/set_uint64_le() functions
These are implemented as bit-shifting functions that allow reading
and writing UEFI variables stored as little endian 64-bit unsigned
values.
2021-02-02 21:03:58 +00:00