Lennart Poettering [Thu, 4 Jul 2019 16:33:30 +0000 (18:33 +0200)]
userdbd: add new service that can merge userdb queries from multiple clients
Lennart Poettering [Mon, 5 Aug 2019 16:21:49 +0000 (18:21 +0200)]
shared: add helpers for displaying new-style user/group records to users
Lennart Poettering [Wed, 7 Aug 2019 13:26:32 +0000 (15:26 +0200)]
shared: add internal API for querying JSON user records via varlink
This new API can be used in place of NSS by our own internal code if
more than the classic UNIX records are needed.
Lennart Poettering [Mon, 5 Aug 2019 16:21:30 +0000 (18:21 +0200)]
shared: add helpers for converting NSS passwd/group structures to new JSON objects
These new calls may be used to convert classic UNIX/glibc NSS struct
passwd and struct group records into new-style JSON-based user/group
objects.
Lennart Poettering [Wed, 7 Aug 2019 13:25:36 +0000 (15:25 +0200)]
shared: add generic user/group record structures and JSON parsers
Lennart Poettering [Wed, 13 Nov 2019 22:28:05 +0000 (23:28 +0100)]
libcrypt-util: add superficial validator for UNIX hashed password strings
Lennart Poettering [Wed, 13 Nov 2019 22:13:42 +0000 (23:13 +0100)]
shared: split out crypt() specific helpers into its own .c/.h in src/shared/
This way we can use libxcrypt specific functionality such as
crypt_gensalt() and thus take benefit of the newer algorithms libxcrypt
implements. (Also adds support for a new env var $SYSTEMD_CRYPT_PREFIX
which may be used to select the hash algorithm to use for libxcrypt.)
Also, let's move the weird crypt.h inclusion into libcrypt.h so that
there's a single place for it.
Lennart Poettering [Wed, 7 Aug 2019 10:33:33 +0000 (12:33 +0200)]
nss-util: add macros for generating getpwent()/getgrent() prototypes
We have similar macros already for getpwuid()/getpwnam(), let's add more
of this.
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 13:26:39 +0000 (14:26 +0100)]
Merge pull request #14579 from keszybz/docs-index
Revert the test move and fix formatting on main page a bit
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 12:59:11 +0000 (13:59 +0100)]
Merge pull request #14562 from yuwata/table-strv
introduce TABLE_STRV and use it in networkctl and resolvectl
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 12:46:16 +0000 (13:46 +0100)]
docs: fix width of console example
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 12:45:04 +0000 (13:45 +0100)]
Revert "docs: rename HACKING → Hacking"
This reverts commit
8c5cd27dd155fbe71a6bf82096b8775c5ff453b8.
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 12:43:24 +0000 (13:43 +0100)]
Merge pull request #14578 from keszybz/docs-index
Let's see if redirects work
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 11:15:08 +0000 (12:15 +0100)]
docs: rename HACKING → Hacking
Let's see if this works at all.
Zbigniew Jędrzejewski-Szmek [Wed, 15 Jan 2020 10:55:49 +0000 (11:55 +0100)]
docs: shift console log on index page to the left
Lennart Poettering [Wed, 15 Jan 2020 10:46:11 +0000 (11:46 +0100)]
Merge pull request #14424 from poettering/watch-bus-name-rework
pid1: simplify drastically how we watch bus names for service's BusName= setting
Lennart Poettering [Wed, 15 Jan 2020 09:25:06 +0000 (10:25 +0100)]
Merge pull request #14573 from keszybz/docs-index
Docs index
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 20:35:44 +0000 (21:35 +0100)]
docs: add the systemd output example
It is still nice...
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 20:35:24 +0000 (21:35 +0100)]
docs: update old para with links to the blog stories
They are of historical interest, but without links not very useful.
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 20:25:52 +0000 (21:25 +0100)]
docs: remove markup from title
Github uses a different background for backticked text, and this stands out
(in a bad way) on the title page.
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 13:29:02 +0000 (14:29 +0100)]
man: add commas and reword a sentence
On more careful reading, "exit status ... do not cause the unit to enter a
failure state" is not gramatically or logically correct.
Yu Watanabe [Wed, 15 Jan 2020 02:56:01 +0000 (11:56 +0900)]
Merge pull request #14547 from keszybz/networkctl-matching
networkctl: return error or warning when interfaces are not matched
Yu Watanabe [Tue, 14 Jan 2020 10:07:39 +0000 (19:07 +0900)]
test-format-table: add tests for TABLE_STRV
Yu Watanabe [Tue, 14 Jan 2020 09:29:53 +0000 (18:29 +0900)]
resolvectl: use format-table.[ch]
Yu Watanabe [Tue, 14 Jan 2020 09:29:52 +0000 (18:29 +0900)]
networkctl: use TABLE_STRV
Yu Watanabe [Tue, 14 Jan 2020 09:29:51 +0000 (18:29 +0900)]
format-table: introduce TABLE_STRV
Yu Watanabe [Tue, 14 Jan 2020 09:29:50 +0000 (18:29 +0900)]
strv: introduce strv_compare()
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 20:22:13 +0000 (21:22 +0100)]
Merge pull request #14571 from poettering/assorted-fixlets
two minor fixes for recent merges
Lennart Poettering [Tue, 14 Jan 2020 15:53:43 +0000 (16:53 +0100)]
docs: rework HTML into GitHub Markdown table
Presumably this should render better on https://systemd.io/DISCOVERABLE_PARTITIONS then.
As pointed out on: https://github.com/systemd/systemd/pull/14390#issuecomment-
574205631
Lennart Poettering [Tue, 14 Jan 2020 15:32:20 +0000 (16:32 +0100)]
cgroup: minor comment improvement
As pointed out here:
https://github.com/systemd/systemd/pull/14564#discussion_r366305882
Lennart Poettering [Tue, 14 Jan 2020 15:17:38 +0000 (16:17 +0100)]
Merge pull request #14570 from keszybz/resource-docs
Modernize links to cgroups docs
Lennart Poettering [Mon, 6 Jan 2020 19:13:16 +0000 (20:13 +0100)]
logind: refuse overriding idle hint on tty sessions
Previously we'd allow marking TTY sessions as idle, but when the user
tried to unmark it as idle again it we'd just revert to automatic TTY
atime idle detection, thus making it impossible to mark the session as
non-idle, unless its TTY is atime-touched all the time. But of course,
marking a session as idle is pretty much fatal if you never can mark it
as non-idle again.
This change is triggred by bug reports such as this:
https://github.com/systemd/systemd/issues/14053
With this patch we will now output a clean, clear error message if a
client tries to manipulate the idle state of a non-graphical session.
This means we now have clear rules: "manual" idle logic for graphical
sessions, and TTY based ones for all others that have a TTY of some
form.
I considered allowing the idle state to be overriden both ways for tty
sessions but that's problematic: for sessions that are temporarily
upgraded from tty to graphical and thus suddenly want to manage their
own idle state we'd need to a way to detect when the upgrade goes away
and thus we should revert to old behaviour. Without reverting to the
previous TTY idle auto-magic we'd otherwise be stuck in an eternally
idle or eternally non-idle state, with really bad effects in case
auto-suspend is used. Thus, let's instead generate a proper error
message, saying clearly we don't support it.
(Also includes some other fixes and clean-ups in related code)
Closes: #14053
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 14:52:56 +0000 (15:52 +0100)]
Merge pull request #14564 from poettering/cgroup-realize-fix
pid1: cgroup realization fix
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 14:37:53 +0000 (15:37 +0100)]
Merge pull request #14390 from poettering/gpt-var-tmp
introduce GPT partition types for /var and /var/tmp and support them for auto-discovery
Frantisek Sumsal [Fri, 3 Jan 2020 12:01:26 +0000 (13:01 +0100)]
systemctl: use format-table.[ch] for tables
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 13:19:04 +0000 (14:19 +0100)]
Merge pull request #14505 from poettering/refuse-on-failure
refuse OnFailure= deps on units that have no failure state
Zbigniew Jędrzejewski-Szmek [Tue, 14 Jan 2020 12:23:50 +0000 (13:23 +0100)]
Merge pull request #14563 from poettering/less-the-markdown
trivial markdown fixlets
Zbigniew Jędrzejewski-Szmek [Sun, 12 Jan 2020 11:26:26 +0000 (12:26 +0100)]
basic/strv: drop flags argument from strv_fnmatch()
Zbigniew Jędrzejewski-Szmek [Sun, 12 Jan 2020 11:14:31 +0000 (12:14 +0100)]
networkctl: return error or warning when interfaces are not matched
We'd just print nothing and exit with 0. If the user gave an explicit
name, we should fail. If a pattern didn't match, we should at least warn.
$ networkctl status enx54ee75cb1dc0a* --no-pager && echo $?
No interfaces matched.
0
$ networkctl status enx54ee75cb1dc0a --no-pager
Interface "enx54ee75cb1dc0a" not found.
1
Jun'ichi Nomura [Tue, 3 Dec 2019 07:52:02 +0000 (16:52 +0900)]
mount: mark an existing "mounting" unit from /proc/self/mountinfo as "just_mounted"
When starting a mount unit, systemd invokes mount command and moves the
unit's internal state to "mounting". Then it watches for updates of
/proc/self/mountinfo. When the expected mount entry newly appears in
mountinfo, the unit internal state is changed to "mounting-done".
Finally, when systemd finds the mount command has finished, it checks
whether the unit internal state is "mounting-done" and changes the state
to "mounted".
If the state was not "mounting-done" in the last step though mount command
was successfully finished, the unit is marked as "failed" with following
log messages:
Mount process finished, but there is no mount.
Failed with result 'protocol'.
If daemon-reload is done in parallel with starting mount unit, it is
possible that things happen in following order and result in above failure.
1. the mount unit state changes to "mounting"
2. daemon-reload saves the unit state
3. kernel completes the mount and /proc/self/mountinfo is updated
4. daemon-reload restores the saved unit state, that is "mounting"
5. systemd notices the mount command has finished but the unit state
is still "mounting" though it should be "mounting-done"
mount_setup_existing_unit() should take into account that MOUNT_MOUNTING
is transitional state and set MOUNT_PROC_JUST_MOUNTED flag if the unit
comes from /proc/self/mountinfo so that mount_process_proc_self_mountinfo()
later can make state transition from "mounting" to "mounting-done".
Fixes: #10872
Lennart Poettering [Mon, 13 Jan 2020 19:11:56 +0000 (20:11 +0100)]
cgroup: drop redundant if check
Lennart Poettering [Mon, 13 Jan 2020 19:06:39 +0000 (20:06 +0100)]
cgroup: update only siblings that got realized once
Fixes: #14475
Replaces: #14554
Lennart Poettering [Mon, 13 Jan 2020 19:04:58 +0000 (20:04 +0100)]
cgroup: drop unnecessary {}
Lennart Poettering [Mon, 13 Jan 2020 19:04:38 +0000 (20:04 +0100)]
cgroup: no need to cast dev_t to dev_t
Lennart Poettering [Mon, 13 Jan 2020 19:02:01 +0000 (20:02 +0100)]
cgroup: use log_warning_errno() where possible
Lennart Poettering [Tue, 14 Jan 2020 09:14:11 +0000 (10:14 +0100)]
docs: uppercase all markdown document titles
For most we used uppercasing, but not for all. Let's stick to one rule,
and uppercase them all.
Lennart Poettering [Tue, 14 Jan 2020 09:11:19 +0000 (10:11 +0100)]
docs: drop "The" in categorization titles of Markdown documentation
I think it makes sense to keep the "The" in place for the actual page's
title, but let's drop it from the categorization header, to make it
easier to find stuff, as the "The" isn't helpful to that.
In particular as we sometimes do it this and sometimes the other way so
far, hence let's stick to one common rule.
Lennart Poettering [Tue, 14 Jan 2020 09:08:21 +0000 (10:08 +0100)]
Merge pull request #14561 from keszybz/docs-deellipsisize
Doc formatting fixes and link update
Yu Watanabe [Mon, 13 Jan 2020 21:48:57 +0000 (06:48 +0900)]
Merge pull request #14555 from poettering/table-multine
format-table: proper multi-line support
Zbigniew Jędrzejewski-Szmek [Mon, 13 Jan 2020 20:03:15 +0000 (21:03 +0100)]
docs: update link and more dots
Apparently unicode ellipsis is too much for github.
Zbigniew Jędrzejewski-Szmek [Mon, 13 Jan 2020 14:28:25 +0000 (15:28 +0100)]
docs: say that journalctl --flush/--sync also require journald
https://github.com/systemd/systemd/pull/14549#pullrequestreview-
341758182
Zbigniew Jędrzejewski-Szmek [Mon, 13 Jan 2020 19:57:37 +0000 (20:57 +0100)]
Merge pull request #14557 from poettering/root-storage-daemons-markdown
docs: convert root storage daemon doc to markdown
Lennart Poettering [Mon, 13 Jan 2020 17:48:31 +0000 (18:48 +0100)]
docs: import initrd interface documentation from fdo wiki
Imported from https://www.freedesktop.org/wiki/Software/systemd/InitrdInterface/
Lennart Poettering [Mon, 13 Jan 2020 16:09:44 +0000 (17:09 +0100)]
docs: various small fixes to PORTABILITY_AND_STABILITY markdown
Nothing particularly world moving.
Follow-up for #14549
Lennart Poettering [Mon, 13 Jan 2020 17:53:46 +0000 (18:53 +0100)]
killall: update reference to root storage daemon interface docs
Lennart Poettering [Mon, 13 Jan 2020 17:33:18 +0000 (18:33 +0100)]
docs: convert root storage daemon doc to markdown
Import from:
https://www.freedesktop.org/wiki/Software/systemd/RootStorageDaemons/
Lennart Poettering [Mon, 13 Jan 2020 17:03:13 +0000 (18:03 +0100)]
Merge pull request #14400 from keszybz/alias-check
Alias check rework
Lennart Poettering [Mon, 13 Jan 2020 16:57:59 +0000 (17:57 +0100)]
Merge pull request #14381 from keszybz/ifindex-cleanup
Resolve alternative names
Lennart Poettering [Mon, 13 Jan 2020 16:44:34 +0000 (17:44 +0100)]
Merge pull request #11199 from dargad/restore-pam-setcred
Restore call to pam_setcred
Lennart Poettering [Mon, 13 Jan 2020 16:42:55 +0000 (17:42 +0100)]
Merge pull request #14293 from keur/systemctl_with_dependencies
systemctl: Add --with-dependencies switch
Zeyu DONG [Fri, 10 Jan 2020 12:11:48 +0000 (20:11 +0800)]
hwdb: Entry for Lenovo Ideapad 310S-14ISK Alps Touchpad
Add the resolution and range information for Lenovo Ideapad 310S-14ISK Alps touchpad. It provides information for the test case of libinput for Alps devices.
Timo Schlüßler [Mon, 13 Jan 2020 09:26:58 +0000 (09:26 +0000)]
journalctl: Correctly handle combination of --reverse and --lines (fixes #1596)
Timo Schlüßler [Mon, 13 Jan 2020 09:09:45 +0000 (09:09 +0000)]
journalctl: Correctly handle --show-cursor in combination with --until or --since and --reverse
Lennart Poettering [Mon, 13 Jan 2020 15:47:15 +0000 (16:47 +0100)]
Merge pull request #14532 from poettering/namespace-dynamic-user-fix
Make DynamicUser=1 work in a userns container
Lennart Poettering [Mon, 13 Jan 2020 15:27:03 +0000 (16:27 +0100)]
man: suffix parameter with = in our documentation, if it expects an argument
Also, don't claim we'd insert a "," between addresses, because we
actually don't do that.
Lennart Poettering [Mon, 13 Jan 2020 15:20:53 +0000 (16:20 +0100)]
machinectl: modernize address table handling
Primarily, use the new multi-line support in table formatting.
Also, stream-line naming of the "max-addresses" options. We used three
names for the concept internall, let's just unify on the name we use for
this for external users, i.e. "max-addresses".
Lennart Poettering [Mon, 13 Jan 2020 10:20:02 +0000 (11:20 +0100)]
format-table: natively support multiline cells
This adds native support for multiline cells.
Lennart Poettering [Mon, 13 Jan 2020 15:20:27 +0000 (16:20 +0100)]
string-util: add helper for extracting n'th line of a string
Lennart Poettering [Mon, 13 Jan 2020 15:07:06 +0000 (16:07 +0100)]
string-util: let's add helper for truncating string after a specified number of lines
Zbigniew Jędrzejewski-Szmek [Mon, 13 Jan 2020 14:35:54 +0000 (15:35 +0100)]
Merge pull request #14553 from poettering/man-mkdir
man: small man page fixes
Lennart Poettering [Mon, 13 Jan 2020 10:45:48 +0000 (11:45 +0100)]
Merge pull request #14549 from keszybz/portability-and-stability
Portability and stability
Lennart Poettering [Mon, 13 Jan 2020 10:23:14 +0000 (11:23 +0100)]
man: we support bind mounting regular files too
Let's be precise here: we accept non-directories here too, even though
we create things as directories if we find the Where= not to exist.
Lennart Poettering [Mon, 13 Jan 2020 10:22:11 +0000 (11:22 +0100)]
man: document that we mkdir() on What= in .mount units too
As suggested here:
https://lists.freedesktop.org/archives/systemd-devel/2020-January/043914.html
Dariusz Gadomski [Wed, 8 Jan 2020 15:25:15 +0000 (16:25 +0100)]
test: Add tests for gid list ops
Dariusz Gadomski [Wed, 8 Jan 2020 15:24:45 +0000 (16:24 +0100)]
execute: Detect groups added by PAM and merge them with supplementary groups
Dariusz Gadomski [Wed, 8 Jan 2020 15:24:11 +0000 (16:24 +0100)]
execute: Restore call to pam_setcred
Dariusz Gadomski [Wed, 8 Jan 2020 15:22:29 +0000 (16:22 +0100)]
user-util: Add helper functions for gid lists operations
Zbigniew Jędrzejewski-Szmek [Sun, 12 Jan 2020 18:03:32 +0000 (19:03 +0100)]
docs: say that various cli progs are independent of pid1
Zbigniew Jędrzejewski-Szmek [Sun, 12 Jan 2020 17:32:40 +0000 (18:32 +0100)]
docs: say that dbus api is stable (but list various caveats)
I removed the part about sysv compat, because that has already been removed and
we don't make any use of conditional dbus interfaces afaict.
Zbigniew Jędrzejewski-Szmek [Sun, 12 Jan 2020 17:17:50 +0000 (18:17 +0100)]
docs: say that all documented programs in $PATH are stable
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 18:34:29 +0000 (19:34 +0100)]
docs: import "interface stability promise"
In the wiki, this was a separate page. I don't think this split is useful,
since the information about what is stable and what not seems randomly split
between the two pages.
Links are adjusted for our own pages. Some external links to gentoo and other
projects seem to be broken, but it's a chore to fix them.
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 11:36:21 +0000 (12:36 +0100)]
networkctl: break long line
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 11:33:24 +0000 (12:33 +0100)]
machinectl: reduce scope of iterator variables
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 10:37:26 +0000 (11:37 +0100)]
resolvectl: minor optimizations to allocate less
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 10:21:01 +0000 (11:21 +0100)]
Resolve alternative ifnames wherever we would resolve an interface name
To keep the names manageable, "ifname_or_ifindex" is replaced by "interface".
Zbigniew Jędrzejewski-Szmek [Fri, 10 Jan 2020 20:18:31 +0000 (21:18 +0100)]
util-lib: add function to resolve "alternative" names
Calls to if_nametoindex() are expected to use resolve_ifname() instead.
Yu Watanabe [Sun, 12 Jan 2020 07:01:25 +0000 (16:01 +0900)]
man: XxxRate= are in bps
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 18:20:35 +0000 (19:20 +0100)]
docs/stability: relax the stance on accepting patches a bit
Instead of saying that patches for portability are not accepted, say that this
is decided case-by-case. This is what happens in practice, and we tend to
discuss each patch on its own merits.
Some sentences are reworded a bit where they sound awkward.
Zbigniew Jędrzejewski-Szmek [Sat, 11 Jan 2020 17:47:26 +0000 (18:47 +0100)]
docs: import stability chart from wiki
Zbigniew Jędrzejewski-Szmek [Fri, 10 Jan 2020 16:22:37 +0000 (17:22 +0100)]
util-lib: move things that parse ifnames to shared/
In subsequent commits, calls to if_nametoindex() will be replaced by a wrapper
that falls back to alternative name resolution over netlink. netlink support
requires libsystemd (for sd-netlink), and we don't want to add any functions
that require netlink in basic/. So stuff that calls if_nametoindex() for user
supplied interface names, and everything that depends on that, needs to be
moved.
Zbigniew Jędrzejewski-Szmek [Fri, 10 Jan 2020 15:51:29 +0000 (16:51 +0100)]
basic/socket-util: indent for clarity
Zbigniew Jędrzejewski-Szmek [Fri, 10 Jan 2020 15:32:27 +0000 (16:32 +0100)]
sd-netlink: do not require rtnl pointer to be passed
Zbigniew Jędrzejewski-Szmek [Wed, 18 Dec 2019 13:18:34 +0000 (14:18 +0100)]
networkctl: define a helper for interface name resolution
Zbigniew Jędrzejewski-Szmek [Wed, 18 Dec 2019 12:57:01 +0000 (13:57 +0100)]
timedatectl: drop ifindex output parameter too
Zbigniew Jędrzejewski-Szmek [Wed, 18 Dec 2019 12:54:13 +0000 (13:54 +0100)]
tree-wide: make parse_ifindex simply return the index
We don't need a seperate output parameter that is of type int. glibc() says
that the type is "unsigned", but the kernel thinks it's "int". And the
"alternative names" interface also uses ints. So let's standarize on ints,
since it's clearly not realisitic to have interface numbers in the upper half
of unsigned int range.
rhn [Fri, 10 Jan 2020 23:08:00 +0000 (23:08 +0000)]
nspawn: Correct "container" to "host" MAC setting message
Lennart Poettering [Fri, 10 Jan 2020 16:06:16 +0000 (17:06 +0100)]
Merge pull request #14533 from poettering/swap-prio-fixes
Fix Priority= parsing in .swap units
Lennart Poettering [Fri, 10 Jan 2020 16:03:01 +0000 (17:03 +0100)]
Merge pull request #14508 from poettering/namespace-ro-fix
core: be nicer to read-only images
Lennart Poettering [Fri, 10 Jan 2020 15:40:31 +0000 (16:40 +0100)]
Merge pull request #14538 from yuwata/xyzctl-full
use table_set_width(table, 0) if --full is specified
Zbigniew Jędrzejewski-Szmek [Thu, 9 Jan 2020 11:38:18 +0000 (12:38 +0100)]
man: document alias rules and aliases dropin loading