]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
6 years agoMerge pull request #8915 from yuwata/fix-8904
Michael Biebl [Tue, 8 May 2018 13:03:27 +0000 (15:03 +0200)] 
Merge pull request #8915 from yuwata/fix-8904

 login: do not wall message on cancelling shutdown when Manager.enable_wall_messages is false

6 years agolink: Add support to configure channels of the specified network device (#8882)
Susant Sahani [Tue, 8 May 2018 11:03:41 +0000 (16:33 +0530)] 
link: Add support to configure channels of the specified network device (#8882)

closes #8856

6 years agoMerge pull request #8898 from poettering/nspawn-mount-block
Zbigniew Jędrzejewski-Szmek [Tue, 8 May 2018 10:54:58 +0000 (12:54 +0200)] 
Merge pull request #8898 from poettering/nspawn-mount-block

some nspawn cgroup and mount lock-down fixes

6 years agoMerge pull request #8926 from keszybz/man-journal-remote
Yu Watanabe [Tue, 8 May 2018 08:56:51 +0000 (17:56 +0900)] 
Merge pull request #8926 from keszybz/man-journal-remote

Small additions to sd-journal-{remote,upload}.service man pages

6 years agoman: fix title of systemd-networkd-wait-online(8) (#8925)
Yu Watanabe [Tue, 8 May 2018 08:53:52 +0000 (17:53 +0900)] 
man: fix title of systemd-networkd-wait-online(8) (#8925)

6 years agoman: add a bit more text about systemd-journal-upload.service 8926/head
Zbigniew Jędrzejewski-Szmek [Tue, 8 May 2018 08:39:18 +0000 (10:39 +0200)] 
man: add a bit more text about systemd-journal-upload.service

6 years agoman: add a bit more text about systemd-journal-remote.service
Zbigniew Jędrzejewski-Szmek [Tue, 8 May 2018 08:37:09 +0000 (10:37 +0200)] 
man: add a bit more text about systemd-journal-remote.service

6 years agoMerge pull request #8922 from yuwata/fix-8920-8921
Zbigniew Jędrzejewski-Szmek [Tue, 8 May 2018 08:31:50 +0000 (10:31 +0200)] 
Merge pull request #8922 from yuwata/fix-8920-8921

man: update references to systemd-journal-{remote,upload}

6 years agoman: fix typo 8922/head
Yu Watanabe [Tue, 8 May 2018 03:41:59 +0000 (12:41 +0900)] 
man: fix typo

6 years agoman: mention that --url option of journal-upload can specify the port number
Yu Watanabe [Tue, 8 May 2018 02:58:16 +0000 (11:58 +0900)] 
man: mention that --url option of journal-upload can specify the port number

6 years agoman: mention the default port number of journal-remote
Yu Watanabe [Tue, 8 May 2018 02:57:28 +0000 (11:57 +0900)] 
man: mention the default port number of journal-remote

6 years agoman: update references to systemd-journal-{remote,upload}
Yu Watanabe [Tue, 8 May 2018 01:14:02 +0000 (10:14 +0900)] 
man: update references to systemd-journal-{remote,upload}

Fixes #8920 and #8921.

6 years agodoc: clarify at which point user/group name resolution needs to work (#8884)
Lennart Poettering [Mon, 7 May 2018 12:49:16 +0000 (14:49 +0200)] 
doc: clarify at which point user/group name resolution needs to work (#8884)

Prompted by the discussions on:

https://bugs.freedesktop.org/show_bug.cgi?id=106339

6 years agonetworkd: add support to send DHCP user class option (#7499)
Susant Sahani [Mon, 7 May 2018 12:21:02 +0000 (17:51 +0530)] 
networkd: add support to send DHCP user class option (#7499)

This patch add support to enables to send User Class option code 77
RFC 3004.

This option MAY carry multiple User Classes.

The format of this option is as follows:

         Code   Len   Value
        +-----+-----+---------------------  . . .  --+
        | 77  |  N  | User Class Data ('Len' octets) |
        +-----+-----+---------------------  . . .  --+

   where Value consists of one or more instances of User Class Data.
   Each instance of User Class Data is formatted as follows:

         UC_Len_i     User_Class_Data_i
        +--------+------------------------  . . .  --+
        |  L_i   | Opaque-Data ('UC_Len_i' octets)   |
        +--------+------------------------  . . .  --+

UserClass=
A DHCPv4 client can use UserClass option to identify the type or category of user or applications
it represents. The information contained in this option is an string that represents the user class
of which the client is a member. Each class sets an identifying string of information to be used by the DHCP service to classify clients. Takes a whitespace-separated list.

UserClass= hello world how are you

Closes: RFC: #5134
6 years agomeson: generate m4 preprocessor from config.h (#8914)
Yu Watanabe [Mon, 7 May 2018 09:17:35 +0000 (18:17 +0900)] 
meson: generate m4 preprocessor from config.h (#8914)

6 years agologin: do not wall message on cancelling shutdown when Manager.enable_wall_messages... 8915/head
Yu Watanabe [Mon, 7 May 2018 01:16:04 +0000 (10:16 +0900)] 
login: do not wall message on cancelling shutdown when Manager.enable_wall_messages is false

Fixes #8904.

6 years agologin: change variable type of enable_wall_messages as it matches Manager.enable_wall...
Yu Watanabe [Mon, 7 May 2018 01:13:54 +0000 (10:13 +0900)] 
login: change variable type of enable_wall_messages as it matches Manager.enable_wall_messages

6 years agomeson: also try to search gnu-efi based on EFI_MACHINE_TYPE_NAME (#8900)
Yu Watanabe [Fri, 4 May 2018 15:49:57 +0000 (00:49 +0900)] 
meson: also try to search gnu-efi based on EFI_MACHINE_TYPE_NAME (#8900)

On Fedora rawhide, since gnu-efi-3.0.8-3.fc29, many file paths are
changed to use `EFI_MACHINE_TYPE_NAME` instead of `gnu_efi_arch`.

Fixes #8896.

6 years agoupdate TODO 8898/head
Lennart Poettering [Mon, 30 Apr 2018 19:20:31 +0000 (21:20 +0200)] 
update TODO

6 years agonamespace: extend list of masked files by ProtectKernelTunables=
Lennart Poettering [Thu, 3 May 2018 15:44:20 +0000 (17:44 +0200)] 
namespace: extend list of masked files by ProtectKernelTunables=

This adds a number of entries nspawn already applies to regular service
namespacing too. Most importantly let's mask /proc/kcore and
/proc/kallsyms too.

6 years agonspawn: move nspawn cgroup hierarchy one level down unconditionally
Lennart Poettering [Wed, 2 May 2018 12:24:54 +0000 (14:24 +0200)] 
nspawn: move nspawn cgroup hierarchy one level down unconditionally

We need to do this in all cases, including on cgroupsv1 in order to
ensure the host systemd and any systemd in the payload won't fight for
the cgroup attributes of the top-level cgroup of the payload.

This is because systemd for Delegate=yes units will only delegate the
right to create children as well as their attributes. However, nspawn
expects that the cgroup delegated covers both the right to create
children and the attributes of the cgroup itself. Hence, to clear this
up, let's unconditionally insert a intermediary cgroup, on cgroupsv1 as
well as cgroupsv2, unconditionally.

This is also nice as it reduces the differences in the various setups
and exposes very close behaviour everywhere.

6 years agonspawn: let's make use of SPECIAL_MACHINE_SLICE macro, after all we already set it
Lennart Poettering [Wed, 2 May 2018 12:24:39 +0000 (14:24 +0200)] 
nspawn: let's make use of SPECIAL_MACHINE_SLICE macro, after all we already set it

6 years agonspawn: don't make /proc/kmsg node too special
Lennart Poettering [Mon, 30 Apr 2018 19:22:41 +0000 (21:22 +0200)] 
nspawn: don't make /proc/kmsg node too special

Similar to the previous commit, let's just use our regular calls for
managing temporary nodes take care of this.

6 years agonspawn: mount boot ID from temporary file in /tmp
Lennart Poettering [Mon, 30 Apr 2018 19:20:50 +0000 (21:20 +0200)] 
nspawn: mount boot ID from temporary file in /tmp

Let's not make /run too special and let's make sure the source file is
not guessable: let's use our regular temporary file helper calls to
create the source node.

6 years agonspawn: lock down a few things in /proc by default
Lennart Poettering [Mon, 30 Apr 2018 10:22:41 +0000 (12:22 +0200)] 
nspawn: lock down a few things in /proc by default

This tightens security on /proc: a couple of files exposed there are now
made inaccessible. These files might potentially leak kernel internals
or expose non-virtualized concepts, hence lock them down by default.
Moreover, a couple of dirs in /proc that expose stuff also exposed in
/sys are now marked read-only, similar to how we handle /sys.

The list is taken from what docker/runc based container managers
generally apply, but slightly extended.

6 years agoMerge pull request #8868 from yuwata/resolve-show-current-server
Lennart Poettering [Thu, 3 May 2018 15:24:34 +0000 (17:24 +0200)] 
Merge pull request #8868 from yuwata/resolve-show-current-server

resolvectl: show current DNS server

6 years agoMerge pull request #8644 from yuwata/rfe-1589
Lennart Poettering [Thu, 3 May 2018 15:23:40 +0000 (17:23 +0200)] 
Merge pull request #8644 from yuwata/rfe-1589

timesync: expose NTP response on DBus

6 years agoethtool: get_glinksettings Fix copy (#8889)
Susant Sahani [Thu, 3 May 2018 15:20:56 +0000 (20:50 +0530)] 
ethtool: get_glinksettings Fix copy (#8889)

It should be other way around.

6 years agonspawn: use free_and_replace() at more places
Lennart Poettering [Fri, 27 Apr 2018 20:03:14 +0000 (22:03 +0200)] 
nspawn: use free_and_replace() at more places

6 years agonspawn: size_t more stuff
Lennart Poettering [Fri, 27 Apr 2018 20:01:54 +0000 (22:01 +0200)] 
nspawn: size_t more stuff

A follow-up for #8840

6 years agodoc: document nore carefully that tmpfs within the cgroupfs setup shouldn't confuse...
Lennart Poettering [Wed, 2 May 2018 12:23:45 +0000 (14:23 +0200)] 
doc: document nore carefully that tmpfs within the cgroupfs setup shouldn't confuse statfs() checks

6 years agoMerge pull request #8859 from poettering/virt-xen-lying
Yu Watanabe [Thu, 3 May 2018 14:23:32 +0000 (23:23 +0900)] 
Merge pull request #8859 from poettering/virt-xen-lying

Prefer DMI over CPUID when detecting Xen

6 years agolocale-util: add comment with link to unicode chars supported by eurlatgr (#8894)
Lennart Poettering [Thu, 3 May 2018 14:15:04 +0000 (16:15 +0200)] 
locale-util: add comment with link to unicode chars supported by eurlatgr (#8894)

See: #6443

6 years agomount-setup: add a comment that the character/block device nodes are "optional" ...
Lennart Poettering [Thu, 3 May 2018 14:10:35 +0000 (16:10 +0200)] 
mount-setup: add a comment that the character/block device nodes are "optional" (#8893)

if we lack privs to create device nodes that's fine, and creating
/run/systemd/inaccessible/chr or /run/systemd/inaccessible/blk won't
work then. Document this in longer comments.

Fixes: #4484
6 years agoMerge pull request #8887 from poettering/file-hier-efi
Yu Watanabe [Thu, 3 May 2018 14:07:07 +0000 (23:07 +0900)] 
Merge pull request #8887 from poettering/file-hier-efi

three improvements to the file-hierarchy(7) man page

6 years agoman: docbook doesn't like line breaks within table cells (#8885)
Lennart Poettering [Thu, 3 May 2018 14:02:43 +0000 (16:02 +0200)] 
man: docbook doesn't like line breaks within table cells (#8885)

It will pass them on as they are to the formatted man pages, which is
pretty uncool. Let's hence avoid line breaks with table cells.

6 years agotest: don't send image building output to /dev/null (#8886)
Lennart Poettering [Thu, 3 May 2018 13:47:42 +0000 (15:47 +0200)] 
test: don't send image building output to /dev/null (#8886)

Yes, the output is sometimes annyoing, but /dev/null is not the right
place...

I figure this redirection was left in from some debugging session, let's
fix it, and make the setup_basic_environment invocation like in all
other test scripts.

6 years agoMerge pull request #8865 from yuwata/fix-signal
Evgeny Vereshchagin [Thu, 3 May 2018 13:35:38 +0000 (16:35 +0300)] 
Merge pull request #8865 from yuwata/fix-signal

util: fix integer overflow

6 years agoupdate TODO
Lennart Poettering [Thu, 3 May 2018 13:13:42 +0000 (15:13 +0200)] 
update TODO

6 years agoMerge pull request #8892 from poettering/binfmt-misc-rst
Lennart Poettering [Thu, 3 May 2018 11:07:56 +0000 (13:07 +0200)] 
Merge pull request #8892 from poettering/binfmt-misc-rst

binfmt_misc url fixes

6 years agoman: add explanations of show-timesync and timesync-status commands 8644/head
Yu Watanabe [Mon, 30 Apr 2018 13:42:40 +0000 (22:42 +0900)] 
man: add explanations of show-timesync and timesync-status commands

6 years agotimedatectl: add timesync-status and show-timesync commands
Yu Watanabe [Thu, 3 May 2018 09:07:43 +0000 (18:07 +0900)] 
timedatectl: add timesync-status and show-timesync commands

Closes #1589.

6 years agotimesync: save and expose NTP responce on bus
Yu Watanabe [Mon, 30 Apr 2018 13:37:02 +0000 (22:37 +0900)] 
timesync: save and expose NTP responce on bus

6 years agotimesync: try to reload DBus configuration when RequestName() fails
Yu Watanabe [Mon, 30 Apr 2018 14:51:04 +0000 (23:51 +0900)] 
timesync: try to reload DBus configuration when RequestName() fails

If dbus.service starts earlier than the dynamic user systemd-timesync
is realized, then the dbus policy file for timesyncd does not loaded
and timesyncd fails to request name.
To support such case, try to reload dbus configuration when requesting
name fails.

6 years agotimesync: expose manager properties on bus
Yu Watanabe [Mon, 30 Apr 2018 14:02:09 +0000 (23:02 +0900)] 
timesync: expose manager properties on bus

6 years agotest: list more up-to-date urls in test-web-util 8892/head
Lennart Poettering [Thu, 3 May 2018 08:55:16 +0000 (10:55 +0200)] 
test: list more up-to-date urls in test-web-util

This is based on @jsynacek's patch from #8837, but adds the new URL in
two flavours instead of replacing the old, also making @keszybz happy.

Replaces: #8837

6 years agoresolvectl: simplify map_{link,global}_domains() 8868/head
Yu Watanabe [Thu, 3 May 2018 08:10:02 +0000 (17:10 +0900)] 
resolvectl: simplify map_{link,global}_domains()

6 years agoresolve: update comments to mention resolvectl
Yu Watanabe [Tue, 1 May 2018 07:39:36 +0000 (16:39 +0900)] 
resolve: update comments to mention resolvectl

6 years agoresolvectl: show current DNS server
Yu Watanabe [Tue, 1 May 2018 13:17:22 +0000 (22:17 +0900)] 
resolvectl: show current DNS server

`systemd-resolved` rotate the DNS servers. So, it may by useful to
show the current DNS server for diagnosing `systemd-resolved`.

6 years agoresolvectl: simplify map_{link,global}_dns_servers()
Yu Watanabe [Thu, 3 May 2018 08:06:06 +0000 (17:06 +0900)] 
resolvectl: simplify map_{link,global}_dns_servers()

6 years agoresolve: expose CurrentDNSServer= property on Bus
Yu Watanabe [Tue, 1 May 2018 06:58:42 +0000 (15:58 +0900)] 
resolve: expose CurrentDNSServer= property on Bus

6 years agooss-fuzz: add the reproducer case by oss-fuzz #8064 8865/head
Yu Watanabe [Thu, 3 May 2018 07:57:29 +0000 (16:57 +0900)] 
oss-fuzz: add the reproducer case by oss-fuzz #8064

6 years agotest: add tests for signal_from_string()
Yu Watanabe [Thu, 3 May 2018 07:47:12 +0000 (16:47 +0900)] 
test: add tests for signal_from_string()

6 years agoutil: rename signal_from_string_try_harder() to signal_from_string()
Yu Watanabe [Thu, 3 May 2018 07:38:57 +0000 (16:38 +0900)] 
util: rename signal_from_string_try_harder() to signal_from_string()

Also this makes the new `signal_from_string()` function reject
e.g, `SIG3` or `SIG+5`.

6 years agoutil: make signal_from_string() accept RTMIN, RTMAX, and RTMAX-n
Yu Watanabe [Thu, 3 May 2018 07:40:02 +0000 (16:40 +0900)] 
util: make signal_from_string() accept RTMIN, RTMAX, and RTMAX-n

Before this, `signal_from_string()` accepts simple signal name
or RTMIN+n. This makes the function also accept RTMIN, RTMAX,
and RTMAX-n.
Note that RTMIN+0 is equivalent to RTMIN, and RTMAX-0 is to RTMAX.

This also fixes the integer overflow reported by oss-fuzz #8064.
https://oss-fuzz.com/v2/testcase-detail/5648573352902656

6 years agoman: refer to the html version of binfmt-misc.rst
Lennart Poettering [Wed, 2 May 2018 20:03:02 +0000 (22:03 +0200)] 
man: refer to the html version of binfmt-misc.rst

Yes, the kernel's file is called "binfmt-misc.rst", but let's link the
HTML version, after all HTML is much more appropriate for hyperlinking.

6 years agonetworkd: use ipv6_accept_ra_use_dns rather than dhcp_use_dns (#8836)
Susant Sahani [Wed, 2 May 2018 18:16:10 +0000 (23:46 +0530)] 
networkd: use ipv6_accept_ra_use_dns rather than dhcp_use_dns (#8836)

While Saving the DNS server use [IPv6AcceptRA] UseDNS= that is
ipv6_accept_ra_use_dns.

Closes #8420

6 years agotest-functions: don't nest KVM (#8883)
Lennart Poettering [Wed, 2 May 2018 18:06:13 +0000 (20:06 +0200)] 
test-functions: don't nest KVM (#8883)

Nested KVM is very flaky as we learnt from our CI. Hence, let's avoid
KVM whenever we detect we are already running inside of KVM.

Maybe one day nested KVM is fixed, at which point we can turn this on
again, but for now let's simply avoid nested KVM, since reliable CI is
more important than quick CI, I guess.

And yes, avoiding KVM for our qemu runs does make things substantially
slower, but I think it's not a complete loss.

Inspired by @evverx' findings in:

https://github.com/systemd/systemd/pull/8701#issuecomment-380213302

6 years agoman: suffix all dir paths in file-hierarchy(7) with "/" 8887/head
Lennart Poettering [Wed, 2 May 2018 15:00:30 +0000 (17:00 +0200)] 
man: suffix all dir paths in file-hierarchy(7) with "/"

Our CODING_STYLE document suggests to suffix all paths referring to dirs
rather than regular files with a "/" in our docs and log messages.
Update file-hierarchy(7) to do just that.

No other changes.

6 years agoman: document /efi in file-hiearchy(7)
Lennart Poettering [Wed, 2 May 2018 14:55:37 +0000 (16:55 +0200)] 
man: document /efi in file-hiearchy(7)

We have been supporting the directory since a while in the gpt
generator, let's document it in file-hierarchy(7) too

6 years agoman: document the XDG specs as further sources of specifications for file-hierarchy(7)
Lennart Poettering [Wed, 2 May 2018 14:54:32 +0000 (16:54 +0200)] 
man: document the XDG specs as further sources of specifications for file-hierarchy(7)

We document this further down in the text, but let's also list this
early on, where we mention the FHS as major influence too, so that it is
clear we incorporate all that thinking.

6 years agoudev: do not mark ari_enabled true when its sysattr value is 0 (#8870)
Yu Watanabe [Wed, 2 May 2018 14:21:30 +0000 (23:21 +0900)] 
udev: do not mark ari_enabled true when its sysattr value is 0 (#8870)

Fixes #8869.

6 years agoMerge pull request #8866 from yuwata/fix-8842
Lennart Poettering [Wed, 2 May 2018 14:15:26 +0000 (16:15 +0200)] 
Merge pull request #8866 from yuwata/fix-8842

 core: disable namespace sandboxing for '+' prefixed lines

6 years agoMerge pull request #8867 from yuwata/update-readme
Lennart Poettering [Wed, 2 May 2018 12:32:00 +0000 (14:32 +0200)] 
Merge pull request #8867 from yuwata/update-readme

doc: Update README

6 years agoset: drop unused set_make() function (#8879)
Yu Watanabe [Wed, 2 May 2018 08:54:52 +0000 (17:54 +0900)] 
set: drop unused set_make() function (#8879)

The function causes compiler error when built with '-Ddebug=hashmap',
and is not used anymore. Let's drop it.

6 years agoMerge pull request #8815 from poettering/get-unit-by-cgroup
Lennart Poettering [Wed, 2 May 2018 08:51:48 +0000 (10:51 +0200)] 
Merge pull request #8815 from poettering/get-unit-by-cgroup

add new GetUnitByControlGroup API

6 years agomeson: drop 'name' argument in cc.has_argument() (#8878)
Yu Watanabe [Wed, 2 May 2018 08:05:51 +0000 (17:05 +0900)] 
meson: drop 'name' argument in cc.has_argument() (#8878)

6 years agoadd __nr_statx defines for extra architectures (#8872)
Adam Duskett [Wed, 2 May 2018 08:04:50 +0000 (04:04 -0400)] 
add __nr_statx defines for extra architectures (#8872)

This includes:
 - arm
 - arm64
 - alpha
 - powerpc64
 - sparc

Taken from kernel 4.16.6

6 years agonspawn: fix warning by -Wnonnull (#8877)
Yu Watanabe [Wed, 2 May 2018 08:03:31 +0000 (17:03 +0900)] 
nspawn: fix warning by -Wnonnull (#8877)

6 years agosystemd-path: fix memory leak reported by ASAN (#8874)
Filipe Brandenburger [Wed, 2 May 2018 06:47:04 +0000 (23:47 -0700)] 
systemd-path: fix memory leak reported by ASAN (#8874)

The leak can be reproduced by running systemd-path --suffix .tmp under valgrind or asan:

    $ ./build/systemd-path --suffix .tmp search-binaries
    /usr/local/bin/.tmp:/usr/bin/.tmp:/usr/local/sbin/.tmp:/usr/sbin/.tmp:/home/vagrant/.local/bin/.tmp:/home/vagrant/bin/.tmp

    =================================================================
    ==19177==ERROR: LeakSanitizer: detected memory leaks

    Direct leak of 56 byte(s) in 1 object(s) allocated from:
        *0 0x7fd6adf72850 in malloc (/lib64/libasan.so.4+0xde850)
        *1 0x7fd6ad2b93d2 in malloc_multiply ../src/basic/alloc-util.h:69
        *2 0x7fd6ad2bafd2 in strv_split ../src/basic/strv.c:269
        *3 0x7fd6ad42ba67 in search_from_environment ../src/libsystemd/sd-path/sd-path.c:409
        *4 0x7fd6ad42bffe in get_search ../src/libsystemd/sd-path/sd-path.c:482
        *5 0x7fd6ad42c55b in sd_path_search ../src/libsystemd/sd-path/sd-path.c:607
        *6 0x7fd6ad42b3a2 in sd_path_home ../src/libsystemd/sd-path/sd-path.c:348
        *7 0x55f59c65ebea in print_home ../src/path/path.c:97
        *8 0x55f59c65f157 in main ../src/path/path.c:177
        *9 0x7fd6abaea009 in __libc_start_main (/lib64/libc.so.6+0x21009)

    Indirect leak of 68 byte(s) in 5 object(s) allocated from:
        *0 0x7fd6adf72850 in malloc (/lib64/libasan.so.4+0xde850)
        *1 0x7fd6abb5f689 in strndup (/lib64/libc.so.6+0x96689)

    Indirect leak of 25 byte(s) in 1 object(s) allocated from:
        *0 0x7fd6adf72850 in malloc (/lib64/libasan.so.4+0xde850)
        *1 0x7fd6abb5f689 in strndup (/lib64/libc.so.6+0x96689)
        *2 0x6c2e2f746e617266  (<unknown module>)

    SUMMARY: AddressSanitizer: 149 byte(s) leaked in 7 allocation(s).

6 years agodoc: update hosts nsswitch setting to which consistent to man pages 8867/head
Yu Watanabe [Tue, 1 May 2018 06:18:10 +0000 (15:18 +0900)] 
doc: update hosts nsswitch setting to which consistent to man pages

6 years agodoc: drop static user systemd-timesync from README
Yu Watanabe [Tue, 1 May 2018 06:16:39 +0000 (15:16 +0900)] 
doc: drop static user systemd-timesync from README

6 years agodoc: drop static user systemd-journal-gateway from README
Yu Watanabe [Tue, 1 May 2018 06:15:44 +0000 (15:15 +0900)] 
doc: drop static user systemd-journal-gateway from README

and add systemd-journal-remote instead.

6 years agotest: fix descriptions 8866/head
Yu Watanabe [Tue, 1 May 2018 04:42:48 +0000 (13:42 +0900)] 
test: fix descriptions

6 years agotest: add tests for PrivateDevices= with '+' prefix
Yu Watanabe [Tue, 1 May 2018 04:42:32 +0000 (13:42 +0900)] 
test: add tests for PrivateDevices= with '+' prefix

6 years agocore: disable namespace sandboxing for '+' prefixed lines
Yu Watanabe [Tue, 1 May 2018 04:33:34 +0000 (13:33 +0900)] 
core: disable namespace sandboxing for '+' prefixed lines

Fixes #8842.

6 years agosystemctl: make sure legacy "reboot", "suspend" and friends are always asynchronous...
Guillem Jover [Mon, 30 Apr 2018 16:21:27 +0000 (18:21 +0200)] 
systemctl: make sure legacy "reboot", "suspend" and friends are always asynchronous (#8848)

Currently, "reboot" behaves differently in setups with and without logind.
If logind is used (which is probably the more common case) the operation
is asynchronous, we should behave in the same way as "systemctl <verb>".
Let's clean this up, and always expose the same behaviour, regardless if
logind is used or not: let's always make it asynchronous.

See: #6479
Fixes: commit 130246d2e8d7a0c91dbaa1110fa7a6d6e6f86a50
6 years agovirt: simplifications 8859/head
Lennart Poettering [Mon, 30 Apr 2018 10:24:57 +0000 (12:24 +0200)] 
virt: simplifications

Let's simplify the code a bit. Let's reduce the number of redundant if
checks a bit, (i.e. if we want to check for equality with
VIRTUALIZATION_VM_OTHER there's no need to check for non-equality with
VIRTUALIZATION_NONE first). As a very welcome side-effect this means we
lose some lines of code and our level of indentation is reduced.

No changes in behaviour.

6 years agovirt: if we detect Xen by DMI, trust that over CPUID
Lennart Poettering [Mon, 30 Apr 2018 10:23:03 +0000 (12:23 +0200)] 
virt: if we detect Xen by DMI, trust that over CPUID

Apparently Xen sometimes lies about its identity when queried via CPUID.
Let's hence prefer DMI tests for CPUID

Fixes: #8844
6 years agoMerge pull request #8847 from poettering/transient-once
Zbigniew Jędrzejewski-Szmek [Mon, 30 Apr 2018 07:50:03 +0000 (09:50 +0200)] 
Merge pull request #8847 from poettering/transient-once

enforce that scope units are started at most once

6 years agohwdb: Add accelerometer orientation quirk for the Kazam Vision tablet (#8845)
Hans de Goede [Sat, 28 Apr 2018 08:43:06 +0000 (10:43 +0200)] 
hwdb: Add accelerometer orientation quirk for the Kazam Vision tablet (#8845)

Add accelerometer orientation quirk for the 8" Kazam Vision "gaming"
tablet.

6 years agoupdate TODO 8847/head
Lennart Poettering [Fri, 27 Apr 2018 19:31:43 +0000 (21:31 +0200)] 
update TODO

6 years agocore: enforce that scope units can be started only once
Lennart Poettering [Fri, 27 Apr 2018 18:35:10 +0000 (20:35 +0200)] 
core: enforce that scope units can be started only once

Scope units are populated from PIDs specified by the bus client. We do
that when a scope is started. We really shouldn't allow scopes to be
started multiple times, as the PIDs then might be heavily out of date.
Moreover, clients should have the guarantee that any scope they allocate
has a clear runtime cycle which is not repetitive.

6 years agoMerge pull request #8808 from poettering/logind-signal
Lennart Poettering [Fri, 27 Apr 2018 18:22:35 +0000 (20:22 +0200)] 
Merge pull request #8808 from poettering/logind-signal

logind: process SIGTERM + SIGINT properly

6 years agoMerge pull request #8799 from poettering/exit-status-string
Zbigniew Jędrzejewski-Szmek [Fri, 27 Apr 2018 16:26:19 +0000 (18:26 +0200)] 
Merge pull request #8799 from poettering/exit-status-string

add friendly string support for BSD EX_ exit statusses

6 years agoupdate TODO 8808/head
Lennart Poettering [Tue, 24 Apr 2018 16:23:29 +0000 (18:23 +0200)] 
update TODO

6 years agomachined: minor code cleanups, such as voidifying calls
Lennart Poettering [Tue, 24 Apr 2018 16:16:44 +0000 (18:16 +0200)] 
machined: minor code cleanups, such as voidifying calls

6 years agologind: (void)ify all things we knowingly ignore
Lennart Poettering [Tue, 24 Apr 2018 16:16:14 +0000 (18:16 +0200)] 
logind: (void)ify all things we knowingly ignore

6 years agologind: terminate cleanly on SIGTERM/SIGINT
Lennart Poettering [Tue, 24 Apr 2018 16:14:25 +0000 (18:14 +0200)] 
logind: terminate cleanly on SIGTERM/SIGINT

Let's properly terminate on SIGTERM or SIGINT. Previously we'd just rely
on the implicit process clean-up logic on UNIX. By shutting down
properly on SIGTERM/SIGINT we make it easier to track down memory leaks
by employing valgrind.

6 years agologind: modernize Manager object allocation and freeing
Lennart Poettering [Tue, 24 Apr 2018 16:13:12 +0000 (18:13 +0200)] 
logind: modernize Manager object allocation and freeing

Let's propagate errors correctly, and stick to the usual naming and
behaviour of these functions. Or in other words, make this closer to the
matching code in machined.

6 years agobasic/log: always ignore errno from the enviornment (#8841)
Zbigniew Jędrzejewski-Szmek [Fri, 27 Apr 2018 16:00:58 +0000 (18:00 +0200)] 
basic/log: always ignore errno from the enviornment (#8841)

This extends the change done in b29f6480ec to other logging functions.

This actually fixes some bugs in callers of log_struct(), for example
config_parse_alias() called 'return log_syntax(..., 0, ...)' which could result
in a bogus non-zero return value.

Calls to log_object() and log_format_iovec() — which is only used by
server_driver_message() — appear correct.

6 years agojournal-send: drop redundant parenthesis 8799/head
Lennart Poettering [Fri, 27 Apr 2018 15:29:38 +0000 (17:29 +0200)] 
journal-send: drop redundant parenthesis

As suggested in @keszybz' comments on #8840

6 years agoman: don't claim we'd set XDG_SEAT and XDG_VTNR as part of service management
Lennart Poettering [Tue, 24 Apr 2018 09:51:21 +0000 (11:51 +0200)] 
man: don't claim we'd set XDG_SEAT and XDG_VTNR as part of service management

Previously, reading through systemd.exec(5) one might get the idea that
XDG_SEAT and XDG_VTNR are part of the service management logic, but they
are not, they are only set if pam_systemd is part of a PAM stack an
pam_systemd is used.

Hence, let's drop these env vars from the list of env vars, and instead
add a paragraph after the list mentioning that pam_systemd might add
more systemd-specific env vars if included in the PAM stack for a
service that uses PAMName=.

6 years agoexit-status: list BSD exit codes too
Lennart Poettering [Mon, 23 Apr 2018 17:26:25 +0000 (19:26 +0200)] 
exit-status: list BSD exit codes too

Let's optionally translate BSD exit codes to error strings too.

My first approach on adding this was to turn ExitStatusLevel into a
bitmask rather than a linear level, with one bit for the various feature
bits. However, the exit code ranges are generally not defined
independently from each other, i.e. our own ones are defined with the
LSB ones in mind, and most sets are defined with the ISO C ones.

Hence, instead I changed the existing hierarchy of MINIMAL, SYSTEMD, LSB
with an alias of FULL == LSB, only slightly by seperating FULL and LSB
into two separate levels, so that there's now:

1. MINIMAL (only EXIT_SUCCESS/EXIT_FAILURE)
2. SYSTEMD (incorporating our own exit codes)
3. LSB (like SYSTEMD but adding in LSB service exit codes)
4. FULL (like FULL but adding BSD exit codes)

Note that across the codebase only FULL, SYSTEMD, and MINIMAL are used,
depending on context, how much we know about the process and whether we
are logging for debugging purposes or not. This means the LSB level
wouldn't really have to be separate, but it appeared careless to me to
fold it into FULL along with the BSD exit codes.

Note that this commit doesn't change much for regular codepaths: the
FULL exit status level is only used during debug logging, as a helper to
the user reading the debug logs.

6 years agoman: document BSD exit codes in systemd.exec(5) too
Lennart Poettering [Mon, 23 Apr 2018 17:25:23 +0000 (19:25 +0200)] 
man: document BSD exit codes in systemd.exec(5) too

Our own tools use them now, and we probably should encourage that, hence
let's document them along with the other exit codes we use.

6 years agodoc: clarify the intended audience of CGROUP_DELEGATION.md
Lennart Poettering [Mon, 23 Apr 2018 17:21:27 +0000 (19:21 +0200)] 
doc: clarify the intended audience of CGROUP_DELEGATION.md

There was some confusion about who is the intended audience. Let's
clarify that early on, to ensure people aren't disappointed.

6 years agoMerge pull request #8840 from poettering/unsigned-size_t
Lennart Poettering [Fri, 27 Apr 2018 15:15:45 +0000 (17:15 +0200)] 
Merge pull request #8840 from poettering/unsigned-size_t

fix various array size/index types to be size_t rather than unsigned

6 years agoman: updated systemd-analyze blame description for service-units with Type=simple...
Mikhail Kasimov [Fri, 27 Apr 2018 14:06:39 +0000 (17:06 +0300)] 
man: updated systemd-analyze blame description for service-units with Type=simple (#8834)

Fixes #5121.

6 years agoupdate TODO 8840/head
Lennart Poettering [Fri, 27 Apr 2018 12:28:51 +0000 (14:28 +0200)] 
update TODO

6 years agotree-wide: use newa() rather than alloca() where we can
Lennart Poettering [Fri, 27 Apr 2018 12:28:35 +0000 (14:28 +0200)] 
tree-wide: use newa() rather than alloca() where we can