summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* logind: when a bus call is done on a session, user or seat, optionally ↵Lennart Poettering2015-01-095-100/+182
| | | | | | | | | | determine them from the caller credentials More specifically, if an operation is requested on a session with an empty name, the caller's session is used. If an operation is requested on a seat with an empty name, the seat of the caller's session is used. Finally, if an operation on the user with UID -1 is requested, the user of the client's session is used (and not the UID of the client!).
* logind: include "self" object links in dbus introspectionLennart Poettering2015-01-093-0/+12
| | | | Makes "busctl introspect" a lot more fun.
* loginctl: make "loginctl session-status" without session ID show the ↵Lennart Poettering2015-01-091-14/+24
| | | | | | caller's session status Similar for user-status and seat-status.
* core: modernize execution code a bitLennart Poettering2015-01-091-198/+198
| | | | | | | | | | | | Among other things, avoid log_struct() unless we really need it. Also, use "r" as variable to store function errors in, instead of "err". "r" is pretty much what we use everywhere else, hence using the same here make sense. FInally, in the child, when we want to log, make sure to open the logging framework first, since it is explicitly closed in preparation for the exec().
* journal: do not check for number of filesZbigniew Jędrzejewski-Szmek2015-01-091-7/+0
| | | | | | | Now that we bump rlimit, we do not really know how many files we can open. Remove the check. https://bugzilla.redhat.com/show_bug.cgi?id=1179980
* systemctl: add missing output modes to help messageRonny Chevalier2015-01-091-2/+3
|
* bus: append bloom-filter to all signalsDavid Herrmann2015-01-091-1/+1
| | | | | Make sure to append bloom-filters to all signal-messages, not only broadcasts.
* core: check both EPERM and EACCES for OOM adjustmentsLennart Poettering2015-01-081-1/+1
|
* core: make EPERM errors when applying OOM adjustment for forked processes ↵Lennart Poettering2015-01-081-4/+8
| | | | | | non-fatal This should be useful for user namespaces.
* loginctl: port to generic verbs.h APILennart Poettering2015-01-082-182/+145
|
* machined: when cloning a raw disk image, also set the NOCOW flagLennart Poettering2015-01-087-10/+20
|
* man: bring machinectl man page up-to-dateLennart Poettering2015-01-081-1/+1
|
* man: bring systemctl man page and --help text into the same orderLennart Poettering2015-01-081-4/+3
|
* systemctl,loginctl: start polkit agent for all polkit enabled operationsLennart Poettering2015-01-083-4/+33
|
* machinectl: given that machinectl invokes a number of polkit enabled ↵Lennart Poettering2015-01-081-4/+45
| | | | methods, start the polkit agent on terminals
* machinectl: show most recent log output in "machinectl status", tooLennart Poettering2015-01-082-22/+68
|
* loginctl: show the 10 most recent log user/session log lines in "loginctl ↵Lennart Poettering2015-01-084-70/+128
| | | | user-status" and "loginctl session-status"
* cryptsetup: support header= optionAndrey Chaser2015-01-081-3/+41
| | | | https://bugs.freedesktop.org/show_bug.cgi?id=66396
* test-verbs: add unit tests for verbs minilibDave Reisner2015-01-081-0/+78
|
* bus-proxyd: fix EPERM on repliesDavid Herrmann2015-01-081-9/+24
| | | | | | | | | | | | | | | | | | Imagine a kdbus peer sending a method-call without EXPECT_REPLY set through the proxy to a dbus1 peer. The proxy turns the missing EXPECT_REPLY flag into a dbus1 NO_REPLY_EXPECTED flag. However, if the receipient ignores that flag (valid dbus1 behavior) and sends a reply, the proxy will try to forward it to the original peer. This will fail with EPERM as the kernel didn't track the reply. We have two options now: Either we ignore EPERM for reply messages, or we track reply-windows in the proxy so we can properly ignore replies if EXPECT_REPLY wasn't set. This commit chose the first option: ignore EPERM for replies. The only down-side is that replies without matching method call will no longer be forwarded by the proxy. This works on dbus1, though. Nobody sane does this, so lets ignore it.
* bus-proxyd: optimize replies if they're not requestedDavid Herrmann2015-01-081-0/+3
| | | | | | | If a caller does not request a reply, dont send it. This skips message creation and speeds up NO_REPLY_EXPECTED cases. Note that sd-bus still handles this case internally, but if we handle it in bus-proxyd, we can skip the whole message creation step.
* bus-proxy: augment credentials from /proc for cmdline updateDavid Herrmann2015-01-081-1/+1
| | | | | | | | | | dbus1 does not provide cmdline, so we have to augment our credentials from /proc to beautify the bus-proxyd cmdline. We dont use this for anything but beautification, so there shouldn't be any problems due to /proc pid-recycling races. This fixes bus-proxyd to no longer display 'xxxxxxxxxxxxxxxxxxxxxxxxxxx' in its cmdline.
* nspawn: fix error message when mknod failsTom Gundersen2015-01-081-1/+1
|
* path-util: plug leakTom Gundersen2015-01-081-0/+3
|
* dbus1-generator: fix array sentinalDavid Herrmann2015-01-081-0/+1
| | | | | Add a {} sentinal entry so the config-iterator can properly iterate all array elements. Fixes a segfault in the dbus1-generator.
* sd-bus: fix copy-paste errorLukasz Skalski2015-01-081-1/+1
|
* journal: bump RLIMIT_NOFILE when journal files to 16K (if possible)Lennart Poettering2015-01-083-0/+12
| | | | | | | | | | | When there are a lot of split out journal files, we might run out of fds quicker then we want. Hence: bump RLIMIT_NOFILE to 16K if possible. Do these even for journalctl. On Fedora the soft RLIMIT_NOFILE is at 1K, the hard at 4K by default for normal user processes, this code hence bumps this up for users to 4K. https://bugzilla.redhat.com/show_bug.cgi?id=1179980
* udevadm: don't hit an assert when obsolete parameters are passedLennart Poettering2015-01-081-4/+15
| | | | https://bugzilla.redhat.com/show_bug.cgi?id=1178051
* util: make it easy to initialize the crtime from the current time in ↵Lennart Poettering2015-01-082-1/+4
| | | | fd_setcrtime()
* import: also set NOCOW for gpt disk imagesLennart Poettering2015-01-081-1/+10
| | | | | | | Given the write patterns on disk images, we better should turn COW off for them. In particular as the file systems used inside the disk images should do their own data integrity checks anyway and we don't need multiple layers of it.
* journald: turn off COW for journal files on btrfsLennart Poettering2015-01-084-10/+66
| | | | | | | | | | | | | | btrfs' COW logic results in heavily fragment journal files, which is detrimental for perfomance. Hence, turn off COW for journal files as we create them. Turning off COW comes at the cost of data integrity guarantees, but this should be acceptable, given that we do our own checksumming, and generally have a pretty conservative write pattern. Also see discussion on linux-btrfs: http://www.spinics.net/lists/linux-btrfs/msg41001.html
* util: upgrade default $TERM from vt102 to vt220 if we have no idea about the ↵Lennart Poettering2015-01-071-1/+1
| | | | | | | | | | | | | | | | | connected terminal So far, if we had no knowledge about the correct $TERM we defaulted to v102, as a safe, conservative choice. However, the terminfo data for vt102 is not aware of pageup/pagedown, which makes "less" much harder work with than necessary. Setting vt220 allows them to work correctly. "vt220" should be a sufficiently safe choice too, given that xterm, gnome-terminal and the linux console all strive to implement vt220 as baseline, already to pass pageup/pagedown correctly to apps. Effectively, with this change "journalctl -e" run inside a "systemd-nspawn" terminal will now run a pager where pageup/pagedown works, which is quite an improvement of usability for containers.
* bus-util: fix error number output when waiting for jobLennart Poettering2015-01-071-0/+1
|
* service: automatically create After= dependency from services to their ↵Lennart Poettering2015-01-071-46/+65
| | | | .busname units, if BusName= is set
* conf-parse: don't accept invalid bus names as BusName= arguments in service ↵Lennart Poettering2015-01-073-58/+92
| | | | units
* conf-parse: make syntax logging functions behave more like other log functonsLennart Poettering2015-01-072-7/+8
| | | | | | | In particular, don't patch the error number to EINVAL if 0, and don't negate it. (Also, add do {} while (false) around multi-line macro)
* busctl: exit cleanly when the bus connection is severedLennart Poettering2015-01-071-0/+8
|
* sd-bus: when we synthesize messages, initialize timestamps ourselvesLennart Poettering2015-01-071-1/+15
|
* sd-bus: unify how we set the sender of synthetic messagesLennart Poettering2015-01-074-21/+23
|
* sd-bus: make use of the newly added timestamps on kdbus kernel messagesLennart Poettering2015-01-071-18/+52
|
* sd-bus: always catch name requests for the special names ↵Lennart Poettering2015-01-072-4/+14
| | | | "org.freedesktop.DBus" and "org.freedesktop.DBus.Local" and refuse them
* machinectl: prettify "machinectl list" outputLennart Poettering2015-01-071-8/+52
|
* sysv-generator: initialize units before use to ensure correct orderingMichael Biebl2015-01-071-4/+4
| | | | | | | | | | | | | | The original loop called fix_order() on each service immediately after loading it, but fix_order() would reference other units which were not loaded yet. This resulted in bogus and unnecessary orderings based on the static start priorities. Therefore call load_sysv() for every init script when traversing them in enumerate_sysv(). This ensures that all units are loaded when fix_order() is called. Bug-Debian: https://bugs.debian.org/771118
* ptyfwd: simplify how we handle vhangups a bitLennart Poettering2015-01-073-39/+28
|
* btrfs-util: rework how we iterate through the results of the TREE_SEARCH resultsLennart Poettering2015-01-071-32/+95
| | | | | Let's introduce some syntactic sugar with iteration macros, and add correct key increment calls.
* sysv-generator: handle Provides: for non-virtual facility namesMichael Biebl2015-01-071-1/+24
| | | | | | | | | | | | | | | | | | | | The list of provided facility names as specified via Provides: in the LSB header was originally implemented by adding those facilities to the Names= property via unit_add_name(). In commit 95ed3294c632f5606327149f10cef1eb34422862 the internal SysV support was replaced by a generator and support for parsing the Names= option had been removed from the unit file parsing in v186. As a result, Provides: for non-virtual facility was dropped when introducing the sysv-generator. Since quite a few SysV init scripts still use that functionality (at least in distros like Debian which have a large body of SysV init scripts), add back support by making those facility names available via symlinks to the unit filename to ensure correct orderings between SysV init scripts which use those facility names. Bug-Debian: https://bugs.debian.org/774335
* machinectl: make sure that "machinectl login" exits immediately when the ↵Lennart Poettering2015-01-075-16/+104
| | | | machine it is connected to dies
* util: make use of kcmp() to compare fds, if it is availableLennart Poettering2015-01-073-4/+89
|
* util: don't fail recursive bind mounting if we cannot read the mount flags ↵Lennart Poettering2015-01-071-6/+9
| | | | from an obstructed mounted
* core: implement serialization/deserialization of fd store elementsLennart Poettering2015-01-071-71/+112
|