:: Re: [DNG] Mosquitto cannot be start…
Etusivu
Poista viesti
Vastaa
Lähettäjä: Ludovic Bellière
Päiväys:  
Vastaanottaja: dng
Aihe: Re: [DNG] Mosquitto cannot be started, because no /var/mosquitto directory (Devuan stable)
Hello Steffen,

The systemd service file does create the necessary directories (see:
https://github.com/eclipse/mosquitto/blob/master/service/systemd/mosquitto.service.simple).

/run/mosquitto not being created is most likely an issue with debian itself.
Creating the folder from the init file, as per your workaround, is valid. To
resolve the installation issue would require to file a bug against mosquitto on
debian BTS. Apparently somebody did just that, and provided a patch to boot:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=993048

See also: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=983429

Cheers,
                 Ludovic


On Mon, 13 Dec 2021, Steffen Dettmer via Dng wrote:

>Hi,
>
>mosquitto does not start, because there is no /var/mosquitto directory
>for its PID file. Actually it cannot even be installed, because dpkg
>script already wants it.
>Also creating directory does not solve the problem, because /run is
>tmpfs, so manually created directory won't be there on next reboot.
>
>As workaround, I simply added
>
> mkdir -p /run/mosquitto/ ; chown mosquitto /run/mosquitto
>
>to /etc/init.d/mosquitto script. I guess this in Debian is done by
>some systemd magic, which could be needed to be "emulated" in Devuan,
>so I write here.
>
>What should I do?
>