Lennart Poettering [Tue, 10 Dec 2019 10:52:54 +0000 (11:52 +0100)]
tree-wide: use SD_ID128_STRING_MAX where appropriate
Lennart Poettering [Tue, 10 Dec 2019 10:33:28 +0000 (11:33 +0100)]
id128: introduce ID128_UUID_STRING_MAX for sizing UUID buffers
Anita Zhang [Mon, 9 Dec 2019 21:33:36 +0000 (13:33 -0800)]
Merge pull request #14284 from yuwata/network-fix-segfault-14283
network: fix segfault in parsing SendOption=
Yu Watanabe [Sun, 8 Dec 2019 10:54:49 +0000 (19:54 +0900)]
test-network: add a test case for SendOption=
Yu Watanabe [Sun, 8 Dec 2019 10:54:20 +0000 (19:54 +0900)]
network: fix segfault in parsing SendOption=
Fixes #14283.
Mike Gilbert [Fri, 6 Dec 2019 19:28:13 +0000 (14:28 -0500)]
seccomp: real syscall numbers are >= 0
Real syscall numbers start at 0. The fake seccomp values seem to be
strictly less than 0.
Fixes:
4df8fe8415eaf4abd5b93c3447452547c6ea9e5f
Yong Cong Sin [Sat, 7 Dec 2019 14:15:02 +0000 (01:15 +1100)]
Add Cube iWork 11 Stylus
Yu Watanabe [Sun, 8 Dec 2019 15:57:06 +0000 (00:57 +0900)]
test: do not fail if new device is plugged during enumeration
Yu Watanabe [Sun, 8 Dec 2019 15:39:33 +0000 (00:39 +0900)]
test-network: make test_bind_carrier more stable
Yu Watanabe [Sun, 8 Dec 2019 15:15:31 +0000 (00:15 +0900)]
Merge pull request #14266 from topimiettinen/dont-resolve-user-if-not-root
resolved: don't resolve the user if not root
Yu Watanabe [Sat, 7 Dec 2019 20:13:08 +0000 (05:13 +0900)]
Merge pull request #14273 from ssahani/ifb
network: introduce IFB
Yu Watanabe [Sat, 7 Dec 2019 14:20:37 +0000 (23:20 +0900)]
network: fix copy and paste mistake
Topi Miettinen [Fri, 6 Dec 2019 14:36:58 +0000 (16:36 +0200)]
resolved, networkd: don't resolve the user if not root
If a daemon is not started as root, most likely it also can't create its
directory and let's not try to resolve the user in that case either.
Create /run/systemd/netif/lldp with tmpfiles.d like other netif directories.
This is also very helpful for preparing a RootImage for the daemons as NSS crud
is not needed.
Yu Watanabe [Sat, 7 Dec 2019 15:03:29 +0000 (00:03 +0900)]
test-network: add test case for IFB
Susant Sahani [Sat, 7 Dec 2019 13:35:55 +0000 (14:35 +0100)]
network: introduce ifb (Intermediate Functional Block)
Intermediate Functional Block
The Intermediate Functional Block (ifb) pseudo network interface acts as a QoS concentrator for multiple different sources of traffic. Packets from or to other interfaces have to be redirected to it using the mirred action in order to be handled, regularly routed traffic will be dropped. This way, a single stack of qdiscs, classes and filters can be shared between multiple interfaces.
Here's a simple example to feed incoming traffic from multiple interfaces through a Stochastic Fairness Queue (sfq):
(1) # modprobe ifb
(2) # ip link set ifb0 up
(3) # tc qdisc add dev ifb0 root sfq
Susant Sahani [Sat, 7 Dec 2019 13:35:23 +0000 (14:35 +0100)]
sd-netlink: add support for ifb device
Yu Watanabe [Sat, 7 Dec 2019 05:11:44 +0000 (14:11 +0900)]
Merge pull request #14102 from ssahani/acd-duplicate-ip
network: introduce DAD for static IPV4 address
Anita Zhang [Fri, 6 Dec 2019 19:02:56 +0000 (11:02 -0800)]
Merge pull request #14265 from keszybz/seccomp-log-line-fix
shared/seccomp: avoid possibly writing bogus errno code in debug log
Yu Watanabe [Fri, 6 Dec 2019 14:29:28 +0000 (23:29 +0900)]
test-network: add test case for IPv4 DAD
Susant Sahani [Thu, 21 Nov 2019 15:54:52 +0000 (16:54 +0100)]
network: introduce DAD for static address
Closes #2527.
Zbigniew Jędrzejewski-Szmek [Fri, 6 Dec 2019 14:04:51 +0000 (15:04 +0100)]
shared/seccomp: avoid possibly writing bogus errno code in debug log
CID
1409488.
This code was added in
903659e7b242c3cc897e32835f1918d380b24e5f. The change
that is done here is a simple fix to avoid use of a
unitialized/wrongly-initialized variable, but the bigger issue is that nothing
looks at the returned result to distinguish between 0 and a positive return
value.
Zbigniew Jędrzejewski-Szmek [Fri, 6 Dec 2019 11:46:42 +0000 (12:46 +0100)]
Merge pull request #14235 from fbuihuu/cryptsetup-fixes
Cryptsetup fixes
Yu Watanabe [Thu, 5 Dec 2019 10:54:29 +0000 (19:54 +0900)]
network: do not drop foreign config if interface is in initialized state
If the interface is in initialized state, no network file is assigned to
the interface. If an interface is not managed by networkd, previously,
the foreign configs of the interface was dropped.
Fixes #14250.
Lennart Poettering [Fri, 6 Dec 2019 07:55:30 +0000 (08:55 +0100)]
Merge pull request #14252 from keszybz/growfs-port-resizefs
Port growfs over to resizefs
Lennart Poettering [Fri, 6 Dec 2019 07:55:15 +0000 (08:55 +0100)]
Merge pull request #14253 from keszybz/cleanups
Cleanups
Lennart Poettering [Fri, 6 Dec 2019 07:54:54 +0000 (08:54 +0100)]
Merge pull request #14167 from cpaelzer/fix-MemoryDenyWriteExecute-x86-s390-bug-
1853852-UPSTREAM
Fix memory_deny_write_execute on x86 and s390 with libseccomp 2.4.2
Anita Zhang [Thu, 5 Dec 2019 18:55:20 +0000 (10:55 -0800)]
Merge pull request #14258 from TimoWilken/patch-1
Fix typo (duplicate "or")
Timo Wilken [Thu, 5 Dec 2019 18:36:57 +0000 (18:36 +0000)]
Fix typo (duplicate "or")
This fixes a double "or" in the text of `systemctl --help`.
Franck Bui [Tue, 3 Dec 2019 08:49:09 +0000 (09:49 +0100)]
cryptsetup: umount encrypted devices before detaching it during shutdown
This is done by ordering local-fs-pre.target and remote-fs-pre.target after
cryptsetup.target and remote-cryptsetup.target respectively.
Fixes: #8472
Franck Bui [Tue, 3 Dec 2019 08:30:57 +0000 (09:30 +0100)]
crypsetup: introduce x-initrd.attach option
This option is an indication for PID1 that the entry in crypttab is handled by
initrd only and therefore it shouldn't interfer during the usual start-up and
shutdown process.
It should be primarily used with the encrypted device containing the root FS as
we want to keep it (and thus its encrypted device) until the very end of the
shutdown process, i.e. when initrd takes over.
This option is the counterpart of "x-initrd.mount" used in fstab.
Note that the slice containing the cryptsetup services also needs to drop the
usual shutdown dependencies as it's required by the cryptsetup services.
Fixes: #14224
Zbigniew Jędrzejewski-Szmek [Thu, 5 Dec 2019 09:31:55 +0000 (10:31 +0100)]
TODO: remove obsolete entries
"introspect" is well established and OK. We shouldn't change it at this point.
Zbigniew Jędrzejewski-Szmek [Wed, 4 Dec 2019 13:51:33 +0000 (14:51 +0100)]
Fix use of unitialized variable in error path
CID
1408478.
Zbigniew Jędrzejewski-Szmek [Thu, 5 Dec 2019 09:22:01 +0000 (10:22 +0100)]
Merge pull request #14209 from poettering/sd-bus-sensitive
sd-bus bits from homed PR
Zbigniew Jędrzejewski-Szmek [Thu, 5 Dec 2019 09:17:10 +0000 (10:17 +0100)]
Merge pull request #14221 from poettering/homed-preparatory-resizefs
preparatory fs resizing support split out of homed PR
Zbigniew Jędrzejewski-Szmek [Thu, 5 Dec 2019 09:15:49 +0000 (10:15 +0100)]
growfs: port over to resize_fs()
Zbigniew Jędrzejewski-Szmek [Thu, 5 Dec 2019 08:22:13 +0000 (09:22 +0100)]
growfs: define main function through macro
Yu Watanabe [Thu, 5 Dec 2019 07:10:29 +0000 (16:10 +0900)]
Merge pull request #14229 from yuwata/nspawn-network-interface-14223
nspawn: do not fail if udev is not running
Christian Ehrhardt [Wed, 4 Dec 2019 10:44:32 +0000 (11:44 +0100)]
seccomp: mmap test results depend on kernel/libseccomp/glibc
Like with shmat already the actual results of the test
test_memory_deny_write_execute_mmap depend on kernel/libseccomp/glibc
of the platform it is running on.
There are known-good platforms, but on the others do not assert success
(which implies test has actually failed as no seccomp blocking was achieved),
but instead make the check dependent to the success of the mmap call
on that platforms.
Finally the assert of the munmap on that valid pointer should return ==0,
so that is what the check should be for in case of p != MAP_FAILED.
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Christian Ehrhardt [Wed, 27 Nov 2019 09:53:50 +0000 (10:53 +0100)]
seccomp: use per arch shmat_syscall
At the beginning of seccomp_memory_deny_write_execute architectures
can set individual filter_syscall, block_syscall, shmat_syscall values.
The former two are then used in the call to add_seccomp_syscall_filter
but shmat_syscall is not.
Right now all shmat_syscall values are the same, so the change is a
no-op, but if ever an architecture is added/modified this would be a
subtle source for a mistake so fix it by using shmat_syscall later.
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Christian Ehrhardt [Wed, 27 Nov 2019 08:57:55 +0000 (09:57 +0100)]
seccomp: ensure rules are loaded in seccomp_memory_deny_write_execute
If seccomp_memory_deny_write_execute was fatally failing to load rules it
already returned a bad retval.
But if any adding filters failed it skipped the subsequent seccomp_load and
always returned an rc of 0 even if no rule was loaded at all.
Lets fix this requiring to (non fatally-failing) load at least one rule set.
Signed-off-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
Christian Ehrhardt [Wed, 27 Nov 2019 08:52:07 +0000 (09:52 +0100)]
seccomp: fix multiplexed system calls
Since libseccomp 2.4.2 more architectures have shmat handled as multiplexed
call. Those will fail to be added due to seccomp_rule_add_exact failing
on them since they'd need to add multiple rules [1].
See the discussion at https://github.com/seccomp/libseccomp/issues/193
After discussions about the options rejected [2][3] the initial thought of
a fallback to the non '_exact' version of the seccomp rule adding the next
option is to handle those now affected (i386, s390, s390x) the same way as
ppc which ignores and does not block shmat.
[1]: https://github.com/seccomp/libseccomp/issues/193
[2]: https://github.com/systemd/systemd/pull/14167#issuecomment-
559136906
[3]: https://github.com/systemd/systemd/commit/
469830d1
Anita Zhang [Thu, 5 Dec 2019 00:14:11 +0000 (16:14 -0800)]
Merge pull request #14173 from ssahani/tc-sfq
network: tc: introduce sfq and tbf
Anita Zhang [Thu, 5 Dec 2019 00:07:41 +0000 (16:07 -0800)]
Merge pull request #14219 from poettering/homed-preparatory-loop
preparatory /dev/loopN support split out of homed PR
Yu Watanabe [Wed, 4 Dec 2019 10:12:36 +0000 (19:12 +0900)]
network: if /sys is rw, then udev should be around
This switches detect_container() to path_is_read_only_rw("/sys"), as if
systemd-udevd.service is conditionalized with that way.
This also updates the log message.
Yu Watanabe [Mon, 2 Dec 2019 15:51:44 +0000 (00:51 +0900)]
nspawn: do not fail if udev is not running
If /sys is read only filesystem, e.g., nspawn is running in container,
then usually udev is not running. In such a case, let's assume that
the interface is already initialized. Also, this makes nspawn refuse
to use the network interface which is under renaming.
Fixes #14223.
Guilhem Lettron [Sat, 30 Nov 2019 02:51:40 +0000 (03:51 +0100)]
Implement SNI when using DNS-over-TLS
Some DNS providers need SNI to identify client.
This can be used by adding #name to a DNS.
Example:
[Resolve]
DNS=192.168.1.1#example.com
Lennart Poettering [Wed, 4 Dec 2019 13:12:24 +0000 (14:12 +0100)]
Merge pull request #14111 from keszybz/unknown-section-warning
Warn about unknown sections
Lennart Poettering [Tue, 20 Aug 2019 13:35:53 +0000 (15:35 +0200)]
sd-bus: don't include properties maked as "emit-invalidation" in InterfacesAdded signals
Properties marked this way really shouldn't be sent around willy-nilly,
that's what the flag is about, hence exclude it from InterfacesAdded
signals (and in fact anything that is a signal).
Lennart Poettering [Mon, 19 Aug 2019 18:28:34 +0000 (20:28 +0200)]
sd-bus: add new call sd_bus_message_sensitive() and SD_BUS_VTABLE_SENSITIVE
This allows marking messages that contain "sensitive" data with a flag.
If it's set then the messages are erased from memory when the message is
freed.
Similar, a flag may be set on vtable entries: incoming/outgoing message
matching the entry will then automatically be flagged this way.
This is supposed to be an easy method to mark messages containing
potentially sensitive data (such as passwords) for proper destruction.
(Note that this of course is only is as safe as the broker in between is
doing something similar. But let's at least not be the ones at fault
here.)
Zbigniew Jędrzejewski-Szmek [Wed, 4 Dec 2019 12:30:52 +0000 (13:30 +0100)]
Merge pull request #13953 from SpencerMichaels/systemd-boot-efistub-id-fix
boot: Fix default/oneshot selection for EFISTUB entries
Lennart Poettering [Wed, 4 Dec 2019 12:13:38 +0000 (13:13 +0100)]
Merge pull request #14218 from poettering/homed-preparatory-small-stuff
Assorted smaller stuff split out from homed PR
Lennart Poettering [Wed, 4 Dec 2019 12:13:18 +0000 (13:13 +0100)]
Merge pull request #13886 from poettering/sd-event-pidfd
add pidfd support to sd-event (but not yet PID 1)
Yu Watanabe [Tue, 3 Dec 2019 14:20:50 +0000 (23:20 +0900)]
test-network: add a test case for SFQ
Yu Watanabe [Tue, 3 Dec 2019 14:12:00 +0000 (23:12 +0900)]
network: SFQ cannot be configured with netem or TBF
Susant Sahani [Wed, 27 Nov 2019 11:42:21 +0000 (12:42 +0100)]
network: tc introduce sfq - Stochastic Fairness Queueing
Stochastic Fairness Queueing is a classless queueing discipline.
SFQ does not shape traffic but only schedules the transmission of packets, based on 'flows'.
The goal is to ensure fairness so that each flow is able to send data in turn,
thus preventing any single flow from drowning out the rest.
Yu Watanabe [Sun, 24 Nov 2019 12:23:48 +0000 (21:23 +0900)]
test-network: add test case for TBF
Yu Watanabe [Mon, 25 Nov 2019 14:15:08 +0000 (23:15 +0900)]
network: drop unnecessary headers
Yu Watanabe [Mon, 25 Nov 2019 14:13:54 +0000 (23:13 +0900)]
network: make network_emulator_fill_message() take NetworkEmulator
Yu Watanabe [Mon, 25 Nov 2019 14:07:58 +0000 (23:07 +0900)]
network: rename QDiscs to QDisc
Yu Watanabe [Sun, 24 Nov 2019 11:31:38 +0000 (20:31 +0900)]
network: ignore sections which have both NetworkEmulator and TokenBufferFilter settings
Susant Sahani [Sun, 17 Nov 2019 06:30:03 +0000 (07:30 +0100)]
networkd tc: introduce tbf
See https://linux.die.net/man/8/tc-tbf
Lennart Poettering [Thu, 27 Dec 2018 13:31:27 +0000 (14:31 +0100)]
shared: add new wrapper for online fs resizing ioctls
Lennart Poettering [Fri, 28 Dec 2018 18:01:53 +0000 (19:01 +0100)]
missing: add XFS magic
Lennart Poettering [Fri, 17 May 2019 08:17:06 +0000 (10:17 +0200)]
main-func: send main exit code to parent via sd_notify() on exit
So far we silently convert negative return values from run() as
EXIT_FAILURE, which is how UNIX expects it. In many cases it would be
very useful for the caller to retrieve the actual error number we exit
with. Let's generically return that via sd_notify()'s ERRNO= attribute.
This means callers can set $NOTIFY_SOCKET and get the actual error
number delivered at their doorstep just like that.
Lennart Poettering [Mon, 6 May 2019 20:38:43 +0000 (22:38 +0200)]
process-util: add new safe_fork() flag for connecting stdout to stderr
This adds a new safe_fork() flag. If set the child process' fd 1 becomes
fd 2 of the caller. This is useful for invoking tools (such as various
mkfs/fsck implementations) that output status messages to stdout, but
which we invoke and don't want to pollute stdout with their output.
Lennart Poettering [Thu, 4 Jul 2019 14:48:32 +0000 (16:48 +0200)]
tmpfile-util: modernize mkostemp_safe() a bit
Lennart Poettering [Tue, 23 Apr 2019 13:23:48 +0000 (15:23 +0200)]
tmpfile-util: if no path is passed to fopen_temporary() make one up
Let's beef up functionality a bit, and modernize the whole function.
Lennart Poettering [Wed, 7 Aug 2019 10:34:46 +0000 (12:34 +0200)]
user-util: add uid_is_container() for checking whether UID is in container range
We have similar calls for the dynamic user and system range, let's add
this too here.
Lennart Poettering [Wed, 7 Aug 2019 10:34:29 +0000 (12:34 +0200)]
user-util: export is_nologin_shell() so that we can use it elsewhere
Charles (Chas) Williams [Thu, 21 Nov 2019 15:26:24 +0000 (10:26 -0500)]
man: document journal rate limit burst multiplier
The actual burst limit is modified by the remaining disk space. This
isn't mentioned anywhere in the available documentation and might be a
source of surprise for an end user expecting certain behaviors.
Lennart Poettering [Thu, 11 Jul 2019 12:50:26 +0000 (14:50 +0200)]
string-util: readd string_erase()
This was dropped in
8e27167cc9b8beda2bf49789b15f0b0301b95d17, but is
actually useful for some usecases still.
Lennart Poettering [Thu, 8 Aug 2019 17:53:17 +0000 (19:53 +0200)]
memory-util: introduce erase_and_free() helper
Lennart Poettering [Mon, 15 Jul 2019 11:32:03 +0000 (13:32 +0200)]
errno-util: add new ERRNO_IS_DISK_SPACE() helper
Lennart Poettering [Mon, 19 Aug 2019 16:06:03 +0000 (18:06 +0200)]
ordered-set: add ordered_set_first() helper
Lennart Poettering [Thu, 14 Nov 2019 13:49:40 +0000 (14:49 +0100)]
parse-util: sometimes it is useful to check if a string is a valid integer, but not actually parse it
Leonid Bloch [Sun, 1 Dec 2019 23:05:02 +0000 (01:05 +0200)]
sd-boot: Add a 0.1 second delay before key-probing for showing menu
If there is no boot menu timeout, pressing a key during boot should get
the boot menu displayed. However, on some systems the keyboard is not
initialized right away, which causes the menu to be inaccessible if no
timeout is specified.
To resolve this, if the error is "not ready" after the initial attempt of
detection, wait for 0.1 second and retry. This solves the problem
described above on all the tested systems.
The reason for just a single retry, and not retrying while "not ready",
is that some firmwares continue to return the "not ready" error on
every probe attempt if no key is pressed.
Signed-off-by: Leonid Bloch <lb.workbox@gmail.com>
Lennart Poettering [Wed, 30 Oct 2019 19:26:50 +0000 (20:26 +0100)]
sd-event: refuse running default event loops in any other thread than the one they are default for
Lennart Poettering [Wed, 30 Oct 2019 18:00:12 +0000 (19:00 +0100)]
man: document the new sd-event pidfd magic
Lennart Poettering [Wed, 30 Oct 2019 17:59:44 +0000 (18:59 +0100)]
man: mention that SIGCHLD has to be blocked before using sd_event_add_child()
Lennart Poettering [Wed, 30 Oct 2019 17:56:03 +0000 (18:56 +0100)]
man: don't claim we'd unblock the specified signal in sd_event_add_signal()
We don't, the signal remains blocked. We use signalfd() to be able to
read the signal events without unblocking the signal.
While we are at it, mention that pthread_sigmask() is fine too.
Lennart Poettering [Wed, 30 Oct 2019 16:42:31 +0000 (17:42 +0100)]
test: add test for pidfd support in sd-event
Lennart Poettering [Wed, 30 Oct 2019 16:41:15 +0000 (17:41 +0100)]
sd-event: refuse sd_event_add_child() if SIGCHLD is not blocked
We already refuse sd_event_add_signal() if the specified signal is not
blocked, let's do this also for sd_event_add_child(), since we might
need signalfd() to implement this, and this means the signal needs to be
blocked.
Lennart Poettering [Wed, 30 Oct 2019 16:37:12 +0000 (17:37 +0100)]
sd-event: make use of new signal_is_blocked() helper
Lennart Poettering [Wed, 30 Oct 2019 16:37:00 +0000 (17:37 +0100)]
signal-util: add new helper signal_is_blocked()
Lennart Poettering [Wed, 30 Oct 2019 16:22:49 +0000 (17:22 +0100)]
sd-event: add pidfd support
This adds support for watching for process exits via Linux new pidfd
concept. This makes watching processes and killing them race-free if
properly used, fixing a long-standing UNIX misdesign.
This patch adds implicit and explicit pidfd support to sd-event: if a
process shall be watched and is specified by PID we will now internally
create a pidfd for it and use that, if available. Alternatively a new
constructor for child process event sources is added that takes pidfds
as input.
Besides mere watching of child processes via pidfd two additional
features are added:
→ sd_event_source_send_child_signal() allows sending a signal to the
process being watched in the safest way possible (wrapping
the new pidfd_send_signal() syscall).
→ sd_event_source_set_child_process_own() allows marking a process
watched for destruction as soon as the event source is freed. This is
currently implemented in userspace, but hopefully will become a kernel
feature eventually.
Altogether this means an sd_event_source object is now a safe and stable
concept for referencing processes in race-free way, with automatic
fallback to pre-pidfd kernels.
Note that this patch adds support for this only to sd-event, not to PID
1. That's because PID 1 needs to use waitid(P_ALL) for reaping any
process that might get reparented to it. This currently semantically
conflicts with pidfd use for watching processes since we P_ALL is
undirected and thus might reap process earlier than the pidfd notifies
process end, which is hard to handle. The kernel will likely gain a
concept for excluding specific pidfds from P_ALL watching, as soon as
that is around we can start making use of this in PID 1 too.
Lennart Poettering [Wed, 30 Oct 2019 15:35:48 +0000 (16:35 +0100)]
process-util: add helper pidfd_get_pid()
It returns the pid_t a pidfd refers to.
Lennart Poettering [Wed, 30 Oct 2019 15:29:42 +0000 (16:29 +0100)]
missing: add rt_sigqueueinfo() syscall definition
This is not a new system call at all (since kernel 2.2), however it's
not exposed in glibc (a wrapper is exposed however in sigqueue(), but it
substantially simplifies the system call). Since we want a nice fallback
for sending signals on non-pidfd systems for pidfd_send_signal() let's
wrap rt_sigqueueinfo() since it takes the same siginfo_t parameter.
Lennart Poettering [Fri, 25 Oct 2019 14:06:06 +0000 (16:06 +0200)]
missing: define new pidfd syscalls
Lennart Poettering [Wed, 30 Oct 2019 11:03:13 +0000 (12:03 +0100)]
sd-event: (void)ify some epoll_ctl() syscall invocations
Lennart Poettering [Wed, 30 Oct 2019 11:00:49 +0000 (12:00 +0100)]
sd-event: drop unnecessary local variable
Paul Davey [Tue, 26 Nov 2019 23:51:59 +0000 (12:51 +1300)]
udev: Ensure udev_event_spawn reads stdout
When running the program with udev_event_spawn it is possible to miss
output in stdout when the program exits causing the result to be empty
which can cause rules using the result to not function correctly.
This is due to the on_spawn_sigchld callback being processed while IO is
still pending and causing the event loop to exit.
To correct this the sigchld event source is made a lower priority than
the other event sources to ensure it is processed after IO. This
requires changing the IO event source to oneshot and re-enabling it when
valid data is read but not for EOF, this prevents the empty pipes
constantly generating IO events.
Lennart Poettering [Wed, 4 Dec 2019 09:30:58 +0000 (10:30 +0100)]
Merge pull request #14133 from keur/clear_ambient_inherited
Clear ambient inherited
Lennart Poettering [Wed, 4 Dec 2019 09:30:32 +0000 (10:30 +0100)]
Merge pull request #14177 from keszybz/use-initrd.target
Use initrd.target in the initramfs
Christian Göttsche [Wed, 27 Nov 2019 18:43:47 +0000 (19:43 +0100)]
core: reload SELinux label cache on daemon-reload
Reloading the SELinux label cache here enables a light-wight follow-up of a SELinux policy change, e.g. adding a label for a RuntimeDirectory.
Closes: #13363
Lennart Poettering [Wed, 4 Dec 2019 09:29:22 +0000 (10:29 +0100)]
Merge pull request #14189 from cgzones/selinux_tmpfiles
Selinux tmpfiles
Lennart Poettering [Tue, 26 Nov 2019 08:46:00 +0000 (09:46 +0100)]
pid1: add new kernel cmdline arg systemd.cpu_affinity=
Let's allow configuration of the CPU affinity via the kernel cmdline,
overriding CPUAffinity= in /etc/systemd/system.conf
Prompted by:
https://lists.freedesktop.org/archives/systemd-devel/2019-November/043754.html
Raphael [Fri, 29 Nov 2019 17:34:54 +0000 (18:34 +0100)]
Fix DPI for MX Master 2s bluetooth mouse
Mouse behaviour is unusably slow disregardless of mouse speed settings.
Jérémy Rosen [Fri, 29 Nov 2019 19:28:35 +0000 (20:28 +0100)]
Create parent directories when creating systemd-private subdirs
This is needed when systemd is compiled without systemd-tmpfiles
Zbigniew Jędrzejewski-Szmek [Wed, 4 Dec 2019 08:15:23 +0000 (09:15 +0100)]
Merge pull request #14211 from yuwata/support-nlmsgerr_attr_msg
Support NLMSGERR_ATTR_MSG
Yu Watanabe [Mon, 2 Dec 2019 15:29:44 +0000 (00:29 +0900)]
network: do not return error but return UINT64_MAX if speed meter is disabled
Fixes #14222.