[systemd-devel] [PATCH] machine_kill(): Don't kill the unit when killing the leader

2014-08-14 Thread Eelco Dolstra
If "machinectl poweroff" or "machinectl reboot" is used on a systemd-nspawn container started with --keep-unit and --register, it should *only* send the appropriate signal to the leader PID (i.e. the container's systemd process). It shouldn't fall through to manager_kill_unit() to also send the sig

[systemd-devel] [PATCH] Fix off-by-one error in "Missed X kernel messages" warning

2014-08-06 Thread Eelco Dolstra
On receiving a message, "kernel_seqnum" is set to "serial + 1". So subtracting 1 will cause messages like "Missed 0 kernel messages", which should be "Missed 1 kernel messages". --- src/journal/journald-kmsg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/journal/journald

Re: [systemd-devel] [PATCH 17/17] networkd: add dhcp server support

2014-05-27 Thread Eelco Dolstra
s another person's essential feature.) For instance, networkd currently lacks a WPA supplicant, which you surely need in a modern system. So should systemd accrete a WPA supplicant? How about Bluetooth support? Etc. etc. I mean, is there any concrete criterion about what should or shouldn't go

Re: [systemd-devel] systemd-notify --ready is not reliable

2014-05-20 Thread Eelco Dolstra
over the current situation :-) -- Eelco Dolstra | LogicBlox, Inc. | http://nixos.org/~eelco/ ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel

[systemd-devel] [PATCH] Fix typos in systemctl manpage

2014-05-15 Thread Eelco Dolstra
--- man/systemctl.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/man/systemctl.xml b/man/systemctl.xml index 94f2380..29ab95f 100644 --- a/man/systemctl.xml +++ b/man/systemctl.xml @@ -435,7 +435,7 @@ along with systemd; If not, see .

[systemd-devel] systemd-notify --ready is not reliable

2014-04-23 Thread Eelco Dolstra
use systemd-notify. Not an ideal solution :-) What do you think? -- Eelco Dolstra | LogicBlox, Inc. | http://nixos.org/~eelco/ ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Re: [systemd-devel] [PATCH] Handle Unix domain socket connections from outside our namespace

2014-04-19 Thread Eelco Dolstra
at src/core/socket.c:684, function >> instance_from_socket(). Aborting. >> systemd[1]: Caught , dumped core as pid 336. >> systemd[1]: Freezing execution. > Yikes. I admit I didn't boot the machine with it... sorry. When you tweaked my commit you dropped the "break;"

[systemd-devel] [PATCH] Handle Unix domain socket connections from outside our namespace

2014-04-16 Thread Eelco Dolstra
NixOS uses Unix domain sockets for certain host <-> container interaction; i.e. the host connects to a socket visible in the container's directory tree, where the container uses a .socket unit to spawn the handler program on demand. This worked in systemd 203, but in 212 fails with "foo.socket fail

[systemd-devel] [PATCH] Fix obsolete references to systemd-random-seed-load.service

2013-09-22 Thread Eelco Dolstra
This service was merged with systemd-random-seed-save.service in c35b956d34bbb8bb208e49e45de2c103ca11911c. --- src/cryptsetup/cryptsetup-generator.c | 2 +- units/systemd-random-seed.service.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cryptsetup/cryptsetup-genera

[systemd-devel] [PATCH] Fix CPUShares configuration option

2013-05-24 Thread Eelco Dolstra
This fixes the error message "Unknown or unsupported cgroup attribute CPUShares". --- src/core/cgroup-semantics.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/cgroup-semantics.c b/src/core/cgroup-semantics.c index 82b02bb..7df9d01 100644 --- a/src/core/cgroup-semant

[systemd-devel] [PATCH] Start ctrl-alt-del.target irreversibly

2013-05-07 Thread Eelco Dolstra
This makes ctrl-alt-del reboots more robust, just like "systemctl reboot". --- src/core/manager.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/manager.c b/src/core/manager.c index c7f8f20..0508628 100644 --- a/src/core/manager.c +++ b/src/core/manager.c @@ -1372,7 +

[systemd-devel] [PATCH] systemd-sysctl: Handle missing /etc/sysctl.conf properly

2013-03-27 Thread Eelco Dolstra
Since fabe5c0e5fce730aa66e10a9c4f9fdd443d7aeda, systemd-sysctl returns a non-zero exit code if /etc/sysctl.conf does not exist, due to a broken ENOENT check. --- src/sysctl/sysctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sysctl/sysctl.c b/src/sysctl/sysctl.c index

Re: [systemd-devel] [PATCH 1/2] Ignore IPv6 link-local addresses

2013-02-04 Thread Eelco Dolstra
is probably caused by this. There was a Glibc bug about this: http://sourceware.org/bugzilla/show_bug.cgi?id=12714 However, even with Glibc 2.17 (which should have the patch provided there), getaddrinfo() with AF_INET6 still returns a zero scopeid. Will investigate further... -- Eelco Dolstra

[systemd-devel] [PATCH 2/2] Fix a segfault in nscd when using nss-myhostname

2013-02-04 Thread Eelco Dolstra
Nscd expects that an NSS module's gethostbyname4_r function returns its first result in the pre-allocated gaih_addrtuple denoted by **pat. (See nscd/aicache.c in the Glibc sources.) However, nss-myhostname doesn't fill in **pat but allocates the first result in ‘buffer’, then sets *pat. So nscd c

[systemd-devel] [PATCH 1/2] Ignore IPv6 link-local addresses

2013-02-04 Thread Eelco Dolstra
Returning IPv6 link-local addresses is a bad idea, because they only work if an application connects specifically over the corresponding interface. So you get errors like: $ curl -6 http://my-machine/ curl: (7) Failed to connect to fe80::d6be:d9ff:fe1b:8477: Invalid argument To prevent this,

