Closed mstormi closed 3 years ago
This worked as a post-install fix:
mkdir -p /opt/zram/log.bind/mosquitto
chown mosquitto /opt/zram/log.bind/mosquitto
That's creating the directory on the lowerFS so it's there when zram starts.
Do you think that is a proper fix ?
Not sure why zram-config.service
didn't sync back /var/log/mosquitto
.
I was able to reproduce this for grafana and homegear, too. Same fix applies.
Sorry for the delayed response, I was out camping with my Family and just got back, I'll try to look at this and the other issues over the weekend and figure out the best solution.
No worries, there's a life beyond the screen, too. Just returned from my son's vaccination.
@ecdye see https://community.openhab.org/t/openhabian-mosquitto-mqtt-failed-to-start/102951/86
I was able to reproduce by flashing an image, installing mosquitto from the menu and then reboot. See below for status after reboot. So the reason is
/var/log/mosquitto
is gone. Manually purged + installed mosquitto again via menu:/var/log/mosquitto
is back. Rebooted again,/var/log/mosquitto
is gone again.There's a report this happens with openhab and homegear, too (although I don't trust that statement as it obviously isn't true for openhab) but it's sign of a common zram issue.
Note unlike some other packages we create the systemd config for, the mosquitto package comes with its own mosquitto.service so we would need to sed-edit or replace that OR use the override config as in my post #41 see there for my fix. That is not in our code though.