Commit Graph

4081 Commits

Author SHA1 Message Date
Lennart Poettering 960d4b29d7
Merge pull request #10334 from keszybz/nomempool
Use mempool only in progs linked to libsystemd-shared.so
2018-10-11 13:44:34 +02:00
Zbigniew Jędrzejewski-Szmek 6939fb9eb4 meson: update bug reference
https://github.com/mesonbuild/meson/issues/1644 was resolved in 0.42:
be4428005d,
but still no-go.
2018-10-11 10:55:41 +02:00
dana 3118a4cf17 man: clarify behaviour of RandomizedDelaySec= 2018-10-10 16:15:05 +02:00
Asbjørn Apeland ca92fe36e0 man: fix typo 2018-10-10 09:57:57 +02:00
Zbigniew Jędrzejewski-Szmek dd76367d3b
Merge pull request #10307 from poettering/portable-path
finishing touches to portable services, and let's move portablectl to /usr/bin to make it official
2018-10-09 14:58:22 +02:00
Franck Bui c6885f5f36 core: introduce systemd.early_core_pattern= kernel cmdline option
Until a core dump handler is installed by systemd-sysctl, the generation of
core dump for services is turned OFF which can make the debugging of the early
boot process harder especially since there's no easy way to restore the core
dump generation.

This patch introduces a new kernel command line option which specifies an
absolute path where the kernel should write the core dump file when an early
process crashes.

This will take effect until systemd-coredump (or any other handlers) takes
over.
2018-10-09 10:26:23 +02:00
Lennart Poettering bd2865caf6 bootctl: include boot entries discovered by the boot loader but not in $BOOT in the "list" output
Let's use the new LoaderEntries efi var for this, and show all entries
we couldn't find via the config snippets.
2018-10-08 21:40:44 +02:00
Lennart Poettering d88c96ffe5 bootctl: add new verbs for setting the default boot/oneshot entry
Fixes: #5739 #8574
2018-10-08 21:40:44 +02:00
Lennart Poettering 8cbb7d8783 efi: allow ESP validity checks to be turned off
let's add an env var for this, as this really shouldn't be a top-level
feature, as it turning off the validity checks certainly isn't
advisable.

Fixes: #4925
2018-10-08 21:40:44 +02:00
Lennart Poettering 4eb5636b6c man: various updates to the bootctl man page 2018-10-08 21:40:44 +02:00
Lennart Poettering dcb4fe7401 man: document the new --no-pager switch of bootctl
Also, let's move the --help and --version items to the end of the list.
2018-10-08 21:40:44 +02:00
Lennart Poettering 1634ebb54a
Merge pull request #10262 from keszybz/hibres-disable
Switches to disable hibernation and/or resuming
2018-10-08 21:39:54 +02:00
Lennart Poettering 787dfb82f5 portabled: generate a more useful error when invalid image types are attempted to be attached
Fixes: #10095
2018-10-08 18:49:45 +02:00
Lennart Poettering 2ace445da7 man: explain the two search paths in the SYNOPSIS with a header 2018-10-08 18:49:45 +02:00
Lennart Poettering 83f72cd65f man,docs: document the new unit file directory for attached images 2018-10-08 18:49:45 +02:00
Zbigniew Jędrzejewski-Szmek e8f1d00d69 shared/sleep-config: add switches to kill specific sleep modes
/etc/systemd/sleep.conf gains four new switches:
AllowSuspend=, AllowHibernation=, AllowSuspendThenHibernate=, AllowHybridSleep=.

Disabling specific modes was already possible by masking suspend.target,
hibernate.target, suspend-then-hibernate.target, or hybrid-sleep.target.
But this is not convenient for distributions, which want to set some defaults
based on what they want to support. Having those available as configuration
makes it easy to put a config file in /usr/lib/systemd/sleep.conf.d/ that
overrides the defaults and gives instructions how to undo that override.
2018-10-08 18:21:00 +02:00
Zbigniew Jędrzejewski-Szmek e83419d043 hib-res-generator: add "noresume"
This is an override parameter, to totally skip dehiberanation.
2018-10-08 16:06:16 +02:00
Yu Watanabe 8a89c5392d man: fix explanation about UID/GID field in tmpfiles.d(5)
Fixes #9495.
2018-10-05 19:06:10 +02:00
Alan Jenkins 923f910115 man/systemd.exec: MountFlags=shared behaviour was changed (fixed?)
The behaviour described *was* observed on Fedora 28
(systemd-238-9.git0e0aa59), with and without SELinux.  I don't actually
know why though!  It contradicts my understanding of the code, including an
explicit comment in the code.

Testing in a VM upgraded to v239-792-g1327f272d, this behaviour goes away.


Test case:

# /etc/systemd/system/mount-test.service
[Service]
MountFlags=shared
Type=oneshot
ExecStart=/usr/bin/ls -l /proc/1/ns/mnt /proc/self/ns/mnt
ExecStart=/usr/bin/grep ext4 /proc/self/mountinfo


Weird old behaviour: new mount namespace but / is fully shared.

lrwxrwxrwx. 1 root root 0 Sep 14 11:18 /proc/1/ns/mnt -> mnt:[4026531840]
lrwxrwxrwx. 1 root root 0 Sep 14 11:48 /proc/self/ns/mnt ->
mnt:[4026532851]

