Cannot make MQTT service working

I tried to install MQTT on my hassbian from this video:

I follow to the end but the problem is: When I restart my pi.

home-assistant@homeassistant: **inactive**

I think the problem is the video guide tell me to edit the home-assistant@homeassistant service to require mosquitto to run every time reboot. But right now every time I reboot my pi. my mqtt service only run after I used command Mosquitto - v

I don’t know how to fix my HA and my mosquitto to run . please help ?

The fact Home Assistant fails to start suggests the mosquitto service also failed to start (because you configured Home Assistant’s startup to be dependent upon mosquitto’s presence).

I suggest you remove the requirement for mosquitto.service to be operational before Home Assistant is allowed to start. It’s the information entered at around 10:57 minutes in the video (all of the Requires=mosquitto.service" line and what is added to`. Save the file and either restart the system daemon or just reboot the Raspberry Pi.

Now Home Assistant will start independently of the need for mosquitto. If it still fails to start, then there are other problems to solve.

Now you can focus on why the mosquitto service failed to start. Double-check what you wrote in etc/systemd/system/mosquitto.service. Check the system log for errors concerning mosquitto.service.

tail -100 /var/log/syslog

follow your advise. I can restart my HA now. but mosquitto sirvice is dead now.should I tried to remove all mosquito and retry back with

sudo hassbian-install mosquitto


It was always dead. That’s why Home Assistant failed to start when you configured it to depend on mosquitto being alive (it was never alive).

You now have to determine why the mosquitto service fails to start. As I said in my previous post, double check the mosquitto.service file for typing errors. Check syslog for error messages that might provide clues as to why mosquitto isn’t starting.

Uninstalling/re-installing mosquitto isn’t the answer. You know mosquitto works because you can start it from the command line. The problem is it fails to run automatically upon startup. That’s controlled by the system daemon, specifically the information you entered in mosquitto.service.