summaryrefslogtreecommitdiffstats
path: root/src (unfollow)
Commit message (Collapse)AuthorFilesLines
2021-12-16network: route: link_drop_foreign_routes() must be called only for managed ↵Yu Watanabe1-2/+3
interfaces
2021-12-16networkd: check the existence of the routeYu Watanabe1-0/+4
2021-12-16network: address: minor optimization for link_drop_foreign_addresses()Yu Watanabe1-4/+7
link_address_is_dynamic() is costful in general. Call it only when KeepConfiguration= is set. Note, it is not necessary to check link->network in the loop, as we have the assertion for that in the beginning of the function.
2021-12-16network: drop IPv6LL addresses manually configured in .network fileYu Watanabe1-2/+5
2021-12-16NEWS: update againZbigniew Jędrzejewski-Szmek1-39/+65
2021-12-16kernel-install: Introduce KERNEL_INSTALL_MACHINE_ID in /etc/machine-infoDaan De Meyer4-1/+40
If KERNEL_INSTALL_MACHINE_ID is defined in /etc/machine-info, prefer it over the machine ID from /etc/machine-id. If a machine ID is defined in neither /etc/machine-info nor in /etc/machine-id, generate a new UUID and try to write it to /etc/machine-info as KERNEL_INSTALL_MACHINE_ID and use it as the machine ID if writing it to /etc/machine-info succeeds. In practice, this means we have a more robust fallback if there's no machine ID in /etc/machine-id than just using "Default" and allows image builders to force kernel-install to use KERNEL_INSTALL_MACHINE_ID by simply writing it to /etc/machine-info themselves.
2021-12-16test: bump the timeout when collecting test coverageFrantisek Sumsal1-2/+6
2021-12-16test: settle before checking logsFrantisek Sumsal1-0/+2
Otherwise we might miss the "Device path too long" message: ``` [ 21.083274] testsuite-64.sh[374]: swapoff /dev/vda1 [ 21.089841] testsuite-64.sh[376]: ++ mktemp [ 21.095115] testsuite-64.sh[271]: + logfile=/tmp/tmp.a1MULA35wL [ 21.095115] testsuite-64.sh[271]: + journalctl -b -q --no-pager -o short-monotonic -p info --grep 'Device path.*vda.?'\'' too long to fit into unit name' ... [ 21.277360] systemd[1]: testsuite-64.service: Main process exited, code=exited, status=1/FAILURE [ 21.277508] systemd[1]: testsuite-64.service: Failed with result 'exit-code'. ... [ 21.323500] systemd[1]: Device path '/sys/devices/pci0000:00/0000:00:03.0/0000:01:00.0/0000:02:00.0/0000:03:00.0/0000:04:00.0/0000:05:00.0/0000:06:00.0/0000:07:00.0/0000:08:00.0/0000:09:00.0/0000:0a:00.0/0000:0b:00.0/0000:0c:00.0/0000:0d:00.0/0000:0e:00.0/0000:0f:00.0/0000:10:00.0/0000:11:00.0/0000:12:00.0/0000:13:00.0/0000:14:00.0/0000:15:00.0/0000:16:00.0/0000:17:00.0/0000:18:00.0/0000:19:00.0/0000:1a:00.0/virtio0/block/vda/vda1' too long to fit into unit name, ignoring device. ```
2021-12-16man: split out a paragraph and shorten the text about sd-network-generatorZbigniew Jędrzejewski-Szmek1-7/+8
The ordering of the service wrt. to udevd is enforced by unit configuration, so no need to tell the user about this. From users' POV, the only thing that counts is that the unit is enabled and then the right thing happens.
2021-12-16units: enable systemd-network-generator by defaultZbigniew Jędrzejewski-Szmek2-1/+5
It is used by udevd and networkd. Since udevd is enabled statically, let's also change the preset to "on". networkd is opt-in, so let's pull in the generator when enabling networkd too.
2021-12-15network: route: update commentYu Watanabe1-3/+2
2021-12-15journal: Stop reading in increments of block size during hole punchingDaan De Meyer1-3/+1
Let's not try to be overly clever here. This code path is not overly performance sensitive and we should avoid trying to outsmart the kernel without proper benchmarking.
2021-12-15journal: Use 16kb buffer during hole punchingDaan De Meyer1-1/+2
Let's use the same buffer size as used in as copy.h.
2021-12-15journal: Correctly advance offset when iterating hash table entriesDaan De Meyer1-7/+6
pread() is not guaranteed to completely fill up the given buffer with data which we assumed until now. Instead, only increment the offset by the number of bytes that were actually read.
2021-12-15journal: Add a minimum hole size for hole punchingDaan De Meyer1-0/+5
Let's not bother punching extremely small holes to avoid unnecessary file fragmentation.
2021-12-15NEWS: update networkd related entriesYu Watanabe1-3/+4
2021-12-15test: add testcases for net.ifname-policy= kernel command line argumentYu Watanabe1-2/+18
2021-12-15network-generator: support to set NamePolicy= through kernel command line ↵Yu Watanabe5-20/+164
argument Closes #16296.
2021-12-15udev: move NamePolicy to netif-naming-scheme.[ch]Yu Watanabe4-39/+42
2021-12-15network-generator: support MAC address longer or shorter than ETH_ALENYu Watanabe2-8/+14
2021-12-15meson: build network-generator unconditionallyYu Watanabe4-20/+17
The service also generates .link files for udevd.
2021-12-15unit: run network-generator before starting udevdYu Watanabe1-1/+1
Otherwise, .link files generated by the service may not be loaded by udevd.
2021-12-15kernel-install: Remove "Default" from list of suffixes checkedDaan De Meyer1-1/+1
This was an undocumented change in behavior introduced by 9e82a74cb0f08a288f9db228a0b5bec8a7188cdb. Previously, we only checked for "Default" if we didn't find a machine ID. Let's make sure we keep the previous behavior intact.
2021-12-15resolved: filter out our own stub resolvers when parsing serversZbigniew Jędrzejewski-Szmek5-23/+34
We get "upstream" dns server config from ~three places: /etc/resolv.conf, config files, and runtime config via dbus. With this commit, we'll filter out our own stub listeners if they are configured in either of the first two sources. For /etc/resolv.conf this is done quitely, and for our own config files, a LOG_INFO message is emitted, since this is a small inconsistency in the config. Setting loops like this over dbus is still allowed. The reason is that in the past we didn't treat this as an error, and if we were to start responding with an error, we could break a scenario that worked previously. E.g. NM sends us a list of servers, and one happens to be the our own. We would just not use that stub server before, but it'd still be shown in the dbus properties and such. We would have to return error for the whole message, also rejecting the other valid servers. I think it's easier to just keep that part unchanged. Test case: $ ls -l /etc/resolv.conf -rw-r--r-- 1 root root 57 Dec 15 10:26 /etc/resolv.conf $ cat /etc/resolv.conf nameserver 192.168.150.1 options edns0 trust-ad search . $ cat /etc/systemd/resolved.conf.d/stub.conf [Resolve] DNSStubListenerExtra=192.168.150.1 $ resolvectl ... Global resolv.conf mode: foreign DNS Servers: 192.168.150.1 Fallback DNS Servers: ... (with the patch): Global resolv.conf mode: foreign Fallback DNS Servers: ...
2021-12-15resolved: return immediately if we already know what to returnZbigniew Jędrzejewski-Szmek1-10/+2
2021-12-15hwdb: Add accel orientation quirk for the Chuwi Hi10 Go tabletJayce Fayne1-0/+4
2021-12-14fstab-generator: do not remount /sys when running in a containerYu Watanabe1-3/+10
Closes #21744.
2021-12-14journactl: show info about journal range only at debug level (#21775)Zbigniew Jędrzejewski-Szmek1-1/+1
The message that the "journal begins … ends …" has been always confusing to users. (Before b91ae210e62 it was "logs begin … end …" which was arguably even more confusing, but really the change in b91ae210e62 didn't substantially change this.) When the range shown is limited (by -e, -f, --since, or other options), it doesn't really matter to the user what the oldest entries are, since they are purposefully limiting the range. In fact, if we are showing the last few entries with -e or -f, knowing that many months the oldest entries have is completely useless. And when such options are *not* used, the first entry generally corresponds to the beginning of the range shown, and the last entry corresponds to the end of that range. So again, it's not particularly useful, except when debugging journalctl or such. Let's just treat it as a debug message. Fixes #21491.
2021-12-14hostnamectl: add a chassis symbol in status outputZbigniew Jędrzejewski-Szmek1-1/+27
The idea is to be able to distinguish whether we're in a VM/container or something more substantial at a glance. Chassis: laptop 💻 Chassis: tablet 具 Chassis: vm 🖴 Chassis: server 🖳 Chassis: handset 🕻 Chassis: watch ⌚ Chassis: desktop 🖥 Chassis: container ☐
2021-12-14udevadm: also show write-only attributesYu Watanabe1-10/+15
2021-12-14sd-device: make FOREACH_DEVICE_SYSATTR() also list write-only attributesYu Watanabe1-1/+1
Closes #10102.
2021-12-14home: fix heap-use-after-freeYu Watanabe1-0/+6
`bus_home_emit_remove()` may be called from manager_free() -> home_free(). In that case, manager->bus is already unref()ed. Fixes #21767.
2021-12-14home: clear Manager::bus, ::event, ::homes_by_xxx and so onYu Watanabe1-7/+7
`home_free()` may try to call some dbus or event related functions. To prevent that, set those variables NULL.
2021-12-14polkit: make bus_verify_polkit_async_registry_free() return Hashmap* with NULLYu Watanabe2-3/+6
2021-12-14wait-online: also use address state even when operational state is below ↵Yu Watanabe2-8/+14
degraded Closes #21706.
2021-12-14shell-completion: Add completion for systemd-analyze critical-chainNishal Kulkarni2-0/+17
systemd-analyze critical-chain accepts an optional unit argument, however currently there's no shell-completion for it This change provides unit name completion for both bash and zsh. Closes: #20927
2021-12-14Fix loading of graphsacsfer1-2/+2
2021-12-14boot, meson: allow statically linked buildRobert Scheck2-3/+13
Build option "link-boot-shared" to build a statically linked bootctl and systemd-bless-boot by using -Dlink-boot-shared=false on systems with full systemd stack except bootctl and systemd-bless-boot, such as CentOS/RHEL 9.
2021-12-14man: do not install sd-boot man pages when -Dgnu-efi=false is setDavide Cavalca8-14/+14
2021-12-13man: how to unset CPUQuota=Sho Iizuka1-1/+2
This description will help users who are trying to reset the already configured CPUQuota= by trying incorrect ways such as CPUQuota=0 or CPUQUota=infinity.
2021-12-13resolved: filter stub listeners in manager_get_dns_server()Tom Yan1-1/+10
Commit 49ef064c8dcd8ed12d98e6c705e676babade0897 attempts to handle "stub loop" by switching to the next server *after the query has been made*. The approach may be good enough for link scopes. However, for the manager / global scope, it is not. First of all, there are more than one types (SYSTEM and FALLBACK) of servers it can use. Also, whether those of type FALLBACK should be used depends. Besides, dns_scope_good_domain() determines whether things should be routed to a scope by checking whether the scope has a server. The decision made would be incorrect if stubs were not filtered beforehand. Therefore, to avoid failing query unnecessarily, and to make sure that extra stub listeners will not trigger unexpected and/or inconsistent behavior, make manager_get_dns_server() do what it should have done.
2021-12-13man: make systemd-creds man page a bit easier to readZbigniew Jędrzejewski-Szmek1-10/+10
2021-12-13shared/creds: print debugging information when something goes wrongZbigniew Jędrzejewski-Szmek1-40/+60
2021-12-13build(deps): bump actions/upload-artifact from 2.2.4 to 2.3.0dependabot[bot]1-1/+1
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2.2.4 to 2.3.0. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/27121b0bdffd731efa15d66772be8dc71245d074...da838ae9595ac94171fa2d4de5a2f117b3e7ac32) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
2021-12-13build(deps): bump github/codeql-action from 1.0.25 to 1.0.26dependabot[bot]1-3/+3
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 1.0.25 to 1.0.26. - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/github/codeql-action/compare/546b30f35ae5a3db0e0be1843008c2224f71c3b0...5f532563584d71fdef14ee64d17bafb34f751ce5) --- updated-dependencies: - dependency-name: github/codeql-action dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
2021-12-13test: bump timeout for TEST-50-DISSECT and TEST-67-INTEGRITYLuca Boccassi2-2/+2
TEST-67-INTEGRITY times out quite often, and when it passes it does so a few seconds short of the timeout. It's a slow qemu test, so bump the timeout. TEST-50-DISSECT has been reported to fail in the same way on Debian's infrastructure, again narrowly failing or passing just short of the timeout.
2021-12-13man: reorder itemZbigniew Jędrzejewski-Szmek1-2/+2
We said that recovery keys are "similar to regular passphrases" before intorducing "regular passphrases".
2021-12-12man/sd-run: /bin/bash -> bash in -t exampleнаб1-3/+3
sd-run already does PATH lookup via find_executable_full()
2021-12-12man/sd-notify: /bin/bash -> /bin/sh, read -> read -r in exampleнаб1-2/+2
2021-12-12Change all fixed-path bash shebangs to /u/b/env bash outside test/наб11-12/+13