[systemd-devel] [PATCH] systemctl: introduce -e and -d for start and stop

Lennart Poettering lennart at poettering.net
Wed May 13 06:36:31 PDT 2015

On Wed, 13.05.15 15:21, jsynacek at redhat.com (jsynacek at redhat.com) wrote:

> From: Jan Synacek <jsynacek at redhat.com>

Hmm, do we really need two options for this? I mean, since -e would
only ever be combined with start, and -d only with stop it could as
well be a single option that works for both?

Also, I am tempted to say that this should be reversed: instead of
making this options that alter start/stop behaviour, it should be
options that alter enable/disable behaviour, and actually take into
account the precise units that were enabled, including everything
referenced in the [Install] section of the unit files.

hence, I think I would prefer something like this instead:

       systemctl enable --now foobar.service
       systemctl disable --now foobar.service

Where "--now" simply means that the service shall be started after
enabling, and stopped after disabling. 

Does this make sense?


Lennart Poettering, Red Hat

More information about the systemd-devel mailing list