Commit Graph

40187 Commits

Author SHA1 Message Date
Zach Smith 1bbbefe7a6 systemd-sleep: replace rtc wakealarm with CLOCK_BOOTTIME_ALARM s2h
refactor to use timerfd in place of rtc wakealarm

confirm CLOCK_BOOTTIME_ALARM support in can_s2h

Remove CLOCK_BOOTTIME_ALARM task from TODO

remove unnecessary check on clock_supported return
2019-05-28 17:02:36 +02:00
Lennart Poettering 46fcf95dbe seccomp: add new 5.1 syscall pidfd_send_signal() to filter set list 2019-05-28 17:01:05 +02:00
Lennart Poettering c22f885e4e test: exit cleanly on success 2019-05-28 16:14:02 +02:00
Zbigniew Jędrzejewski-Szmek 6bf901a9b5
Merge pull request #12437 from poettering/chmod-and-chown-rewrite
chmod_and_chown() rewrite
2019-05-28 15:12:20 +02:00
Zbigniew Jędrzejewski-Szmek 127c167cdb
Merge pull request #12390 from poettering/string-file-mkdir
fileio: add a WRITE_STRING_FILE_MKDIR_0755 flag to write_string_file() that creates parent directories if needed
2019-05-28 14:42:55 +02:00
Zbigniew Jędrzejewski-Szmek 365939fc9f
Merge pull request #12392 from poettering/firstboot-salt
generalize crypt_r() salt generation code
2019-05-28 14:36:54 +02:00
Lennart Poettering 1c99d2e0c5
Merge pull request #12597 from keszybz/analyze-timestamp
Analyze timestamps
2019-05-28 14:34:53 +02:00
Lennart Poettering 0fe11383b7
Merge pull request #12682 from keszybz/pull-in-user-targets
rules: enable hardware-related targets also for user instances
2019-05-28 14:28:59 +02:00
Zbigniew Jędrzejewski-Szmek 51b568f752 NEWS: add some entries
For #12680, #12571.
2019-05-28 14:28:09 +02:00
Lennart Poettering 7345109e61 capability-util: be more careful with types 2019-05-28 14:23:20 +02:00
Zbigniew Jędrzejewski-Szmek b7437f1c55
Merge pull request #12679 from yuwata/journal-issue-12400
journal: do not trigger assertion when journal_file_close() get NULL
2019-05-28 14:20:34 +02:00
Zbigniew Jędrzejewski-Szmek 026f3d3b91 rules: enable hardware-related targets also for user instances
> the odd thing is that these units are also defined for the systemd user
> instance. However, because these are bound to SYSTEMD_USER_WANTS rather than
> SYSTEMD_WANTS they are effectively useless unless some other software
> installs the corresponding udev rules first.

This adds the rules and starts those targets also for user instances.
Fixes #12330.
2019-05-28 14:18:11 +02:00
Yu Watanabe 627df1dc42 journal: use cleanup attribute at one more place 2019-05-28 18:07:18 +09:00
Yu Watanabe c377a6f3ad journal: do not trigger assertion when journal_file_close() get NULL
We generally expect destructors to not complain if a NULL argument is passed.

Closes #12400.
2019-05-28 18:07:18 +09:00
Yu Watanabe 3fb1069019 udev: fix error message 2019-05-28 10:35:21 +02:00
Zbigniew Jędrzejewski-Szmek 3f8841f286
Merge pull request #12653 from yuwata/test-network-improvements-2
network: fix configuring vxcan devices and several test-network follow-ups
2019-05-28 10:27:58 +02:00
Douglas Christman f003d62ec6 zsh-completion: fix completion for systemd-inhibit --what 2019-05-28 10:04:42 +02:00
Yu Watanabe a54510c775 udev: suppress warning when interface matches 99-default.link
This suppress the following warning:
```
systemd-udevd[437]: Config file /usr/lib/systemd/network/99-default.link
applies to device based on potentially unpredictable interface name 'wlan0'
```

