summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* sd-bus: bind outgoing AF_UNIX sockets to abstract addresses conveying client ↵Lennart Poettering2023-05-161-0/+49
| | | | | | | | | | | | | | | | comm + bus description string Let's pass some additional meta information along bus connections without actually altering the communication protocol. Pass the client comm and client description string of the bus via including it in the abstract namespace client socket address we connect to. This is purely informational (and entirely user controlled), but has the benefit that servers can make use of the information if they want, but really don't have to. It works entirely transparently. This takes inspiration from how we convey similar information via credential socket connections.
* test-bus-server: minor modernizationsLennart Poettering2023-05-161-6/+1
|
* test-bus-chat: modernize a few thingsLennart Poettering2023-05-161-102/+54
|
* Merge pull request #27652 from keszybz/readme-moreZbigniew Jędrzejewski-Szmek2023-05-1613-27/+173
|\ | | | | Add man page for libsystemd, extend readme and stability promise
| * docs: list all public headers in stability promiseZbigniew Jędrzejewski-Szmek2023-05-161-2/+9
| | | | | | | | | | | | | | We provide the same stability for all the headers that are public. Also, mark id128 as portable to other systems. There is really nothing in the code that would make it hard. It would probably work out-of-the-box.
| * README: describe how our libraries are linkedZbigniew Jędrzejewski-Szmek2023-05-161-2/+38
| | | | | | | | | | | | | | In https://github.com/systemd/systemd/pull/27637#issuecomment-1547517316 we discussed disclaiming warranty when distros do version mixing. But to make this disclaimer meaningful, we need to document what options are available.
| * man: add libsystemd(3)Zbigniew Jędrzejewski-Szmek2023-05-1511-23/+125
| | | | | | | | | | | | | | | | Before libsystemd-daemon, libsystemd-journal, libsystemd-id128, etc., were merged into libsystemd, it was enough to have individual man pages for them. But they have been delivered as one thing for many years, so it's better to have a landing page for libsystemd. It mostly directs to individual pages anyway.
| * meson: add sd_pid_notify_barrier linkZbigniew Jędrzejewski-Szmek2023-05-151-0/+1
| | | | | | | | Fixup for 0de343187127f6a5a93602608812e60fc4092c9a.
* | meson: fix description for link-udev-shared optionYu Watanabe2023-05-161-1/+1
| |
* | man: use correct name for --bank optionnikstur2023-05-151-1/+1
| |
* | hwdb: fix keyboard entry for IdeapadFlex5 (#27643)saikat05112023-05-161-1/+1
|/ | | | | Fixes a bug caused by 19db450f3a243fcaf0949beebafc3025f8e3a98e (#27211). Also this makes the model more specific.
* watchdog: always disarm watchdog properly before closing itLennart Poettering2023-05-151-5/+10
| | | | | | | If we change the watchdog device we should disarm the old one first. Similar, if we open the watchdog, but then fail setting it up, disarm it before closing it again.
* Revert "units: Add missing dependencies on initrd-switch-root.target"Daan De Meyer2023-05-158-16/+16
| | | | This reverts commit f0ad3e6b9652fe785245934ff8604cc897d3b8f4.
* mkosi: Always pull in network-online.targetDaan De Meyer2023-05-151-0/+3
| | | | | Let's always pull this in so that we always activate systemd-networkd-wait-online for extra coverage.
* mkosi: Drop squashfs dropinDaan De Meyer2023-05-151-2/+0
| | | | | | This accidentally got pulled into a commit even though it was only for local testing, let's drop it again so we correctly use erofs when building local images.
* portable, meson: allow statically linked buildRobert Scheck2023-05-152-2/+12
| | | | | | | | | | Build option "link-portabled-shared" to build a statically linked systemd-portabled by using -Dlink-portabled-shared=false on systems with full systemd stack except systemd-portabled, such as CentOS/RHEL 9.
* mkosi: Install tmux in the final imageDaan De Meyer2023-05-151-0/+1
| | | | | | | We currently have to resort to SSH to get more than one interactive terminal in a mkosi qemu VM. Let's increase our options by installing tmux in the final image, which can multiplex the serial console into many unique terminal sessions.
* Merge pull request #27644 from mrc0mmand/fuzz-nspawnLuca Boccassi2023-05-153-5/+43
|\ | | | | test: update nspawn's basic config file used for fuzzing
| * test: make $BUILD_DIR writable when rootfs is mounted read-onlyFrantisek Sumsal2023-05-151-2/+6
| | | | | | | | | | Adjust two systemd-nspawn invocations where rootfs is mounted read-only, to avoid gcov complaining.
| * test: pass $BUILD_DIR as $COVERAGE_BUILD_DIR to the system managerFrantisek Sumsal2023-05-151-0/+5
| | | | | | | | To make additional coverage-related tweaks slightly easier.
| * test: update nspawn's basic config file used for fuzzingFrantisek Sumsal2023-05-151-3/+32
|/
* machine-id-setup: Do not overwrite if /etc/machine-id contains uninitializedDaan De Meyer2023-05-151-4/+14
| | | | | | | | When we're building OS images, we never want /etc/machine-id to contain anything other than "uninitialized" until we actually boot the image. So let's allow image builders to write "uninitialized" to /etc/machine-id and if systemd-machine-id-setup is called after, make sure we don't overwrite it.
* Merge pull request #27640 from mrc0mmand/more-testsLuca Boccassi2023-05-1412-83/+308
|\ | | | | test: more TEST-13-NSPAWN-SMOKE follow-ups
| * test: rename TEST-13-NSPAWN-SMOKE to TEST-13-NSPAWNFrantisek Sumsal2023-05-143-2/+2
| | | | | | | | To make it consistent with the rest of the tests.
| * test: slightly extend the systemd-nspawn testsFrantisek Sumsal2023-05-142-0/+235
| |
| * test: wait after sending a signal if necessaryFrantisek Sumsal2023-05-141-3/+3
| | | | | | | | | | On overloaded systems it might take a bit until the signal is sent, processed, and the respective file is created.
| * nspawn: simplify error handlingFrantisek Sumsal2023-05-141-6/+4
| |
| * test: install the overlayfs/loop modules unconditionallyFrantisek Sumsal2023-05-144-37/+22
| |
| * test: create merged-usr containersFrantisek Sumsal2023-05-141-18/+22
| |
| * test: bind mount the $BUILD_DIR into nspawn containersFrantisek Sumsal2023-05-142-5/+6
| | | | | | | | | | when collecting coverage. This applies only to containers started via machinectl (or directly via the systemd-nspawn@.service unit).
| * test: use dropins to override system configurationFrantisek Sumsal2023-05-141-11/+13
| | | | | | | | Instead of touching the configuration files directly.
| * vimrc: use 109ch text width for shell scripts as wellFrantisek Sumsal2023-05-131-1/+1
|/
* po: Translated using Weblate (Belarusian)Maksim Kliazovich2023-05-131-12/+11
| | | | | | | | Currently translated at 100.0% (193 of 193 strings) Co-authored-by: Maksim Kliazovich <maxklezovich@gmail.com> Translate-URL: https://translate.fedoraproject.org/projects/systemd/master/be/ Translation: systemd/main
* sd-dhcp-server: also send DNS servers or friends on DHCPOFFERYu Watanabe2023-05-131-30/+27
| | | | | | | | | | | | | | | From RFC 2131 section 4.3.1 (https://www.rfc-editor.org/rfc/rfc2131#section-4.3.1): ---- The server MUST return to the client: - Parameters requested by the client, according to the following rules: -- IF the server has been explicitly configured with a default value for the parameter, the server MUST include that value in an appropriate option in the 'option' field, ---- The sentence is not only for ACK, but for all (positive) responses, that is DHCPOFFER and DHCPACK. Fixes #27471.
* Merge pull request #27605 from YHNdnzj/dbus-activation-followupLuca Boccassi2023-05-134-18/+31
|\ | | | | core: only refuse Type=dbus service enqueue if dbus has pending stop job
| * Revert "core/manager: export manager_dbus_is_running" and partially "core: ↵Mike Yuan2023-05-123-11/+7
| | | | | | | | | | | | | | | | | | | | refuse dbus activation if dbus is not running" This reverts commit e8863150653931ae2ffc91757623f179ce763628 and partially 53964fd26b4a01191609ffc064aa8ccccd28e377. Specifically, changes to signal_activation_request() is not desired.
| * core: only refuse Type=dbus service enqueuing if dbus has stop jobMike Yuan2023-05-121-7/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Follow-up for #27579 In #27579 we refused all StartUnit requests for Type=dbus units if dbus is not running, which means if dbus is manually stopped, user can't use systemctl to start Type=dbus units again, which is incorrect. The only culprit that leads to the cancellation of the whole transaction mentioned in #26799 is job type conflict on dbus. So let's relax the restriction and only refuse job enqueuing if dbus has a stop job. To summarize, the case we want to avoid is: 1. dbus has a stop job installed 2. StartUnit/ActivationRequest is received 3. Type=dbus service gets started, which has Requires=dbus.socket 4. dbus is pulled in again, resulting in job type conflict What we can support is: 1. dbus is already stopped 2. StartUnit is received (possibly through systemctl, i.e. on private bus) 3. Type=dbus service gets started, which will wait for dbus to start 4. dbus is started again, thus the job for Type=dbus service Replaces #27590 Fixes #27588
* | Merge pull request #27571 from DaanDeMeyer/mkosiLuca Boccassi2023-05-1322-19/+95
|\ \ | | | | | | mkosi: Package a erofs usr partition with signed verity
| * | mkosi: Package a erofs usr partition with signed verityDaan De Meyer2023-05-1320-18/+88
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Let's start moving towards a more involved partitioning setup to test our stuff more when using mkosi. The root partition is generated on boot with systemd-repart. CentOS supports neither erofs nor btrfs so we use squashfs and xfs instead. We also enable SecureBoot= locally for additional coverage. This and the use of verity means users need to run `mkosi genkey` once to generate the keys necessary to do secure boot and verity.
| * | mkosi: Store /etc under /usr/share/factory/mkosiDaan De Meyer2023-05-132-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | If we're making a /usr only image, we still want to populate /etc fully on first boot. To make that possible, let's copy /etc to /usr/share/factory/mkosi in a finalize script, which runs after all changes to the image have been made. Let's also add a tmpfiles snippet that merges /usr/share/factory/mkosi with /etc on boot to populate /etc.
| * | mkosi: Do not enable ACL usage by defaultDaan De Meyer2023-05-131-1/+0
| | | | | | | | | | | | | | | | | | This is only useful to be able to remove generated files using rm -rf instead of mkosi clean and has some implications for the generated rootfs so let's not enable it by default.
* | | Merge pull request #27634 from mrc0mmand/TEST-13-shenanigansLuca Boccassi2023-05-1312-331/+626
|\ \ \ | |/ / |/| | test: clean up & extend the nspawn/machinectl test suite
| * | machine,portable: fix a typo in an info messageFrantisek Sumsal2023-05-132-2/+2
| | |
| * | test: merge machinectl edit/cat tests into TEST-13Frantisek Sumsal2023-05-132-36/+19
| | |
| * | test: always install the script utilityFrantisek Sumsal2023-05-133-8/+1
| | |
| * | test: add a couple of tests for machinectlFrantisek Sumsal2023-05-135-367/+582
| | |
| * | machine: fix a memory leak when showing multiple machinesFrantisek Sumsal2023-05-121-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | + machinectl status long-running long-running long-running ================================================================= ==986==ERROR: LeakSanitizer: detected memory leaks Direct leak of 1568 byte(s) in 2 object(s) allocated from: #0 0x7fe57caba097 in calloc (/lib64/libasan.so.8+0xba097) #1 0x7fe57b891e8e in message_from_header ../src/libsystemd/sd-bus/bus-message.c:372 #2 0x7fe57b892dfd in bus_message_from_malloc ../src/libsystemd/sd-bus/bus-message.c:421 #3 0x7fe57b9089a8 in bus_socket_make_message ../src/libsystemd/sd-bus/bus-socket.c:1165 #4 0x7fe57b90affe in bus_socket_read_message ../src/libsystemd/sd-bus/bus-socket.c:1294 #5 0x7fe57b92db71 in bus_read_message ../src/libsystemd/sd-bus/sd-bus.c:2082 #6 0x7fe57b933352 in sd_bus_call ../src/libsystemd/sd-bus/sd-bus.c:2483 #7 0x7fe57b84da61 in sd_bus_call_methodv ../src/libsystemd/sd-bus/bus-convenience.c:183 #8 0x7fe57b2789e8 in bus_call_method ../src/shared/bus-locator.c:109 #9 0x40f71c in show_machine ../src/machine/machinectl.c:713 #10 0x7fe57b65c8cf in dispatch_verb ../src/shared/verbs.c:103 #11 0x42e9ce in machinectl_main ../src/machine/machinectl.c:2980 #12 0x42ebf9 in run ../src/machine/machinectl.c:3005 #13 0x42ed1f in main ../src/machine/machinectl.c:3008 #14 0x7fe579e4a50f in __libc_start_call_main (/lib64/libc.so.6+0x2750f) Indirect leak of 234 byte(s) in 2 object(s) allocated from: #0 0x7fe57cab95b5 in __interceptor_realloc.part.0 (/lib64/libasan.so.8+0xb95b5) #1 0x7fe57b909822 in bus_socket_read_message ../src/libsystemd/sd-bus/bus-socket.c:1214 #2 0x7fe57b92db71 in bus_read_message ../src/libsystemd/sd-bus/sd-bus.c:2082 #3 0x7fe57b933352 in sd_bus_call ../src/libsystemd/sd-bus/sd-bus.c:2483 #4 0x7fe57b84da61 in sd_bus_call_methodv ../src/libsystemd/sd-bus/bus-convenience.c:183 #5 0x7fe57b2789e8 in bus_call_method ../src/shared/bus-locator.c:109 #6 0x40f71c in show_machine ../src/machine/machinectl.c:713 #7 0x7fe57b65c8cf in dispatch_verb ../src/shared/verbs.c:103 #8 0x42e9ce in machinectl_main ../src/machine/machinectl.c:2980 #9 0x42ebf9 in run ../src/machine/machinectl.c:3005 #10 0x42ed1f in main ../src/machine/machinectl.c:3008 #11 0x7fe579e4a50f in __libc_start_call_main (/lib64/libc.so.6+0x2750f) Indirect leak of 4 byte(s) in 2 object(s) allocated from: #0 0x7fe57ca7243b in strdup (/lib64/libasan.so.8+0x7243b) #1 0x7fe57b8c1543 in message_parse_fields ../src/libsystemd/sd-bus/bus-message.c:4125 #2 0x7fe57b893586 in bus_message_from_malloc ../src/libsystemd/sd-bus/bus-message.c:443 #3 0x7fe57b9089a8 in bus_socket_make_message ../src/libsystemd/sd-bus/bus-socket.c:1165 #4 0x7fe57b90affe in bus_socket_read_message ../src/libsystemd/sd-bus/bus-socket.c:1294 #5 0x7fe57b92db71 in bus_read_message ../src/libsystemd/sd-bus/sd-bus.c:2082 #6 0x7fe57b933352 in sd_bus_call ../src/libsystemd/sd-bus/sd-bus.c:2483 #7 0x7fe57b84da61 in sd_bus_call_methodv ../src/libsystemd/sd-bus/bus-convenience.c:183 #8 0x7fe57b2789e8 in bus_call_method ../src/shared/bus-locator.c:109 #9 0x40f71c in show_machine ../src/machine/machinectl.c:713 #10 0x7fe57b65c8cf in dispatch_verb ../src/shared/verbs.c:103 #11 0x42e9ce in machinectl_main ../src/machine/machinectl.c:2980 #12 0x42ebf9 in run ../src/machine/machinectl.c:3005 #13 0x42ed1f in main ../src/machine/machinectl.c:3008 #14 0x7fe579e4a50f in __libc_start_call_main (/lib64/libc.so.6+0x2750f) SUMMARY: AddressSanitizer: 1806 byte(s) leaked in 6 allocation(s).
| * | machine: fix a memory leak when showing multiple imagesFrantisek Sumsal2023-05-121-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | + machinectl image-status container1 container1 container0 container1 container2 container3 container4 ================================================================= ==1354==ERROR: LeakSanitizer: detected memory leaks Direct leak of 4704 byte(s) in 6 object(s) allocated from: #0 0x7fc3670ba097 in calloc (/lib64/libasan.so.8+0xba097) #1 0x7fc365e91e8e in message_from_header ../src/libsystemd/sd-bus/bus-message.c:372 #2 0x7fc365e92dfd in bus_message_from_malloc ../src/libsystemd/sd-bus/bus-message.c:421 #3 0x7fc365f089a8 in bus_socket_make_message ../src/libsystemd/sd-bus/bus-socket.c:1165 #4 0x7fc365f0affe in bus_socket_read_message ../src/libsystemd/sd-bus/bus-socket.c:1294 #5 0x7fc365f2db71 in bus_read_message ../src/libsystemd/sd-bus/sd-bus.c:2082 #6 0x7fc365f33352 in sd_bus_call ../src/libsystemd/sd-bus/sd-bus.c:2483 #7 0x7fc365e4da61 in sd_bus_call_methodv ../src/libsystemd/sd-bus/bus-convenience.c:183 #8 0x7fc3658789e8 in bus_call_method ../src/shared/bus-locator.c:109 #9 0x413b76 in show_image ../src/machine/machinectl.c:1014 #10 0x7fc365c5c8cf in dispatch_verb ../src/shared/verbs.c:103 #11 0x42e992 in machinectl_main ../src/machine/machinectl.c:2981 #12 0x42ebbd in run ../src/machine/machinectl.c:3006 #13 0x42ece3 in main ../src/machine/machinectl.c:3009 #14 0x7fc36444a50f in __libc_start_call_main (/lib64/libc.so.6+0x2750f) Indirect leak of 666 byte(s) in 6 object(s) allocated from: #0 0x7fc3670b95b5 in __interceptor_realloc.part.0 (/lib64/libasan.so.8+0xb95b5) #1 0x7fc365f09822 in bus_socket_read_message ../src/libsystemd/sd-bus/bus-socket.c:1214 #2 0x7fc365f2db71 in bus_read_message ../src/libsystemd/sd-bus/sd-bus.c:2082 #3 0x7fc365f33352 in sd_bus_call ../src/libsystemd/sd-bus/sd-bus.c:2483 #4 0x7fc365e4da61 in sd_bus_call_methodv ../src/libsystemd/sd-bus/bus-convenience.c:183 #5 0x7fc3658789e8 in bus_call_method ../src/shared/bus-locator.c:109 #6 0x413b76 in show_image ../src/machine/machinectl.c:1014 #7 0x7fc365c5c8cf in dispatch_verb ../src/shared/verbs.c:103 #8 0x42e992 in machinectl_main ../src/machine/machinectl.c:2981 #9 0x42ebbd in run ../src/machine/machinectl.c:3006 #10 0x42ece3 in main ../src/machine/machinectl.c:3009 #11 0x7fc36444a50f in __libc_start_call_main (/lib64/libc.so.6+0x2750f) Indirect leak of 12 byte(s) in 6 object(s) allocated from: #0 0x7fc36707243b in strdup (/lib64/libasan.so.8+0x7243b) #1 0x7fc365ec1543 in message_parse_fields ../src/libsystemd/sd-bus/bus-message.c:4125 #2 0x7fc365e93586 in bus_message_from_malloc ../src/libsystemd/sd-bus/bus-message.c:443 #3 0x7fc365f089a8 in bus_socket_make_message ../src/libsystemd/sd-bus/bus-socket.c:1165 #4 0x7fc365f0affe in bus_socket_read_message ../src/libsystemd/sd-bus/bus-socket.c:1294 #5 0x7fc365f2db71 in bus_read_message ../src/libsystemd/sd-bus/sd-bus.c:2082 #6 0x7fc365f33352 in sd_bus_call ../src/libsystemd/sd-bus/sd-bus.c:2483 #7 0x7fc365e4da61 in sd_bus_call_methodv ../src/libsystemd/sd-bus/bus-convenience.c:183 #8 0x7fc3658789e8 in bus_call_method ../src/shared/bus-locator.c:109 #9 0x413b76 in show_image ../src/machine/machinectl.c:1014 #10 0x7fc365c5c8cf in dispatch_verb ../src/shared/verbs.c:103 #11 0x42e992 in machinectl_main ../src/machine/machinectl.c:2981 #12 0x42ebbd in run ../src/machine/machinectl.c:3006 #13 0x42ece3 in main ../src/machine/machinectl.c:3009 #14 0x7fc36444a50f in __libc_start_call_main (/lib64/libc.so.6+0x2750f) SUMMARY: AddressSanitizer: 5382 byte(s) leaked in 18 allocation(s).
| * | test: clean up the nspawn tests a bitFrantisek Sumsal2023-05-124-152/+258
| | |
* | | sulogin: Read SYSTEMD_SULOGIN_FORCE from kernel cmdlineDaan De Meyer2023-05-132-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | This allows setting it on the kernel cmdline and having it work automatically without having to write any dropins or such. Also enable the option in mkosi so that we can debug the initrd properly with a locked root account.