>>> Lennart Poettering <lennart@xxxxxxxxxxxxxx> schrieb am 29.01.2021 um 16:38 in Nachricht <20210129153859.GA31189@gardel-login>: > On Fr, 29.01.21 12:30, Ulrich Windl (Ulrich.Windl@xxxxxxxxxxxxxxxxxxxx) > wrote: > >> Hi! >> >> I wonder whether this is a bug: >> When starting a socket unit that finds ist service active already, I get an > error >> systemd[1]: libvirtd-tls.socket: Socket service libvirtd.service already > active, refusing. >> systemd[1]: Failed to listen on Libvirt TLS IP socket. >> >> When using systemd units in a pacemaker cluster this is fatal: >> pacemaker-controld[7467]: notice: Transition 316 action 81 > (prm_libvirtd-tls-sock_start_0 on rksaph19): expected 'ok' but got 'error' >> >> Maybe the special problem is that two socket units (libvirtd-ro.socket, > libvirtd-tls.socket) exist to start the same service (libvirtd.service). >> >> I'm clueless how to handle that. Ideas? > > The socket activation logic works so that the activation sockets are > passed to the service being activated during execve(). Thus, if a > service is already running we can't pass in more sockets: you have to > restart the service so that there's another execve() we can pass the > newly started sockets over. > > My guess is that your service — if it finds that it didn't get a > socket passed in that it needs — just creates the socket itself as a > fallback... > > It's generally a good idea for services to have Requires= + After= on > the sockets that actviate it, to make sure that the sockets are always > started before the service itself, and the situation you are seeing > cannot happen. I think before running things from pacemaker,I started them in this order libvirtd libvirtd-ro libvirtd-tls And there was no problem (or I missed something). Now with pacemaker I assumed that either libvirtd-ro or libvirtd-tls would start libvirtd as needed with no explicit start of libvirtd. Regards, Ulrich > > Lennart > > -- > Lennart Poettering, Berlin _______________________________________________ systemd-devel mailing list systemd-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/systemd-devel