Commit Graph

47262 Commits

Author SHA1 Message Date
Franck Bui 8ce3de991b
Merge pull request #17214 from poettering/log-generator-fix
fix logging in generators
2020-10-01 10:51:19 +02:00
Lennart Poettering fabf877705
Merge pull request #17154 from keszybz/crypttab-commas
Allow escaping commas in crypttab
2020-10-01 10:26:24 +02:00
Lennart Poettering 9230f5774a
Merge pull request #17213 from keszybz/man-cleanups
Fix links in man pages
2020-10-01 10:24:44 +02:00
Lennart Poettering 7ea3024b50 bootspec: don't fail with EIO if searching for ESP and finding one without an enveloping partition table
If this happens this should just mean: we couldn't find the ESP.

Fixes: #17122
2020-10-01 10:21:02 +02:00
Lennart Poettering dee29aeb59 generator: use kmsg in system-level generators, journal otherwise
Fixes: #17129.
2020-09-30 16:28:34 +02:00
Lennart Poettering ef9bddb799 log: normalize log target condition check
THis doesn't change the condition's logic at all, but is an attempt to
make things a bit more readable: instead of checking log_target !=
LOG_TARGET_AUTO let's actually list the targets where we want to
consider journal/syslog/kmsg, to make things a bit less confusing. After
all the message here is not to avoid them if LOG_TARGET_AUTO is set, but
to definitely do them in the other cases.
2020-09-30 16:17:12 +02:00
Lennart Poettering 27ffec0831 log: update comment
The logic was changed in bc694c06e6, let's
update the comment accordingly.
2020-09-30 16:06:55 +02:00
Jan Schlüter 644af26285 Add Aiptek Hyperpen 6000U to hwdb 2020-09-30 15:02:31 +02:00
Lennart Poettering 533ee38b56 man: mention that sd_bus_send() buffers locally, and sd_bus_process() is needed to flush it out
Prompted-by: #17128
2020-09-30 15:01:17 +02:00
Zbigniew Jędrzejewski-Szmek 21556381ff man: correct various links
As usual, linkchecker ftw!
2020-09-30 14:57:21 +02:00
Zbigniew Jędrzejewski-Szmek a9d99f6e3d man: update rules
Fixup for 278fdd064d.
2020-09-30 14:52:48 +02:00
Zbigniew Jędrzejewski-Szmek 550f3ba68d man/html: fix invocation for pages which are *not* symlinks
It seems I tested that redirects work, but I forgot to check that non-redirects
are still fine too ;(
2020-09-30 14:43:12 +02:00
Lennart Poettering d1f6e01e47 homed: explicitly deactivate all home directories on shutdown
Let's explicitly deactivate all home dirs on shutdown, in order to
properly synchronizing unmounting and avoiding blocking devices.

Previously, we'd rely on automatic deactivation when home directories
become unused. However, that scheme is asynchronous, and ongoing
deactviations might conflicts with attempts to unmount /home. Let's fix
that by providing an explicit service systemd-homed-activate.service
whose only job is to have a ExecStop= line that explicitly deactivates
all home directories on shutdown. This service can the be ordered after
home.mount and similar, ensuring that we'll first deactivate all homes
before deactivating /home itself during shutdown.

This is kept separate from systemd-homed.service so that it is possible
to restart systemd-homed.service without deactivating all home
directories.

Fixes: #16842
2020-09-30 14:37:52 +02:00
Lennart Poettering 626fb9f301
Merge pull request #17203 from poettering/resolv-conf-mode
expose resolv.conf mode bus property
2020-09-30 14:37:24 +02:00
Lennart Poettering 54565e509d
Merge pull request #17195 from keszybz/man-cleanups
Man page cleanups
2020-09-30 14:16:05 +02:00
Lennart Poettering 24d86fdb2f
Merge pull request #17087 from yuwata/man-initial-congestion-window
man: update InitialCongestionWindow= and InitialAdvertisedReceiveWindow=
2020-09-30 10:55:18 +02:00
Lennart Poettering b3ffa2b5f3 resolved: turn off that a search domain is derived from the host's fqdn
If the hostname of a system is set to an fqdn, glibc traditionally
derives a search domain from it if none is explicitly configured.

This is a bit weird, and we currently don't do that in our own search
path logic.

Following #17193 let's turn this behaviour off for now.

Yes, this has a slight chance of pissing people off who think this
behaviour is good. If this is indeed an issue, we can revisit the issue
but in that case if we readd the concept we should do it properly:
derive the search domain from the fqdn in our codebase too and report it
in resolvectl, and in our generated stub files. But I have the suspicion
most people who set the hostname to an fqdn aren#t even aware of this
behaviour nor want it, so let's wait until people complain.

Fixes: #17193
2020-09-30 10:37:59 +02:00
Zbigniew Jędrzejewski-Szmek 885a4e6ca7 man: assorted small fixes
This is almost all of #17177.
2020-09-30 10:31:21 +02:00
Zbigniew Jędrzejewski-Szmek 0558f3035f man/systemd.network(5): unify descriptions of MUDURL=
Let's write one good description and refer to it from the other two
spots.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 9e7600cfd7 man: in systemd-nspawn(1), refer to systemd.exec(5) for the shared stuff
We should avoid duplicating lengthy description of very similar concepts.
--root-hash-sig follows the same semantics as RootHashSig=, so just refer
the reader to the other man page. --root-hash doesn't implement the same
features as RootHash=, so we can't fully replace the description, but let's
give the user a hint to look at the other man page too.

For #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 0b4d17c9a5 man: link to fork(2) more prominently
For #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 211c99c761 man: do not index various /foobar/ paths
For #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek ab1a8ff57d man: refer to the right man page for Environment=
For #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 32520ff3de man: reword description of "-" in sysctl.d(5)
For #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 7fd897c51c man: explain why TZ=: is used
Also, reword the description a bit. "As a string" is meaningless in the context
of commandline arguments, where evyrything is a string. This is not a
strongly-typed programming language where 5 is a number but "5" is something
completely different. Here both 5 and "5" are indistinguishable. The original
text was trying to say that a location name should be given and not a number,
so say "time zone location name".

For #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek fa26ff47f7 man: adjustments in file-hierarchy(7)
In table titles, capitalize only the first word (they are rather long and
it is easier to read when it looks like a normal sentence).

Adjust some phrases to make them clearer when reported as unclear in #17177.
2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 21006e0e3e man,units: link to the new dbus-api man pages 2020-09-30 10:30:03 +02:00
Zbigniew Jędrzejewski-Szmek 5ced292d10
Merge pull request #17199 from poettering/log-tid
include thread ID in log output
2020-09-30 10:28:51 +02:00
Lennart Poettering 147a5046aa resolvectl: show resolv.conf mode in resolvectl output 2020-09-30 10:27:51 +02:00
Lennart Poettering 4261ab654c resolved: expose a new bus property that informs about the /etc/resolv.conf mode
It can be one of "foreign", "missing", "stub", "static", "uplink",
depending on how /etc/resolv.conf is set up:

foreign → someone/something else manages /etc/resolv.conf,
    systemd-resolved is just the consumer

missing → /etc/resolv.conf is missing altogether

stub/static/uplink → the file is managed by resolved, with the
    well-known modes

Fixes: #17159
2020-09-30 10:27:50 +02:00
Ronan Pigott 60b254ca1a loginctl: add -P as short for --value --property= 2020-09-30 10:25:06 +02:00
nl6720 bbbfe49b5e sysusers: use "!*" instead of "!!" as an invalid group password
This basically implements fc58c0c7bf for gshadow.
gpasswd may not have a lock/unlock that behaves the same as passwd, but
according to gshadow(5) the logic of the password field is the same.
2020-09-30 10:21:40 +02:00
Lennart Poettering 8e24b1d23f seccomp-util: add cacheflush() syscall to @default syscall set
This is like membarrier() I guess and basically just exposes CPU
functionality via kernel syscall on some archs. Let's whitelist it for
everyone.

Fixes: #17197
2020-09-30 10:08:15 +02:00
RussianNeuroMancer 4796a4fba9 Calendar and micmute hotkeys on HP EliteBook Folio G1
This commit add calendar and micmute hotkeys for HP EliteBook Folio G1, and also correct name of other laptop from HP EliteBook Folio series - HP EliteBook Folio 1040 G2
2020-09-30 09:32:23 +02:00
Ronan Pigott 0fb8f02506 zsh: loginctl: complete alias 'self' 2020-09-30 09:24:03 +02:00
Pass Automated Testing Suite e3820eeaf1 path-lookup: Correct order of XDG_CONFIG_HOME and XDG_CONFIG_DIRS
According to the XDG Base Directory Specification [1] XDG_CONFIG_HOME
should take precedence over XDG_CONFIG_DIRS.

Fixes: https://github.com/systemd/systemd/issues/16095

[1]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
2020-09-29 21:47:01 +02:00
nl6720 f856778b9c docs: update old documentation links 2020-09-29 21:45:06 +02:00
Yu Watanabe 88da55e28b udevadm: do not ignroe error caused by unpriviledged user invoking the command
This effectively reverts commit 67acde4869.

After commits 569ad251ad and
67acde4869, -EACCES errors are ignored,
and thus 'udevadm trigger' succeeds even when it is invoked by non-root
users. Moreover, on -EACCES error, log messages are shown in debug
level, so usually we see no message, and users are easily confused
why uevents for devices are not triggered.
2020-09-29 21:44:10 +02:00
Lennart Poettering 38ffc7d18a log: include TID= field in structred log output
It always was the intention to expose this as trusted field _TID=, i.e.
automatically determine it from journald via some SCM_xyz field or so,
but this is never happened, and it's unlikely this will be added anytime
soon to the kernel either, hence let's just generate this sender side,
even if it means it's untrusted.
2020-09-29 15:51:53 +02:00
Lennart Poettering 9ee806d1a8 log: optionally display thread ID in log output to tty
This is very useful when playing around with threaded tests, but should
be useful in other cases too.
2020-09-29 15:51:53 +02:00
Lennart Poettering a182fa895b
Merge pull request #17194 from poettering/dot-suffix
resolved: turn off search domain logic for queries for dot-suffixed domains
2020-09-29 15:50:06 +02:00
Zbigniew Jędrzejewski-Szmek 8f335169e2
Merge pull request #17190 from poettering/udev-opath
udev: manipulate device nodes with O_PATH
2020-09-29 13:53:41 +02:00
Lennart Poettering 3354f5003c resolved: imply SD_RESOLVED_NO_SEARCH when looking up trailing dot domains
Let's turn off the search domain logic if a trailing dot is specified
when looking up hostnames and RRs via the Varlink + D-Bus APIs (and thus
also when doing so via nss-resolve). (This doesn't affect lookups via
the stub, since for the any search path logic is done client side
anyway)

It might make sense to force the DNS protocol in this case too (and
disable LLMR + mDNS), but we'll leave that for a different PR — if it
even makes sense. It might also make sense to disable the logic of never
routing single-label lookups to the Internet if a trailing to is
specified, but this needs more discussion too.
2020-09-29 12:12:03 +02:00
Lennart Poettering 64c82c25ab dns-domain: add helper that checks whether domain is dot suffixed 2020-09-29 12:09:16 +02:00
Yu Watanabe 3cb7af5baa man: update InitialCongestionWindow= and InitialAdvertisedReceiveWindow=
Fixes #16643.
2020-09-29 16:05:43 +09:00
Anita Zhang 21892cc46b
Merge pull request #17186 from poettering/tmpfiles-cleanup-man-fix
man: fix reference to unit file
2020-09-28 23:48:28 -07:00
Yu Watanabe fef160b5ab network: limit InitialCongestionWindow= and InitialAdvertisedReceiveWindow= value
Strivtly speaking, this breaks backward compatibility. But setting
too large value into them, then their networking easily breaks.
Note that typically 100 for them is event too large. So, ommiting the
values equal or higher than 1024, and dropping support of k, M, and G
suffixes is OK for normal appropriate use cases.

See discussion in #16643.
2020-09-29 13:55:17 +09:00
Lennart Poettering a7fdc6cbd3 udev: apply access mode/ownership to device nodes with O_PATH
Let's open the device node to modify with O_PATH, and then adjust it
only after verifying everything is in order. This fixes a race where the
a device appears, disappears and quickly reappers, while we are still
running the rules for the first appearance: when going by path we'd
possibly adjust half of the old and half of the new node. By O_PATH we
can pin the node while we operate on it, thus removing the race.

Previously, we'd do a superficial racey check if the device node changed
undearneath us, and would propagate EEXIST in that case, failing the
rule set. With this change we'll instead gracefully handle this, exactly
like in the pre-existing case when the device node disappeared in the
meantime.
2020-09-28 18:45:54 +02:00
Lennart Poettering f25bff5eaf fs-util: add new futimens_opath() helper
futimens() that works for O_PATH fds.
2020-09-28 18:45:54 +02:00
Lennart Poettering 9271daeed7 selinux: add apis to set labels/fix labels per fd instead of path 2020-09-28 18:45:54 +02:00