Mailinglist Archive: opensuse-bugs (3912 mails)

< Previous Next >
[Bug 914415] systemctl restart socket unit will start service too
  • From: bugzilla_noreply@xxxxxxxxxx
  • Date: Mon, 02 Feb 2015 03:55:38 +0000
  • Message-id: <bug-914415-21960-ckvec7zdra@http.bugzilla.suse.com/>
http://bugzilla.suse.com/show_bug.cgi?id=914415

--- Comment #20 from Liuhua Wang <lwang@xxxxxxxx> ---
(In reply to Werner Fink from comment #19)
(In reply to Martin Pluskal from comment #16)

IMHO the `systemctl try-restart' on a socket isn't that what should be done.
Therefore a

Also=lvm2-lvmetad.socket

in the `[Install]' section of the "lvm2-lvmetad.service" should be
sufficient to be ablle to remove"lvm2-lvmetad.service" from the
%service_add_* macro lines in the spec file.

Thank you for providing that.

As my test now these two ways can avoid service from starting after updating
package:
1. remove .socket from %service_delete_* macro in %preun and %postun.
But I don't think it is good that update a package without socket unit being
restarted.

2. add ALSO option to Install section as Werner suggested and remove
But seems that it only works in case that the old package as well including an
ALSO option. The service will be running if only the new package including ALSO
option but the old package not including an ALSO option.
Is it expected?

--
You are receiving this mail because:
You are on the CC list for the bug.
< Previous Next >