[systemd-devel] [PATCH] Fix some typos

2013-01-20 Thread Eelco Dolstra
--- man/systemd.service.xml | 2 +- src/core/manager.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/man/systemd.service.xml b/man/systemd.service.xml index f7cbbb4..891b347 100644 --- a/man/systemd.service.xml +++ b/man/systemd.service.xml @@ -745,7 +745,7 @@

Re: [systemd-devel] merge nss-myhostname into systemd

2013-01-07 Thread Eelco Dolstra
Hi, On 05/01/13 21:41, Tom Gundersen wrote: > This merges the nss-myhostname repo with the systemd repo (as requested > in TODO). Eh. Nss-myhostname is a very useful package, but I'm wondering what the motivation is for merging it into systemd? (The TODO doesn't say eit

[systemd-devel] [PATCH] Fix some typos

2012-11-30 Thread Eelco Dolstra
--- man/udevadm.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/man/udevadm.xml b/man/udevadm.xml index 3bd7738..7791028 100644 --- a/man/udevadm.xml +++ b/man/udevadm.xml @@ -429,9 +429,9 @@ --update -Compile the hardware

Re: [systemd-devel] [PATCH] Fix a fatal dbus abort in bus_manager_message_handler()

2012-10-31 Thread Eelco Dolstra
change looks wrong to me - I don't see a cleanup attribute on > the reply member in git master at least - v195-103-g173fa08 here. Oops, you're right. Searching for calls to dbus_message_unref I mistook the "oom" label in message_from_file_changes() for the one in bus_manager_mess

[systemd-devel] [PATCH] Fix a fatal dbus abort in bus_manager_message_handler()

2012-10-31 Thread Eelco Dolstra
If ListUnitFiles fails, or an OOM occurs, then dbus_message_unref() will be called twice on "reply", causing systemd to crash. So remove the calls to dbus_message_unref(); these are unnecessary because of the cleanup attribute on "reply". --- src/core/dbus-manager.c | 2 -- 1 file changed, 2 dele

[systemd-devel] [PATCH] Properly handle device aliases used as dependencies

2012-10-10 Thread Eelco Dolstra
If a device unit has aliases defined in udev rules, and there are other units that depend on that alias, as in BindTo=sys-subsystem-net-devices-eth0.device then systemd will fail the start the alias, and any dependent units will time out. See https://bugs.freedesktop.org/show_bug.cgi?id=525

Re: [systemd-devel] [ANNOUNCE] systemd 190

2012-09-21 Thread Eelco Dolstra
controller. Apparently setting /sys/fs/cgroup/cpu/cgroup.clone_children to 1 should cause cpuset.{mems,cpus} to be inherited from the top-level cgroup, but as far as I can tell, systemd doesn't set clone_children anywhere. What is the right way to deal with this? Thanks, Eelco. -- Eel

[systemd-devel] [PATCH] Fix compilation error due to wrong __NR_name_to_handle_at definition

2012-09-21 Thread Eelco Dolstra
"__NR_name_to_handle" should read "__NR_name_to_handle_at". This fixes a compilation error on systems with older kernel headers. --- src/shared/missing.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/shared/missing.h b/src/shared/missing.h index c5bb71a..14abe4e

[systemd-devel] [PATCH] Fix broken links to sd-daemon.c

2012-09-13 Thread Eelco Dolstra
--- man/sd-daemon.xml | 2 +- man/sd_booted.xml | 2 +- man/sd_is_fifo.xml | 2 +- man/sd_listen_fds.xml | 2 +- man/sd_notify.xml | 2 +- src/systemd/sd-daemon.h | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/man/sd-daemon.xml b/man/sd-daemon.xml i

Re: [systemd-devel] How to handle loop mounts?

2012-08-08 Thread Eelco Dolstra
chine systemd[1]: Job disk2.img.device/start timed out. Aug 08 15:33:51 machine systemd[1]: Job cryptsetup.target/start failed with result 'dependency'. ... (I'm running systemd 187 BTW.) -- Eelco Dolstra | LogicBlox, Inc. | http://nixos.org/~eelco/ ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel

[systemd-devel] How to handle loop mounts?

2012-08-07 Thread Eelco Dolstra
sense for device units to recognise regular files and go to the "plugged" state immediately? (It would need to wait for the mount point containing the file to appear, though.) -- Eelco Dolstra | LogicBlox, Inc. | http://nixos.org/~eelco/ __

[systemd-devel] [PATCH] systemd: Fail a service if it exceeds its start limit

2012-08-06 Thread Eelco Dolstra
Previously, if a service configured to restart automatically exceeds its start limit, it entered the "inactive/dead" state. That seems wrong to me, since there is nothing to indicate to the user that the service has failed. This patch causes it to enter the failed state instead. --- src/core/ser

[systemd-devel] [PATCH] journald: fix assertion failure in ellipsize_mem()

2012-07-19 Thread Eelco Dolstra
When showing the journal through "journalctl --no-pager", if the prefix of the log message (i.e. the date and syslog identifier) is less than 3 characters shorter than the width of the terminal, you get: Assertion 'new_length >= 3' failed at src/shared/util.c:3859, function ellipsize_mem(). Abort

[systemd-devel] [PATCH] journal: set the _SYSTEMD_UNIT field for messages from terminated processes

2012-06-21 Thread Eelco Dolstra
As described in https://bugs.freedesktop.org/show_bug.cgi?id=50184 the journal currently doesn't set fields such as _SYSTEMD_UNIT properly for messages coming from processes that have already terminated. This means among other things that "systemctl status" may not show some of the output of s