Commit graph

6204 commits

Author SHA1 Message Date
Daniel Mack 5a884f93fd libsystemd-bus: match on any connection ID unless specified 2013-12-20 23:12:42 +01:00
Daniel Mack 73842d62d7 libsystemd-bus: follow changes in kdbus
In particular, the match interface has seen a major overhaul.
2013-12-20 20:57:20 +01:00
Lennart Poettering f7cf00fa51 def: lower exit-on-idle time 2013-12-19 22:18:39 +01:00
Lennart Poettering ff0031069f sd-event: return 1 in sd_event_run() when we hit EINTR
That way we can distuingish timeouts from EINTR
2013-12-19 22:18:39 +01:00
Lennart Poettering 30b5275ac7 service: don't send out PropertiesChanged message for each watchdog notification 2013-12-19 22:18:39 +01:00
Lennart Poettering d9e34bfda3 machined: implement exit-on-idle 2013-12-19 22:18:39 +01:00
Lennart Poettering 37224a5ff5 bus: fix exit-on-idle for driverd 2013-12-19 22:18:39 +01:00
Lennart Poettering ff2ea19264 bus: reenable id change subscriptions 2013-12-19 22:18:39 +01:00
Thomas Hindoe Paaboel Andersen 051dfe8708 remove unused variable 2013-12-19 22:06:47 +01:00
Tom Gundersen 4d47756b8f rtnl: correctly get the size of data to be appended
This fixes:
  systemd[1]: Failed to configure loopback device: Numerical result out of range
2013-12-19 21:39:45 +01:00
Tom Gundersen 753e98788a loopback-setup: correctly set flags and scope for ipv6 address 2013-12-19 21:39:45 +01:00
Kay Sievers 8da4de0376 bus: do not add empty strings, size should be 0 2013-12-19 06:56:53 +01:00
Zbigniew Jędrzejewski-Szmek a669d6226d systemct: add empty line between units in cat 2013-12-18 23:58:24 -05:00
Djalal Harouni 495cb9bbeb loginctl: improve print_{session|user|seat}_status_info() functions
1) Instead of checking if we need to print a new line on each iteration,
pass the "new_line" as a pointer to those functions, so they can use
it to check if a new line is needed. This makes the code more consistent
as it is done in other places: machinectl, systemctl...

2) Move the error messages from show_{session|user|seat}() to their
appropriate print_{session|user|seat}_status_info() functions, this will
prevent from logging an error message twice in case show_properties()
fails and it will improve code readability.

3) Also do not ignore error codes on these functions.
2013-12-18 23:58:24 -05:00
Djalal Harouni 97aa7b4781 loginctl: use show_properties() to get login1 properties
Commit f8f14b3654 introduced a regression that makes loginctl ignore
the "--property" option.

This patch fixes the bug, it uses a new show_properties() function to
query and filter properties.
2013-12-18 23:58:24 -05:00
Djalal Harouni 1c3051eba4 loginctl: replace strv_append() by strv_extend() 2013-12-18 23:58:24 -05:00
Jason St. John c736283bfb journalctl,zsh-completion: fix several issues in --help message text
-- fix grammar and reword some descriptions for clarity
-- add a useful description of what --follow does
-- fix the description for --after-cursor
-- properly introduce the FSS acronym for "Forward Secure Sealing" in
both sections
-- clarify the --disk-usage command

[zj: perform similar changes to zsh completions]

squash! journalctl: fix several issues in --help message text
2013-12-18 23:58:24 -05:00
Djalal Harouni 8c841f21f5 machinectl: show_properties() already logs the error 2013-12-18 23:58:23 -05:00
Zbigniew Jędrzejewski-Szmek 44433ebdb1 udevadm: modernization 2013-12-18 23:58:23 -05:00
Zbigniew Jędrzejewski-Szmek 7643ac9a8a udevadm,scsi_id: add short options to help strings and to the man page
Also clean things up a bit here and there.
2013-12-18 23:58:23 -05:00
Zbigniew Jędrzejewski-Szmek ed142bdb68 scsi_id: cleanup
Remove -i option which would case exit(1) to happen.
Remove some unused code.
Convert to bool where appropriate.
Simplify things a bit.
Always free everything.

https://bugzilla.redhat.com/show_bug.cgi?id=1043304
2013-12-18 23:58:23 -05:00
Lennart Poettering 53461b74df driverd: implement AddMatch/RemoveMatch logic 2013-12-19 04:40:56 +01:00
Kay Sievers b43b8f7a7e do not run kmod-setup in a container 2013-12-19 01:32:55 +01:00
Kay Sievers 7491e6e7c5 temporarily support "kdbus" keyword on the kernel commandline to load the module 2013-12-18 23:56:35 +01:00
Kay Sievers e8a3b2dcfb libudev: monitor - only disallow "udev" type events 2013-12-18 22:30:26 +01:00
Kay Sievers df32a1caaf libudev: disable monitor inside a container
Uevents are events of the host, which should not leak into a container.
Containers do not support hotplug at the moment, and devices and uevents
are not namespace aware.
2013-12-18 22:01:31 +01:00
Kay Sievers ec76ec1fde bus: catch up with kdbus changes 2013-12-18 21:16:35 +01:00
Lukasz Skalski 3e8a51eae6 bus-driverd: fix flags translation in driver_request_name
Flags for a name entry (KDBUS_NAME_*) should be set for
cmd_name->flags (not conn_flags)
2013-12-18 19:32:58 +01:00
Lennart Poettering 8674debc67 Revert "ptyfwd: make master terminal attributes raw, too"
This reverts commit e7d43b3cc3.