968 967 253:0 / / rw,relatime shared:1 - ext4 /dev/mapper/alan_dell_2016...


Current behaviour: / is not fully shared

lrwxrwxrwx. 1 root root 0 Sep 14 11:39 /proc/1/ns/mnt -> mnt:[4026531840]
lrwxrwxrwx. 1 root root 0 Sep 14 11:41 /proc/self/ns/mnt ->
mnt:[4026532329]

591 558 8:3 / / rw,relatime shared:313 master:1 - ext4 /dev/sda3 rw,secl...
2018-10-05 17:38:38 +02:00
Stephen Gallagher a3e0bba8a9 Add DOCUMENTATION_URL as a standard value for /etc/os-release
It is very useful for distributions to be able to set a primary
documentation URL in a standard location so that users and
applications on the system can identify it. For example, many
headless systems these days use the "Cockpit" admin console. It
would be ideal if we could specify this location directly in the
os-release file so that any application or service could have a
well-known location for retrieving this and displaying it
appropriately. Users could likewise examine /etc/os-release to
learn this location.

Related: https://github.com/cockpit-project/cockpit/issues/10198

Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2018-10-04 21:29:18 +02:00
Zbigniew Jędrzejewski-Szmek e80ef269a1
Merge pull request #10255 from poettering/hide-new-id128
drop references to "journalctl --new-id128"
2018-10-02 17:54:36 +02:00
Lennart Poettering b9d016d684 tree-wide: drop all references to "journalctl --new-id128"
Let's advertise "systemd-id128 new" instead.
2018-10-02 16:43:54 +02:00
Lennart Poettering 19a073db9b journalctl: drop --new-id128 from help and man texts
Let's remove redundancy and not advertise "journalctl --new-id128"
anymore, now that we have "systemd-id128 new" in a proper tool.

This allows us to reduce the overly large journalctl command set a bit.

Note that this just removes the --help and man text, the call remains
available for compat reasons.
2018-10-02 16:42:30 +02:00
Zbigniew Jędrzejewski-Szmek adda90b03e man: add man page for systemd-id128 2018-10-02 15:15:10 +02:00
Zbigniew Jędrzejewski-Szmek 0d1d512f7f systemd-id128: a new tool to print machine/boot/invocation/app-specific ids
The raison d'etre for this program is printing machine-app-specific IDs. We
provide a library function for that, but not a convenient API. We can hardly
ask people to quickly hack their own C programs or call libsystemd through CFFI
in python or another scripting language if they just want to print an ID.

Verb 'new' was already available as 'journalctl --new-id128', but this makes
it more discoverable.