Follow-up for 84ea567eb4.
2019-05-28 10:04:12 +02:00
Yu Watanabe 2789437be5 bash-completion: update options for bootctl 2019-05-28 09:49:57 +02:00
Yu Watanabe 3f0d8b2dbd coredumpctl: fix --debugger option
Closes #12660.
2019-05-28 08:22:07 +02:00
Frantisek Sumsal d0533a319b test: correctly fail when system is borked
In certain situations, the systemctl commands may fail (e.g. due to
missing shared libraries), but the 'script' continues and creates a
/testok file, marking the test incorrectly as passed. Let's fix this and
bail out immediately when a command exits with a non-zero exit code.
2019-05-27 22:31:55 +03:00
Evgeny Vereshchagin 75e4c768e2
Merge pull request #12663 from mrc0mmand/clang-asan-improvements
test: improve handling of ASan under clang
2019-05-27 19:59:53 +03:00
Frantisek Sumsal c9a95378ec docs: add documentation for sanitizers 2019-05-27 17:46:10 +02:00
Frantisek Sumsal 37ee8dc80f test: improve handling of ASan under clang
Running integration tests with ASan is somewhat tricky to begin with, as
we need to pre-load the ASan runtime DSO for certain services (like
dbus), otherwise they won't start or behave as expected. In case of gcc
this is pretty easy, as we need the runtime DSO during compilation, so
it's already present on the host system. For clang things get more
complicated, as ASan is compiled in statically by default, thus to
enable the necessary dynamic-ish behavior one needs to compile with
-shared-libasan and then correctly set LD_PRELOAD_PATH, as the runtime
libraries are not in a standard library path.
2019-05-27 17:46:07 +02:00
Oliver Harley 2fc1afca59 --bind-device does not take a bool
See e95be7def2/src/mount/mount-tool.c (L164) 
Also makes the man page consistent with the `--help` option
2019-05-26 16:00:17 +09:00
Jack cf36eb9cfe hwdb: Add support for Linx 12V64 (#12665)
This fixes the accelerometer for the Linx 12V64.
Note that even though the configuration for both models is the same, the 12V64 and 12X64 are different models.
2019-05-26 05:42:00 +09:00
pan93412 ffd552b872 tran: update Chinese (Traditional) translation to the latest. (#12662)
l10n: update Chinese (Traditional) translation
2019-05-25 15:40:43 +02:00
Lennart Poettering 87cf1f8f59 meson: let's make unified cgroupsv2 the default
Prompted by @evverx' comments:

https://github.com/systemd/systemd/pull/10161#pullrequestreview-158327715
2019-05-24 16:44:26 +02:00
Lennart Poettering f63383a31f test-fs-util: don't validate mode of symlinks
Some file systems refuse changing the mode, and the mode has zero effect
anyway, hence let's no test for this.
2019-05-24 15:07:55 +02:00
Lennart Poettering 1802d5f2cf terminal-util: reset access mode in vt_restore(), too
Only changing ownership back to root is not enough we also need to
change the access mode, otherwise the user might have set 666 first, and
thus allow everyone access before and after the chown().
2019-05-24 15:07:55 +02:00
Lennart Poettering 4b3b5bc71b tree-wide: port various places over to use chmod_and_chown()
Doing this properly is hard, hence let's unify the code.
2019-05-24 15:07:55 +02:00
Lennart Poettering f8a8579e84 tmpfile-util: simplify umask reset declaration 2019-05-24 15:07:55 +02:00
Lennart Poettering c1447be4d4 tests: add simple test case for chmod_and_chown() 2019-05-24 15:07:55 +02:00
Lennart Poettering 2dbb7e94af fs-util: rewrite chmod_and_chown()
Inspired by #12431 let's also rework chmod_and_chown() and make sure we
never add more rights to a file not owned by the right user.

Also, let's make chmod_and_chown() just a wrapper arond
fchmod_and_chown().

let's also change strategy: instead of chown()ing first and stating
after on failure and supressing errors, let's avoid the chown in the
firts place, in the interest on keeping things minimal.
2019-05-24 15:07:55 +02:00
Lennart Poettering 2570578d90 machine-image: openat() doesn't operate on the cwd if the first argument is specified
A fix-up for bcb846f30f.
2019-05-24 14:39:19 +02:00
Zbigniew Jędrzejewski-Szmek de26d715e3
Merge pull request #12430 from poettering/seccomp-kill-process
use SCMP_ACT_KILL_PROCESS for SystemCallFilters=
2019-05-24 12:17:53 +02:00
Lennart Poettering a429223d17 test-execute: turn off coredump generation in test services
These services are likely to coredump, and we expect that but aren't
interested in the coredump. Hence let's turn off processing by setting
RLIMIT_CORE to 0/0.
2019-05-24 10:48:28 +02:00
Lennart Poettering c3ab2c389e test-execute: let's ignore the difference between CLD_KILLED and CLD_DUMPED
Depending on system configuration and whether SCMP_ACT_KILL_PROCESS or
SCMP_ACT_KILL_THREAD is available/used processes might coredump on
specific coredumps or are just plain killed. For our test case the
difference doesn't really matter, hence let's hide it away.
2019-05-24 10:48:28 +02:00
Lennart Poettering 18f8c5d466 test-execute: check exit code before exit status
The meaning of the status changes depending on the code, hence let's
always compare the code first, status second.
2019-05-24 10:48:28 +02:00
Lennart Poettering 727a1a0607 service: tweak capitalization of unit description 2019-05-24 10:48:28 +02:00
Lennart Poettering 4cd8263166 NEWS: document the new SystemCallFilter= behaviour 2019-05-24 10:48:28 +02:00
Lennart Poettering f9a3d8e2f3 nspawn: expose the new seccomp actions in the OCI logic 2019-05-24 10:48:28 +02:00
Lennart Poettering 7bbc229cf7 test: use the new action in our tests
This way, we know that it works as intended.
2019-05-24 10:48:28 +02:00
Lennart Poettering ccc16c7842 core: prefer SCMP_ACT_KILL_PROCESS for SystemCallFilter= behaviour
If we have it, use it. It makes a ton more sense.

Fixes: #11967
2019-05-24 10:48:28 +02:00
Lennart Poettering 915fb32438 seccomp: add scmp_act_kill_process() helper that returns SCMP_ACT_KILL_PROCESS if supported 2019-05-24 10:48:28 +02:00
Lennart Poettering d631a760e0
Merge pull request #12601 from keszybz/two-log-color-adjustments
Two log color adjustments
2019-05-24 10:43:07 +02:00
Lennart Poettering 05332e243c
Merge pull request #12590 from keszybz/unicode-cmdlines
Use unicode for cmdline printing
2019-05-24 10:41:30 +02:00
Yu Watanabe f63b14d35e test-network: add basic tests for vxcan device 2019-05-24 10:56:54 +09:00
Yu Watanabe cab042b843 network: make VXCAN devices go through LINK_STATE_CONFIGURING 2019-05-24 10:55:33 +09:00
Yu Watanabe 0aefa2274d test-network: add more tests for LinkLocalAddressing=yes on various netdevs 2019-05-24 10:54:53 +09:00