summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* udev-rules: replace ingrowing word extractor with extract_first_word()Yu Watanabe2023-04-081-13/+14
| | | | No functional change, just refactoring.
* udev-rules: rename variable "filename" -> "path"Yu Watanabe2023-04-081-7/+7
|
* udev-rules: add/update commentsYu Watanabe2023-04-081-4/+5
|
* udev-rules: add missing parenYu Watanabe2023-04-081-1/+1
|
* localed: fix invalid free after shifting pointers using strstripOlivier Gayot2023-04-081-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | After manually editing /etc/locale.gen, calling localectl set-locale sometimes fails. When it fails, the systemd journal shows: systemd-localed: free() / invalid pointer. It turned out that it only fails if some of the uncommented lines in /etc/locale.gen have leading spaces, as in: * C.UTF-8 <= OK * en_US.UTF-8 <= OK * fr_FR.UTF-8 <= NOK After parsing a line from /etc/locale.gen, we use strstrip() to obtain the "trimmed" line (without leading or trailing spaces). However, we store the result of strstrip() in the original pointer containing the untrimmed line. This pointer is later passed to free (this is done automatically using _cleanup_free_). This is a problem because if any leading space is present, the pointer will essentially be shifted from its original value. This will result in an invalid free upon cleanup. The same issue is present in the locale_gen_locale_supported function. Fixed by storing the result of strstrip() in a different pointer.
* man/systemd-mount: Clearify documentation about --bind-deviceUwe Kleine-König2023-04-071-1/+1
| | | | | | | | The documentation suggests that the mount point (i.e. the directory where the device is mounted) is removed when the device vanishes. However only stopping of the automount unit is implemented. So adapt the documentation to reality.
* mkosi: Update to latestDaan De Meyer2023-04-071-1/+1
| | | | | This contains the recently merged fixes to config parsing ordering and overrides.
* hwdb: Add support for "Passion Model P612F"Dmitrii Fomchenkov2023-04-071-0/+8
| | | | Add hwdb sensor entry for device Passion with accelerometer "MXC6655".
* Merge pull request #26887 from yuwata/proc-cmdline-filter-argumentsZbigniew Jędrzejewski-Szmek2023-04-0718-194/+389
|\ | | | | proc-cmdline: filter PID1 arguments on container
| * proc-cmdline: filter PID1 arguments when we are running in a containerYu Watanabe2023-03-296-74/+214
| | | | | | | | | | | | | | | | Otherwise, PID1 arguments e.g. "--deserialize 16" may be parsed unexpectedly by generators. Fixes the issue reported at https://github.com/systemd/systemd/issues/24452#issuecomment-1475004433.
| * tree-wide: reset optind to 0 when GNU extensions in optstring are usedYu Watanabe2023-03-2912-0/+40
| | | | | | | | | | | | | | | | | | | | Otherwise, if getopt() and friends are used before parse_argv(), then the GNU extensions may be ignored. This should not change any behavior at least now, as we usually use getopt_long() only once per invocation. But in the next commit, getopt_long() will be used for other arrays, hence this change will become necessary.
| * condition: use proc_cmdline_strv()Yu Watanabe2023-03-291-12/+5
| |
| * proc-cmdline: introduce proc_cmdline_strv()Yu Watanabe2023-03-293-20/+40
| | | | | | | | | | | | | | | | | | | | | | When we are running in a container, we parse the command line of PID1 in proc_cmdline_parse() or friends. Previously, first we merge the command line nulstr as a single string, and then split by using extract_first_word(). That's not only redundant, but also unsafe when the command line argument contain a space. This drops the redundant steps, hence we can safely parse arguments with space.
| * proc-cmdline: split commandline earlier in proc_cmdline_parse() and friendYu Watanabe2023-03-291-114/+116
| | | | | | | | No functional change, just preparation for later commits.
* | Merge pull request #27161 from pothos/sysext-refreshZbigniew Jędrzejewski-Szmek2023-04-073-4/+6
|\ \ | | | | | | systemd-sysext/confext.service: Refresh on start/reload
| * | systemd-sysext/confext.service: Refresh on start/reloadKai Lueke2023-04-062-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When adding a sysext image to the system and manuall merging it, a later "systemctl (re)start systemd-sysext" won't work because "merge" refuses to work when something is merged already. Another problem with "merge" at start plus "unmerge" at stop is that a service restart can't make use of the new MOVE_MOUNT_BENEATH in the future even which would only be available in "refresh". It also prepares us for setting up the merged overlay for the sysroot from the initrd already, which also would lead to the mentioned start problem of the service (One optimization could be to skip the loading but only if we are sure that all images were loaded and weren't modified since - this assumption is hard because early services could want to inject a sysext, too). Use "refresh" on service start to fix the problem that the service can't start as soon as a manual merge was done. Also add a reload action that allows to issue "systemctl reload systemd-sysext" and it will make use of MOVE_MOUNT_BENEATH once we implement this in systemd-sysext refresh (and it's available from the kernel).
| * | man/systemd-dissect.xml: Remove old sysext path, add confext pathKai Lueke2023-04-061-2/+2
| | | | | | | | | | | | | | | | | | | | | The /usr/lib/extensions/ location for systemd-sysext images is not supported anymore. In https://github.com/systemd/systemd/pull/26013 systemd-confext images got introduced and we can list its path under /usr instead.
* | | bootctl: Gracefully handle missing bootloader directoryDaan De Meyer2023-04-071-0/+4
| | | | | | | | | | | | | | | When --graceful is specified, let's gracefully deal with a missing bootloader directory.
* | | bootctl: show report state and type in json outputLudwig Nussel2023-04-072-0/+12
| | |
* | | resolve: change DNS_PACKET_UNICAST_SIZE_LARGE_MAX to 1232 (#27171)Cristian Rodríguez2023-04-071-2/+2
| | | | | | | | | | | | | | | | | | | | | The old common default was 4096, until 2020 on which all DNS servers (verified on BIND9, NSD, Unbound, dnsmasq) switched to 1232 as an agreed max size [1]. [1] https://www.dnsflagday.net/2020/#message-size-considerations
* | | Merge pull request #27126 from yuwata/journal-compressZbigniew Jędrzejewski-Szmek2023-04-077-32/+152
|\ \ \ | | | | | | | | sd-journal: allow to specify compression algorithm through env
| * | | test: add test case that journal file is created with the requested ↵Yu Watanabe2023-04-071-0/+32
| | | | | | | | | | | | | | | | compression algorithm
| * | | sd-journal: allow to specify compression algorithm through envYu Watanabe2023-04-042-1/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes RHBZ#2183546 (https://bugzilla.redhat.com/show_bug.cgi?id=2183546). Previously, journal file is always compressed with the default algorithm set at compile time. So, if a newer algorithm is used, journal files cannot be read by older version of journalctl that does not support the algorithm. Co-authored-by: Colin Walters <walters@verbum.org>
| * | | sd-journal: always use the compression algorithm specified in the headerYu Watanabe2023-04-042-19/+33
| | | | | | | | | | | | | | | | | | | | Previously, data object may be compressed with an algorithm that is not mentioned in the header.
| * | | compress: introduce compression_supported() helper functionYu Watanabe2023-04-042-0/+13
| | | |
| * | | sd-journal: cache results of parsing environment variablesYu Watanabe2023-04-041-12/+23
| | | |
| * | | journald: fix log messageYu Watanabe2023-04-041-1/+1
| | | |
* | | | man: netdev: Clarify wireguard IPv6 endpoint formatSorah Fukumori2023-04-071-1/+3
| | | |
* | | | mkosi: Update to latestDaan De Meyer2023-04-0711-38/+53
| | | | | | | | | | | | | | | | | | | | | | | | This also migrates the configuration to the new format that was just merged in mkosi. Specifically, we make use of the new [Match] sections to only include specific config snippets per distro.
* | | | Merge pull request #27158 from mrc0mmand/more-testsYu Watanabe2023-04-0710-4/+733
|\ \ \ \ | | | | | | | | | | test: introduce TEST-81-GENERATORS
| * | | | test: introduce TEST-81-GENERATORSFrantisek Sumsal2023-04-068-0/+641
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add some explicit tests for various generators we ship, e.g.: - systemd-debug-generator - systemd-environment-d-generator - systemd-fstab-generator
| * | | | test: add a couple of tests for systemd-modules-loadFrantisek Sumsal2023-04-061-0/+88
| | | | |
| * | | | fstab-generator: don't propagate ignored errnoFrantisek Sumsal2023-04-061-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With certain fstabs we may propagate ENXIO from the $SYSTEMD_SYSFS_CHECK check all the way up, making fstab-generator exit with a non-zero EC and without any helpful message, which is really confusing.
* | | | | test: check if we skip the full setup on daemon-reexecFrantisek Sumsal2023-04-073-3/+48
| |_|/ / |/| | | | | | | | | | | | | | | | | | | A simple test case for issue #27106. Resolves: #27139
* | | | Merge pull request #26013 from goenkam/maanya/syscfg-featureLuca Boccassi2023-04-0621-161/+481
|\ \ \ \ | | | | | | | | | | confext: extension of sysext
| * | | | confext: shell completion for systemd-confextmaanyagoenka2023-04-051-0/+85
| | | | |
| * | | | confext: documentation and man page updates for confextmaanyagoenka2023-04-054-18/+80
| | | | |
| * | | | test-os-util: add tests for sysext and confext release filesmaanyagoenka2023-04-051-1/+47
| | | | |
| * | | | confext: add tests for systemd-confextmaanyagoenka2023-04-051-0/+11
| | | | |
| * | | | confext: add the systemd-confext.service filemaanyagoenka2023-04-052-0/+34
| | | | |
| * | | | confext: add multi call functionality to sysextmaanyagoenka2023-04-052-28/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The confext concept is an extension of the existing sysext concept and allows to extend the host's filesystem or a unit's filesystem with signed images that add new files to the /etc/ directory using OverlayFS.
| * | | | extension-release: establish compatibility between host file and ↵maanyagoenka2023-04-056-48/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | extension-release file The release file that accompanies the confext images needs to be host compatible to be able to be merged into the host /etc/ directory. This commit checks for version compatibility between the image file and the host file.
| * | | | os-util: add a new confext image type and the ability to parse their release ↵maanyagoenka2023-04-059-70/+98
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | files Adds a new image type called IMAGE_CONFEXT which is similar to IMAGE_SYSEXT but works for the /etc/ directory instead of /usr/ and /opt/. This commit also adds the ability to parse the release file that is present with the confext image in /etc/confext-release.d/ directory.
* | | | | repart: Add more loggingDaan De Meyer2023-04-062-2/+30
|/ / / /
* | | | Merge pull request #27154 from DaanDeMeyer/kconfigLuca Boccassi2023-04-052-12/+16
|\ \ \ \ | | | | | | | | | | mkosi kernel build updates
| * | | | mkosi: Update bundled kconfigDaan De Meyer2023-04-051-7/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Remove useless serial console configs - Add CONFIG_SERIAL_8250_PCI so that qemu's virtconsole works properly - Add CONFIG_DMI and CONFIG_DMI_SYSFS so that SMBIOS credentials work - Add CONFIG_IKCONFIG and CONFIG_IKCONFIG_PROC so we can read the current kernel config from /proc/config.gz - Add CONFIG_IOSCHED_BFQ to get rid of a udev error on boot on Fedora - Add CONFIG_HW_RANDOM_VIRTIO to get hw rng in qemu - Add CONFIG_SECURITY_YAMA to get rid of warning from sysctl on boot - Add CONFIG_VSOCKETS and CONFIG_VIRTIO_VSOCKETS to enable vsock support
| * | | | mkosi: Make sure we always boot our built from source kernelDaan De Meyer2023-04-051-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | If we build a kernel from source, let's make sure it's always booted by giving it a very high version number.
* | | | | test: use kbd-mode-map we ship in TEST-73-LOCALEFranck Bui2023-04-051-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | The rational is the same as the one described in commit be0cc2ce6c947aafadb3f42dba405269f670b31c.
* | | | | test: add tests for dir_fd_is_root_or_cwd()Yu Watanabe2023-04-051-0/+7
| | | | | | | | | | | | | | | | | | | | Follow-up for e212f422796da9e626030289faf083407c8955df.
* | | | | resolve: refuse mdns scope for ipv4 broadcast addressesRonan Pigott2023-04-054-4/+22
| | | | | | | | | | | | | | | | | | | | This query can never be answered, so let's no wait for it to timeout.