Am 12.01.2016 um 19:30 schrieb Lennart Poettering:
On Tue, 12.01.16 18:54, Reindl Harald (h.rei...@thelounge.net) wrote:

Also, what happens if the daemon is configured to listen on some
different port? Or on multiple ports? Are you parsing the daemon's
config file too to figure out what to watch for? YUCK!

the Fedora myqld unit does, mine is simplified

the systemd-behavior that manual "systemctl stop whatever.service" don't
prevent socket activation and fireup again the service is a systemd problem
*you* have to solve if you want widely adopted usage of socket activation

That's hardly a "problem", as I see it.

for you

What you should be invoking is "systemctl stop whatever.socket
whatever.service", which terminates both the daemon and the listening
socket. I think that's pretty easy to grok for most folks, as long as
you realized the logic behind it once.

it's not a matter of grok something

it's a matter of not every daemon has a socket and hwat does the user express with a command - you aregued the same way about making "systemctl stop sshd" versus "systemctl stop sshd.service" work as default

That said, of course, this is not obvious at first, hence since quite
some time "systemctl stop" will actually explain this to you: if you
stop a daemon, but leave its socket running, then you'll get a
friendly message telling you about this, and suggesting you the right
command line to terminate the socket too.

as soon as you are able to print out such a "friendly message" you are also able to imply it automatically

I am pretty sure this makes a lot of sense the way it is, and is
sufficiently well self-explanatory.

no, it violates the prnciple of least surprise and that won't change

Attachment: signature.asc
Description: OpenPGP digital signature

--
devel mailing list
devel@lists.fedoraproject.org
http://lists.fedoraproject.org/admin/lists/devel@lists.fedoraproject.org

Reply via email to