Mycroft Community Forum

Failed start on boot

Hidee ho, neighbors.

I followed this instruction to start on boot.

I made what I think are the appropriate changes to User and WorkingDirectory:

[Unit]
Description=Mycroft AI
After=pulseaudio.service

[Service]
User=dan
WorkingDirectory=/home/dan/
ExecStart=/home/dan/mycroft-core/bin/mycroft-start all
ExecStop=/home/dan/mycroft-core/bin/mycroft-stop
Type=forking
Restart=no

[Install]
WantedBy=multi-user.target

Running service mycroft status after rebooting gives me this:

dan@MyComputer:~$ service mycroft status
● mycroft.service - Mycroft AI
Loaded: loaded (/etc/systemd/system/mycroft.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2020-11-11 11:09:48 EST; 28s ago
Process: 649 ExecStart=/home/dan/mycroft-core/bin/mycroft-start all (code=exited, status=203/EXEC)

Nov 11 11:09:48 MyComputer systemd[1]: Starting Mycroft AI…
Nov 11 11:09:48 MyComputer systemd[649]: mycroft.service: Failed to execute command: No such file or directory
Nov 11 11:09:48 MyComputer systemd[649]: mycroft.service: Failed at step EXEC spawning /home/dan/mycroft-core/bin/mycroft-start: No such file or directory
Nov 11 11:09:48 MyComputer systemd[1]: mycroft.service: Control process exited, code=exited, status=203/EXEC
Nov 11 11:09:48 MyComputer systemd[1]: mycroft.service: Failed with result ‘exit-code’.
Nov 11 11:09:48 MyComputer systemd[1]: Failed to start Mycroft AI.
dan@MyComputer:~$

I’m running Linux Mint 20 Cinnamon, ver. 4.6.7.

I don’t really know anything about systemd, but I recently used it to connect my VPN on startup. I had issues with this too because my home directory is encrypted. I had to change the .service file and some other stuff to make it work.

Does anybody know if this is the issue and if there is a work-around?

Thank you!
Dan.

That path is correct? ls -l /home/dan/mycroft-core/bin/mycroft-start
If so, is it located on the root file system or a mount that might not yet be ready when Mycroft starts?


The WorkingDirectory is this combination btw has no effect as the wrapper script already navigates to the mycroft-core directory to execute the actual one. You might want to either do:

WorkingDirectory=/home/dan/mycroft-core
ExecStart=/home/dan/mycroft-core/start-mycroft.sh all

or

ExecStart=/home/dan/mycroft-core/bin/mycroft-start all

without defining WorkingDirectory.