This broke the console terminal when booting up a container, so let's
not do this.
2013-12-18 19:26:10 +01:00
Lennart Poettering 8e959fbf38 bus: reduce calls to KDBUS_CMD_MEMFD_SIZE_SET ioctl
Instead of calling it for each buffer append, increase allocation
exponentially and set the real value only at the end, when sealing off
the memfd.

This should drastically reduce the number of times we invoke the
ioctl().
2013-12-18 19:04:14 +01:00
Lennart Poettering e7d43b3cc3 ptyfwd: make master terminal attributes raw, too 2013-12-18 18:21:28 +01:00
Lennart Poettering 7cae38c4fa execute: set TERM even if we don't open the tty on our own
This way, when a tty path is configured TERM is set, which is nice to
set a useful term for gettys.
2013-12-18 18:21:28 +01:00
Lennart Poettering ddae67fa1b loginctl: when showing device tree of seats with no devices show something useful 2013-12-18 18:21:28 +01:00
Lennart Poettering 06acf2d46a core,logind: libudev usage modernizations
Always use cleanup logic and don't eat up errors returned by libudev
2013-12-18 18:21:28 +01:00
Lennart Poettering e120204729 core,logind,networkd: check for udev device initialization via enumeration matches
Instead of checking each device after we got it, check wuth an
enumeration filter instead, to make it more efficient.
2013-12-18 18:21:28 +01:00
Lennart Poettering fa28bc2df7 core: priorize notification fd processing over notification fd process via sd-event's logic 2013-12-18 18:21:27 +01:00
Lennart Poettering 0e6eaa2d98 log: when we log to /dev/console and got disconnected (maybe due to vhangup) reconnect 2013-12-18 18:21:27 +01:00
Lennart Poettering 220ec97ad6 core: in a container log to /dev/console if "debug" is specified 2013-12-18 18:21:27 +01:00
Lennart Poettering 99f098257f log: don't reopen /dev/console each time we call log_open()
Instead, force reopen it only if we really really have to.
2013-12-18 18:21:27 +01:00
Lennart Poettering bf108e5541 service: watch main pid even in final states
In some circumstances, for example when start-up times out we
immediately jump into the final state, at which point we still should
try to watch the main pid so that the SIGCHLD allows us to quickly
move into dead state.
2013-12-18 18:21:27 +01:00
Kay Sievers f6613dd959 libudev: devices received from udev are always initialized 2013-12-18 17:34:22 +01:00
Thomas Bächler 63966da86d login: Don't stop a running user manager from garbage-collecting the user.
With the current logic, a user will never be garbage-collected, since its
manager will always be around. Change the logic such that a user is
garbage-collected when it has no sessions and linger is disabled.
2013-12-18 10:57:13 +01:00
Kay Sievers 48b9cfcb7c comment out udev's is_initialized call until the problem is sorted out 2013-12-18 05:07:16 +01:00
Lennart Poettering bf5332d2bf core,logind,networkd: don't pick up devices from udev before they finished udev initialization
Managers shouldn't pick up the devices the manage before udev finished
initialization, hence check explicitly for that.
2013-12-18 03:37:26 +01:00
Lennart Poettering 5e2f14e62b busctl: output a single sorted list of names, including activatable and activated 2013-12-18 02:54:16 +01:00
Lennart Poettering 71ebe743a0 bus: beef up driverd
Add validity checks for all parameters passed in.

Implement ReleaseName and StartServiceByName().

Fix access control in vtable.
2013-12-18 02:54:16 +01:00
Lennart Poettering 45fd5e4d08 bus: when releasing, taking, listing bus names check if they are valid
Given that the kernel does not validate bus names we have to when using
them.
2013-12-18 02:54:16 +01:00
Lennart Poettering 23c3a89b89 tests: fix build 2013-12-18 02:54:16 +01:00
Daniel Mack ceceaf09f9 bus: sync with kdbus
Two new things here:

a) struct kdbus_notify_name_change now carries two struct
   kdbus_notify_id_change

b) a new KDBUS_CMD_BYEBYE ioctl that has no user yet in systemd
2013-12-18 00:20:55 +01:00
Tom Gundersen d638dee035 networkd: bridge - fix state machine
We were entering BRIDGE_STATE_CREATED rather than BRIDGE_STATE_READY.
2013-12-17 22:08:12 +01:00