v2:
- rename binary to systemd-id128
- make --app-specific= into a switch that applies to boot-id and machine-id
2018-10-02 15:15:10 +02:00
Zbigniew Jędrzejewski-Szmek 65d410c7ca sd-id128: add sd_id128_get_boot_app_specific() 2018-10-02 15:15:10 +02:00
Jonas DOREL 6cc2b88275 man: add systemctl suspend-then-hibernate (#10194)
This commit tries to document the systemctl suspend-then-hibernate documentation in the systemctl(1) manpage.

Fixes #10192.
2018-09-28 15:56:48 +02:00
Susant Sahani 6cf0a20491 udev/net: add support for the equivalent of "ethtool advertise" to .link files
This work adds support for the equivalent of "ethtool advertise" to .link files?
http://lists.freedesktop.org/archives/systemd-devel/2015-April/030112.html
2018-09-26 22:21:42 +02:00
Anita Zhang c87700a133 Make Watchdog Signal Configurable
Allows configuring the watchdog signal (with a default of SIGABRT).
This allows an alternative to SIGABRT when coredumps are not desirable.

Appropriate references to SIGABRT or aborting were renamed to reflect
more liberal watchdog signals.

Closes #8658
2018-09-26 16:14:29 +02:00
William Douglas 6d7b543342 RFC tmpfiles: Allow configuration to ignore execution errors
This is an implementation that covers making errors encountered when writing
file content optionally fatal. If this is something that folks would want I'll
add handling of this for all the other directives. I'd appreciate suggestions
on how this might better be structured as well (use of a goto fail or such) as
I'm not super happy with the approach.
2018-09-25 23:30:30 +02:00
Lennart Poettering 2b5d05fdfe
Merge pull request #10088 from keszybz/man-systemctl-return
man: add a description of systemctl return codes
2018-09-25 12:35:36 +02:00
Lennart Poettering 7c428bb5d5
Merge pull request #10059 from yuwata/env-exec-directory
core: introduce $RUNTIME_DIRECTORY= or friends
2018-09-25 12:34:30 +02:00
Lennart Poettering a942661787 inhibit: use format-table to format systemd-inhibit --list
This changes the output a bit, as the previous multi-line output of each
inhibitor is changed to a single line, but it does unify the output look
with the one of our other tools. Moreover this adds proper sorting.
2018-09-24 19:21:00 +02:00
Patrik Flykt 125f20b4de networkd-network: Introduce DHCPv6 PD knob for RFC 7084 WPD-4
RFC 7084, WPD-4, requires Customer Edge end routers to behave
according to the following:

"WPD-4:  By default, the IPv6 CE router MUST initiate DHCPv6 prefix
           delegation when either the M or O flags are set to 1 in a
           received Router Advertisement (RA) message.  Behavior of the
           CE router to use DHCPv6 prefix delegation when the CE router
           has not received any RA or received an RA with the M and the
           O bits set to zero is out of scope for this document."

Since it cannot be automatically detected whether DHCPv6 is to be
operated as an CE end router or whether to initiate an Informational
exchange to obtain other useful network information via DHCPv6 when the
Router Advertisement 'O' bit is set, a 'ForceDHCPv6PDOtherInformation'
boolean network configuration option in the '[DHCP]' section of a is
introduced. Setting this option causes DHCPv6 to be started in stateful
mode, although only the 'O' bit is seen in the Router Advertisement.

When 'ForceDHCPv6PDOtherInformation' is set and the Router Advertisement
has only the Other information 'O' bit set, disable requests for IA_NA
addresses.

Fixes #9745.
2018-09-19 13:45:17 -06:00
Zbigniew Jędrzejewski-Szmek 4aabca0058 man: remove recommendation to pull in slices from slices.target
That recommendation is likely to cause more trouble and for pretty
much all end-user units is not useful. Let's recommend relying on
the implicit dependency instead.

Fixes #10015.
2018-09-14 16:39:47 +02:00
Zbigniew Jędrzejewski-Szmek 23a9ffb093 man: add a description of systemctl return codes
Fixes #10056.
2018-09-14 16:02:48 +02:00
Harshit Jain 8c63965c20 man: fix typo (#10084)
fixes #10083
2018-09-14 16:04:10 +09:00
killermoehre a8a273743f replace https://github.com/systemd/systemd/blob/master/doc/* with https://github.com/systemd/systemd/blob/master/docs/* to point to proper documentation 2018-09-13 22:12:38 +02:00
Yu Watanabe d491e65e74 man: document RUNTIME_DIRECTORY= or friends 2018-09-13 17:02:58 +09:00
Zbigniew Jędrzejewski-Szmek 9d0798a2ed
Merge pull request #9832 from yuwata/fix-9831
network: fixes related to setting MTU
2018-09-08 17:17:07 +02:00
Julian Andres Klode abcf95e95e man: Document networkd states in networkctl(1) (#10033)
The manpage gives example outputs with the states, but it never
explains what the states are.

Fixes #575
2018-09-07 16:39:44 +02:00
Michal Sekletar 70f5f48eb8 cryptsetup-generator: introduce basic keydev support
Dracut has a support for unlocking encrypted drives with keyfile stored
on the external drive. This support is included in the generated initrd
only if systemd module is not included.

When systemd is used in initrd then attachment of encrypted drives is
handled by systemd-cryptsetup tools. Our generator has support for
keyfile, however, it didn't support keyfile on the external block
device (keydev).

This commit introduces basic keydev support. Keydev can be specified per
luks.uuid on the kernel command line. Keydev is automatically mounted
during boot and we look for keyfile in the keydev
mountpoint (i.e. keyfile path is prefixed with the keydev mount point
path). After crypt device is attached we automatically unmount
where keyfile resides.

Example:
        rd.luks.key=70bc876b-f627-4038-9049-3080d79d2165=/key:LABEL=KEYDEV
2018-09-04 16:54:53 +02:00
Liberasys 8b247b43c8 man: fix a typo in the documentation (#10003) 2018-09-04 00:35:44 +09:00
Yu Watanabe e03b9f2a3b
Merge pull request #9919 from keszybz/more-sd-bus-doc
Some more sd-bus docs
2018-09-03 21:44:30 +09:00
Todd Walton eaaec6cc12 man: fix RFC ref in resolved.conf man page (#9976)
This is a simple one-character fix to reference the correct RFC for
LLMNR, which is RFC 4795, not RFC 4794.
2018-08-30 09:47:07 +09:00
Dimitri John Ledkov a9fc640671 cryptsetup: add support for sector-size= option (#9936)
Bug-Ubuntu: https://launchpad.net/bugs/1776626

Closes #8881.
2018-08-29 23:38:09 +09:00
Lucas Werkmeister f16eb8b083 man: use singular “they”
For an example where we already use it, see man:sd-login(3):

> A session is defined by the time a user is logged in until they log out.

As far as I can tell, this removes the only remaining occurrences of
referring to users by gendered pronouns in our documentation (though
some still survive in code comments and the NEWS and TODO files):

    git grep '\b\(he\|him\|his\|she\|her\|hers\)\b' man/
2018-08-23 15:54:46 -07:00
Daniel Kahn Gillmor 74053ff282 doc: fix resolvectl(1) per-interface DNS configuration documentation
You can only have one listitem in each varlistentry.

xmllint says:

    resolvectl.xml:269: element varlistentry: validity error : Element varlistentry content does not follow the DTD, expecting (term+ , listitem), got (term term term term term term term listitem listitem listitem )
2018-08-23 14:47:43 -07:00
Daniel Kahn Gillmor b87613ecce doc: fix udev(7) documentation about ATTR{} and SYSCTL{}
Without this fix, udev(7) munges the two items together, like so:

       ATTR{filename}, SYSCTL{kernel parameter}
           Match sysfs attribute values of the event device. Trailing
           whitespace in the attribute values is ignored unless the specified
           match value itself contains trailing whitespace.  Match a kernel
           parameter value.

You're not allowed to have a <term> element after a <listitem> element within a
<varlistentry>.

xmllint complains:

    udev.xml:192: element varlistentry: validity error : Element varlistentry content does not follow the DTD, expecting (term+ , listitem), got (term listitem term listitem )
2018-08-23 14:47:43 -07:00
Zbigniew Jędrzejewski-Szmek d7338be4f0 man: add sd_bus_message_get_signature(3) 2018-08-23 16:57:55 +02:00
Zbigniew Jędrzejewski-Szmek e6a2feb57d
Merge pull request #8135 from shawnl/arg_host
sd-bus: rework host handling
2018-08-23 13:46:54 +02:00
Susant Sahani 53cb501a13 networkd and sd-netlink: add support for Generic netlink And FooOverUDP to IPIP tunnel
This work add support to generic netlink to sd-netlink.
See https://lwn.net/Articles/208755/

networkd: add support FooOverUDP support to IPIP tunnel netdev
https://lwn.net/Articles/614348/

Example conf:

/lib/systemd/network/1-fou-tunnel.netdev
```
[NetDev]
Name=fou-tun
Kind=fou

[FooOverUDP]
Port=5555
Protocol=4

```

/lib/systemd/network/ipip-tunnel.netdev
```
[NetDev]
Name=ipip-tun
Kind=ipip

[Tunnel]
Independent=true
Local=10.65.208.212
Remote=10.65.208.211
FooOverUDP=true
FOUDestinationPort=5555
```

$ ip -d link show ipip-tun
```
5: ipip-tun@NONE: <POINTOPOINT,NOARP> mtu 1472 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/ipip 10.65.208.212 peer 10.65.208.211 promiscuity 0
    ipip remote 10.65.208.211 local 10.65.208.212 ttl inherit pmtudisc encap fou encap-sport auto encap-dport 5555 noencap-csum noencap-csum6 noencap-remcsum numtxqueues 1 numrxqueues 1 gso_max_size 65536 gso_max_segs 65535
```
2018-08-23 11:30:37 +02:00
Zbigniew Jędrzejewski-Szmek c07fe6d0df Merge pull request #9406 from yuwata/rfe-9228
Trivial conflict solved in merge and include net/if_arp.h added.
2018-08-23 11:11:13 +02:00
Steve Ramage a7c64e14e7 man: Fixed grammatical error in systemd.socket.xml (#9916) 2018-08-23 13:14:17 +09:00
Tejun Heo 6ae4283cb1 core: add IODeviceLatencyTargetSec
This adds support for the following proposed latency based IO control
mechanism.

  https://lkml.org/lkml/2018/6/5/428
2018-08-22 16:46:18 +02:00
Chris Morin 0367307e27 man: correct journald field name 2018-08-22 16:21:52 +02:00
Lennart Poettering 2d2224e407 man: document that most sandboxing options are best effort only 2018-08-21 20:00:33 +02:00
Yu Watanabe 7169cdc8b9 network: prohibit to set MTUBytes= and UseMTU= simultaneously 2018-08-13 16:14:56 +09:00
Zbigniew Jędrzejewski-Szmek 7f9f55e1b3 man: add sd_bus_message_read_array(3) 2018-08-11 12:25:54 +02:00
Zbigniew Jędrzejewski-Szmek 58df2afbbf man: add sd_bus_message_skip(3) 2018-08-11 12:25:54 +02:00
Franck Bui f17a8d6178 tmpfiles: don't adjust qgroups on existing subvolumes
The qgroup logic (types 'q' and 'Q') only has an effect if there's no previous
setup at all, and any explicitly configured subvolumes with their qgroups are
left entirely unmodified.

The idea is that if users want a different logic than the one we set up by
default, then by all means they should do that before hand, and tmpfiles won't
override their logic.
2018-08-08 12:37:35 +02:00
Yu Watanabe 8fa266c2a4 man: mention that DUIDType=link-layer-time or link-layer uses MAC address 2018-08-08 10:15:00 +09:00
Yu Watanabe 319b94bca7 man: mention that DUIDType=uuid uses the product UUID or machine-ID 2018-08-08 10:15:00 +09:00
Lennart Poettering 6f663594bc
Merge pull request #9744 from yuwata/fix-9737
Make RootImage= work with PrivateDevices=
2018-08-07 09:55:07 +02:00
Filipe Brandenburger adb6cd9be2 systemctl: add support for --wait to is-system-running
This makes it possible to wait until boot is finished without having to poll
for this command repeatedly, instead using the syntax:

  $ systemctl is-system-running --wait

Waiting is implemented by waiting for the StartupFinished signal to be posted
on the bus.

Register the matcher before checking for the property to avoid race conditions.

Tested by artificially delaying startup with a oneshot service and calling this
command, checked that it emitted `running` and exited with a 0 return code as
soon as the delay service completed startup.

Also tested that booting to degraded state unblocks the command.

Inserted a delay between getting the property and waiting for the signal and
confirmed this seems to work free of race conditions.

Updated the --help text (under --wait) and the man page to document the new
feature.
2018-08-07 09:33:25 +02:00
Shawn Landden 2e6fe09002 man/sd_bus_default: update to reflect changes 2018-08-06 14:30:53 -07:00
Shawn Landden 026df70eaf man: update to reflect changes in -H HOST parsing 2018-08-06 14:29:46 -07:00
Zbigniew Jędrzejewski-Szmek 7735d9397b
Merge pull request #9792 from poettering/hashmap-mempool
minor hashmap fixes
2018-08-06 14:13:30 +02:00
Zbigniew Jędrzejewski-Szmek cad8d67194 Merge pull request #9775 from yuwata/follow-up-9766 2018-08-06 07:59:34 +02:00
Yu Watanabe fe65e88ba6 namespace: implicitly adds DeviceAllow= when RootImage= is set
RootImage= may require the following settings
```
DeviceAllow=/dev/loop-control rw
DeviceAllow=block-loop rwm
DeviceAllow=block-blkext rwm
```
This adds the following settings implicitly when RootImage= is
specified.

Fixes #9737.
2018-08-06 14:02:31 +09:00
Yu Watanabe 31ee397327 man: mention that Hostname= for DHCP must be a valid DNS domain name 2018-08-06 10:48:12 +09:00
Lennart Poettering 7647c01d8f man: include libsystemd-pkgconfig.xml in a few more man pages
for some reason this was forgotten for a couple of sd_bus man pages,
let's fix that.
2018-08-03 17:36:11 +02:00
Lennart Poettering 64a7ef8bc0 man: be more explicit about thread safety of sd_journal
Triggered by https://bugzilla.redhat.com/show_bug.cgi?id=1609349

This adds two generic paragaphs we include via xinclude. One is the
"strict" version, which contains wording saying that we are thread
agnostic and what that means. And the other is the "safe" version, for
the cases we provide fully safety.

Let's then change most man pages to use either of these generic
paragraphs. With one exception: man/sd_journal_get_catalog.xml contains
both kinds of function, we hence use manual wording.
2018-08-03 17:36:11 +02:00
Lennart Poettering e6c7c7ffd5 man: document that 'nofail' also has an effect on ordering
Prompted by #9765
2018-08-02 14:15:44 -07:00
Zbigniew Jędrzejewski-Szmek 46fdbae32e man: add sd_bus_message_rewind(3) 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek e7015301fb man: document sd_bus_slot_get_bus in sd_bus_slot_ref(3)
Similar reasoning as for sd_bus_message_get_bus().
2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek dee0fccca3 man: add sd_bus_slot_set_description(3) 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek 6d4a51820e man: add sd_bus_slot_set_userdata(3) 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek d65044e812 man: add sd_bus_message_set_expect_reply(3) 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek 9905256523 man: document sd_bus_message_get_bus() in sd_bus_message_new(3)
It's not a particularly obvious place, but it's a trivial function that isn't
worth a man page of its own, and it doesn't fit anywhere else either.
2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek 2c48865bd0 man: add sd_bus_message_verify_type(3) 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek 9c9207912e man: add sd_bus_message_get_type(3)
sd_bus_message{get_type,is_signal,is_method_call,is_method_error} get one man
page.

sd_bus_message_{set,get}_{destination,path,interface,member,sender} are put in
the second one.
2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek f16a506418 man: add sd_bus_slot_ref(3) 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek 7ddee21716 man: document sd_bus_message_new_method_return 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek f00ded93e0 man: document *_with_description functions 2018-08-02 15:49:45 +02:00
Zbigniew Jędrzejewski-Szmek 206ed9c1f6 man: add sd_bus_message_new(3) 2018-08-02 15:48:46 +02:00
Zbigniew Jędrzejewski-Szmek 787f78b6a1 man: move more examples to stand-alone files and use 2-space indentation consistenty
Moving them out makes it easier to run them through a compiler, use automatic
indentation, and opens the possibility to provide a download link in the
future. I verified that all examples compile cleanly.

(2-space indentation is used because the examples are already significantly
indented in the man page, and we need to keep them narrow so that they display
well on standard terminals.)
2018-08-02 15:45:24 +02:00
Zbigniew Jędrzejewski-Szmek 2c47fff6d2 man: clarify what can be NULL in an sd_bus_unrefp call
Confusingly, the argument is called 'bus' in all cases. Let's not give people
the idea to call sd_bus_unrefp(NULL).
2018-08-02 15:45:24 +02:00
Zbigniew Jędrzejewski-Szmek cfe8ee463d man: add sd_bus_message_new_call(3) 2018-08-02 15:45:20 +02:00
Zbigniew Jędrzejewski-Szmek e8b84fcca6 man: add sd_bus_message_new_signal(3) 2018-08-02 15:44:25 +02:00
Zbigniew Jędrzejewski-Szmek 5a8b164092 meson: drop parens when appending to list
Meson does not care either way, so let's use the simpler syntax. And files()
already gives a list, so nesting this in a list wouldn't be necessary even
if meson did not flatten everything.
2018-07-31 21:02:01 +09:00
Yu Watanabe 1c57fa90be man: move explanations about boolean and time-span value from systemd.unit to systemd.syntax
Fixes #9735.
2018-07-30 14:13:42 +02:00
Yu Watanabe 494c5676b3 man: use literal tag 2018-07-28 21:46:22 +09:00
Yu Watanabe 8631708741 resolve: add option to toggle reading /etc/hosts
Workaround for #9718.
2018-07-28 21:46:00 +09:00
Lennart Poettering 79905a246d man: document the new Type=exec type
And while we are at it, let's rearrange and extend the Type=
documentation a bit. Let's make it an itemized list, and let's add a
paragraph explaining which type best to use.
2018-07-25 22:48:11 +02:00
Lennart Poettering b115f33cc6 man: update pam_systemd to reflect recent changes
1. Document the new desktop= parameter

2. Clarify that we set XDG_SESSION_DESKTOP, XDG_SESSION_CLASS,
   XDG_SESSION_TYPE if we have the data, and don't just read it.
2018-07-25 16:09:33 +02:00
Lennart Poettering 1acfbbff46 man: document that pam_systemd actually sets XDG_SEAT and XDG_VTNR
The old wording is not clear regarding whether the env var will be
updated or just a fallbacked is used.
2018-07-25 16:07:27 +02:00
Lennart Poettering d68c0833ea man: document CPUAffinity= in system.conf in more detail
Fixes: #9692
2018-07-25 16:01:28 +02:00
Christian Rebischke e92b3655b8 fixed ugly colorcodes on brackets
Signed-off-by: Christian Rebischke <Chris.Rebischke@posteo.de>
2018-07-24 10:43:31 +02:00
Lennart Poettering 5038df43be make dir-locals work again with emacs 26.1
After upgrading to emacs-26.1-1.fc28.x86_64 I noticed that our
.dir-locals.el files weren't honoured anymore (specifically the fill
column variable is not correctly set for c-mode files). I finally
tracked this down to the order in which items are listed in
.dir-locals.el: if the "nil" one is listed last everything works,
otherwise, it's the one that is applied instead of the c-mode one.

This patch simply swaps the entries, and puts the "nil" one last. My
emacs lisp fu is a bit too limited to understand the full impact for
this, and why emacs 26.1 changed behaviour in this regard, but from an
outsider's view the order shouldn't negatively affect things otherwise,
hence this patch.
2018-07-23 20:00:48 +02:00
Lion Yang 2fafabfdc4 coredumpctl: info shows the last entry by default
Closes #9524.
2018-07-23 17:45:53 +02:00
Yu Watanabe 08540a9591 meson: allow building resolved and machined without nss modules
This adds -Dnss-resolve= and -Dnss-mymachines= meson options.
By using this option, e.g., resolved can be built without nss-resolve.
When no nss modules are built, then test-nss is neither built.

Also, This changes the option name -Dmyhostname= to -Dnss-myhostname=
for consistency to other nss related options.

Closes #9596.
2018-07-23 14:03:05 +02:00
Jon Ringle fbb48d4c66 Make final kill signal configurable
Usecase is to allow changing the final kill from SIGKILL to SIGQUIT which
should create a core dump useful for debugging why the service didn't stop
with the SIGTERM
2018-07-23 13:44:54 +02:00
glitsj16 bc21034688 Fix grammar 2018-07-21 10:17:58 +09:00
Lennart Poettering f14d0b2314
Merge pull request #9671 from keszybz/tasks-max-doc
Document user@.service and friends
2018-07-20 20:05:45 +02:00
Zbigniew Jędrzejewski-Szmek a99655b052 man: add a description of user@.service, user-runtime-dir@.service, user-*.slice
Fixes #9590.
2018-07-20 16:57:50 +02:00
Zbigniew Jędrzejewski-Szmek 96719f158a man: split systemd.special(7) into separate system/user sections
User units were in the middle, which is just confusing. Let's discuss
all system units first, and all user units second.

I'm using "System manager units" and "user manager units" instead of the more
obvious "system units" and "user units", because there are also units like
"user@.service".
2018-07-20 16:57:50 +02:00
Ryutaroh Matsumoto be60dd3ec8 Various accountings are not implied by their controllers
The original manpage says "Implies BBBAccounting" many times but actually that accounting is not implied by the respective resource control in v239 with the unified cgroup hierarchy. This commit removes those false explanations.
2018-07-20 16:44:40 +02:00
Lennart Poettering f606cd16d3
Merge pull request #9500 from zsol/append
Add support for opening files for appending
2018-07-20 15:45:08 +02:00
Lennart Poettering 496a6ba40e
Merge pull request #9516 from keszybz/module-load-unification
Module load unification
2018-07-20 13:55:56 +02:00
Zsolt Dollenstein 566b7d23eb Add support for opening files for appending
Addresses part of #8983
2018-07-20 03:54:22 -07:00
Zbigniew Jędrzejewski-Szmek f07b548940 man: fix list-files example
The dot is only shown for failed units.

Alternative for #9644.
2018-07-19 11:31:05 +02:00
Lennart Poettering 8d568e8d3e
Merge pull request #9346 from keszybz/journald-exact2
Store a copy of the input message if any stripping or truncation occurs
2018-07-18 21:00:43 +02:00
Chen Qi 49bdfaba92 man/systemd.resource-control.xml: point user to correct url
cpu.cfs_quota_us is actually explained in sched-bwc.txt instead of
sched-design-CFS.txt.
2018-07-18 13:17:24 +02:00
Lennart Poettering 9236cabf78 man: elaborate a bit on the effect of PrivateNetwork=
Triggered by this thread:

https://lists.freedesktop.org/archives/systemd-devel/2018-July/040992.html
2018-07-17 21:41:23 +02:00
Filipe Brandenburger 06c28aa0d8 resolvectl: Take empty string argument to clear lists in "dns", "domain" and "nta" options
The current CLI does not support a way to clear these lists, since without any
additional arguments, the command will list the current values.

Introduce a new way to clear the lists by passing a single '' argument to these
subcommands.

Update the man page to document this.

Tested:
  $ build/resolvectl domain eth1
  Link 3 (eth1): ~.
  $ build/resolvectl domain eth1 ''
  $ build/resolvectl domain eth1
  Link 3 (eth1):
  $ build/resolvectl domain eth1 '~.' '~example.com'
  $ build/resolvectl domain eth1
  Link 3 (eth1): ~. ~example.com
  $ build/resolvectl domain eth1 ''
  $ build/resolvectl domain eth1
  Link 3 (eth1):
  $ build/resolvectl domain eth1 '~.'
  $ build/resolvectl domain eth1
  Link 3 (eth1): ~.

And similar for "dns" and "nta".
2018-07-17 21:20:52 +02:00
Lennart Poettering 81d39f0d2c man: fix --ignore-inhibitors docs
Reported here:

https://lists.freedesktop.org/archives/systemd-devel/2018-June/040939.html

Also see:

https://lists.freedesktop.org/archives/systemd-devel/2018-July/041036.html
2018-07-17 09:49:04 -07:00
Lennart Poettering 6e0210908e man: clarify that prefixing ExecStart= lines with "-" won't cause systemd to not record non-zero exit statuses
See: #9588
2018-07-17 06:32:54 -07:00
Yu Watanabe bd277f53e8 man: fix group name for systemd-networkd 2018-07-17 03:12:19 +09:00
Lennart Poettering db9eee7e45
Merge pull request #9530 from keszybz/sd-bus-doc
More documentation for sd-bus
2018-07-16 15:01:12 +02:00
Zbigniew Jędrzejewski-Szmek d35f51ea84 tree-wide: use "polkit" to refer to PolicyKit/polkit
Back in 2012 the project was renamed, see the release notes for v 0.105
[https://cgit.freedesktop.org/polkit/tree/NEWS#n754]. Let's update our
documentation and comments to do the same. Referring to PolicyKit is confusing
to users because at the time the polkit api changed too, and we support the new
version. I updated NEWS too, since all the references to PolicyKit there were
added after the rename.

"PolicyKit" is unchanged in various URLs and method call names.
2018-07-16 12:44:24 +02:00
Zbigniew Jędrzejewski-Szmek b750778751 meson: allow systemd.directives and .index to be built if -Dman=false
See 559d215b67 for justification.
2018-07-16 12:36:44 +02:00
Zbigniew Jędrzejewski-Szmek 3c775de6c5 man: add sd_bus_set_description(3) 2018-07-16 12:36:44 +02:00
Zbigniew Jędrzejewski-Szmek 629941003e man: add sd_bus_reply_method_error(3) 2018-07-16 12:25:16 +02:00
Zbigniew Jędrzejewski-Szmek c5fd8c3995 man: add sd_bus_message_copy(3) 2018-07-16 12:25:16 +02:00
Zbigniew Jędrzejewski-Szmek e50f471888 man: add sd_bus_message_new_error(3) 2018-07-16 12:25:14 +02:00
Michal Soltys 0029e6b193 [man] minor systemd.target manual update
Target units gain both Conflicts= and Before= against shutdown.target
(not only Conflicts=).
2018-07-13 19:07:43 +02:00
Tejun Heo 4842263577 core: add MemoryMin
The kernel added support for a new cgroup memory controller knob memory.min in
bf8d5d52ffe8 ("memcg: introduce memory.min") which was merged during v4.18
merge window.

Add MemoryMin to support memory.min.
2018-07-12 08:21:43 +02:00
Yu Watanabe 0fad72faee man: convert old compile option to meson option 2018-07-09 06:53:42 +02:00
Zbigniew Jędrzejewski-Szmek 7215aad64a sd-bus(3): synchronize the list with reality
Use <literallayout> to keep each reference on a separate line. With all the
pages jumbled together into a paragraph, it is quite hard to find anything in
that list.

Also add the missing pages to the list. And remove the nonexistent ones — not
much point in advertisting pages that haven't been written yet.
2018-07-08 15:24:12 +02:00
Alexander Kurtz 1448dfa6bf man: Mention that paths in unit files must be fully normalized.
Related to issues #9107 and #9498 and PRs #9149 and #9157.
2018-07-05 22:55:26 +02:00
Zbigniew Jędrzejewski-Szmek 7c30c3c44f journal: store the original timestamp as SYSLOG_TIMESTAMP=
This is useful if someone wants to recreate the original syslog datagram. We
already include timestamp information as _SOURCE_REALTIME_TIMESTAMP=, and in
normal use that timestamp, converted back to the form used by syslog
(Mth dd HH:MM:SS) would usually give the value. But there are various
circumstances where this might not be true. Most obviously, if the datagram is
sent a bit later after being prepared, the time is rounded to the nearest
second, and it might be off. This is especially bad around New Year when the
syslog timestamp wraps around. Then the same timezone and locale need to be
used to recreate the original timestamp. In the end doing this reliably is
complicated, and it seems much easier to just unconditionally include the
original timestamp.

If the original timestamp cannot be located, we store the full log line.
This way, it should be always possible to recreate the original input.

Example:
MESSAGE=x
SYSLOG_TIMESTAMP=Sep 15 15:07:58
SYSLOG_RAW
^]^@^@^@^@^@^@^@<13>Sep 15 15:07:58 HOST: x^@y
_PID=3318
_SOURCE_REALTIME_TIMESTAMP=1530743976393553

Fixes #2398.
2018-07-05 00:40:35 +02:00
Zbigniew Jędrzejewski-Szmek df8701a3f2 journal: store the original syslog input as SYSLOG_RAW=
This allows the original stream to be recreated and/or verified. The new field
is written if any stripping was done or if the input message contained embeded
NULs.

$ printf '<13>Sep 15 15:07:58 HOST: x\0y' | nc -w1 -u -U /run/systemd/journal/dev-log

$ journalctl -o json-pretty ...
{
  ...
  "MESSAGE" : "x",
  "SYSLOG_RAW" : [ 60, 49, 51, 62, 83, 101, 112, 32, 49, 53, 32, 49, 53, 58, 48, 55, 58, 53, 56, 32, 72, 79, 83, 84, 58, 32, 120, 0, 121 ]
}

$ journalctl -o export ... | cat -v
...
MESSAGE=x
SYSLOG_RAW
^]^@^@^@^@^@^@^@<13>Sep 15 15:07:58 HOST: x^@y

This mostly fixes #4863.
2018-07-04 18:18:04 +02:00
Zbigniew Jędrzejewski-Szmek 58f4458afd man: fix typo 2018-07-04 10:53:21 +02:00
Lennart Poettering 98b0b1123c
Merge pull request #9490 from keszybz/document-sd_message_read
Document sd_bus_message_read
2018-07-03 16:56:49 +02:00
Lennart Poettering cfffa385a3
Merge pull request #9489 from keszybz/copyright-removal-3
Copyright header removal, part 3 (or 4?)
2018-07-03 16:55:01 +02:00
Lucas Werkmeister 8252eb18b8 man: add missing <option> tag
One mention of --user was missing the surrounding <option> tag, making
the table look inconsistent (though the inconsistency is less obvious
after the reordering in 709f4c472c, since the four specifiers mentioning
the --user option are no longer immediately adjacent).
2018-07-03 14:53:36 +02:00
Zbigniew Jędrzejewski-Szmek 50972aac44 man: document sd_bus_read(), add more about sd_bus_read_basic() 2018-07-03 14:31:01 +02:00
Zbigniew Jędrzejewski-Szmek c765233c89 man: use the same markup for "ap" everywhere 2018-07-03 01:34:18 +02:00
Zbigniew Jędrzejewski-Szmek 514094f933 man: drop mode line in file headers
This is already included in .dir-locals, so we don't need it
in the files themselves.
2018-07-03 01:32:25 +02:00
mal 2479c4fe3f Add IPVLAN= to systemd.network man page (#9480)
Required and seems to work in 238.133
2018-07-02 14:31:58 +02:00
Yu Watanabe 69ae75d7ae man: add missing parentheses 2018-06-29 12:40:27 +09:00
Lennart Poettering ca285cdb40
Merge pull request #9422 from yuwata/conf-files
cleanups for default conf files
2018-06-28 10:17:54 +02:00
Lennart Poettering a7e2e50d35 summary: update nspawn description string a bit
nspawn as it is now is a generally useful tool, hence let's drop the
comments about it being useful for debug and so on only.

The new wording just makes the first sentence of the main page also the
summary.
2018-06-28 11:55:44 +09:00
Yu Watanabe b34a21083b man: add missing option for system.conf 2018-06-26 04:07:44 +09:00
Yu Watanabe 48847676ca man: add comments about MTUBytes= and MACAddress= for tuntap devices
Closes #9407.
2018-06-25 18:54:38 +02:00
Zbigniew Jędrzejewski-Szmek dfe23d4145
Merge pull request #4522 from lucaswerkmeister/unescape-template
escape: support --unescape with --template
2018-06-25 18:48:01 +02:00
Michal Koutný 1a0d353b44 man: SystemMaxUse= clarification in journald.conf(5)
Similar semantics applies to {System,Runtime}MaxUse= as to
{System,Runtime}MaxFiles=, i.e. active files aren't vacuumed and the limit
is not thus strictly honored.
2018-06-25 11:18:20 +02:00
Lucas Werkmeister d936cddcb5 escape: add --instance option
Suggested by @keszybz in #4522.
2018-06-25 11:17:55 +02:00
Lucas Werkmeister e563e2534c escape: support --unescape with --template 2018-06-25 11:13:38 +02:00