We use some essential cookies to make our website work.

We use optional cookies, as detailed in our cookie policy, to remember your settings and understand how you use our website.

kyljmn
Posts: 3
Joined: Mon Feb 24, 2020 2:49 am

Service won't start. code=exited, status=1/FAILURE

Mon Feb 24, 2020 2:56 am

I've been trying to get this service running for a while now, and I've been stuck with this problem for a week now.

These are the results for systemctl status:

Code: Select all

pi@raspberrypi:~ $ systemctl status mtf-pi-scout
● mtf-pi-scout.service - The Measure the Future scout
   Loaded: loaded (/lib/systemd/system/mtf-pi-scout.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Mon 2020-02-24 10:35:49 PST; 15min ago
  Process: 1096 ExecStart=/usr/local/mtf/bin/scout (code=exited, status=1/FAILURE)
 Main PID: 1096 (code=exited, status=1/FAILURE)

Feb 24 10:35:48 raspberrypi systemd[1]: Started The Measure the Future scout.
Feb 24 10:35:49 raspberrypi systemd[1]: mtf-pi-scout.service: Main process exited, code=exited, status=1/FAILURE
Feb 24 10:35:49 raspberrypi systemd[1]: mtf-pi-scout.service: Failed with result 'exit-code'.
and These are the logs from journalctl:

Code: Select all

Feb 24 10:32:40 raspberrypi dhcpcd[349]: eth0: fe80::1 is reachable again
Feb 24 10:32:49 raspberrypi sshd[1010]: Accepted password for pi from 192.168.1.5 port 2110 ssh2
Feb 24 10:32:49 raspberrypi sshd[1010]: pam_unix(sshd:session): session opened for user pi by (uid=0)
Feb 24 10:32:49 raspberrypi systemd-logind[268]: New session c3 of user pi.
Feb 24 10:32:49 raspberrypi systemd[1]: Started Session c3 of user pi.
Feb 24 10:32:54 raspberrypi systemd-timesyncd[257]: Synchronized to time server for the first time 162.159.200.123:123 (0.debian.pool.ntp.org).
Feb 24 10:34:02 raspberrypi sudo[1035]:       pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/chmod 755 /usr/local/bin
Feb 24 10:34:02 raspberrypi sudo[1035]: pam_unix(sudo:session): session opened for user root by pi(uid=0)
Feb 24 10:34:02 raspberrypi sudo[1035]: pam_unix(sudo:session): session closed for user root
Feb 24 10:34:54 raspberrypi sudo[1048]:       pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/usr/sbin/service mtf-pi-scout restart
Feb 24 10:34:54 raspberrypi sudo[1048]: pam_unix(sudo:session): session opened for user root by pi(uid=0)
Feb 24 10:34:54 raspberrypi systemd[1]: Started The Measure the Future scout.
Feb 24 10:34:54 raspberrypi systemd[1058]: mtf-pi-scout.service: Failed to execute command: Permission denied
Feb 24 10:34:54 raspberrypi systemd[1058]: mtf-pi-scout.service: Failed at step EXEC spawning /usr/local/mtf/bin/scout: Permission denied
Feb 24 10:34:54 raspberrypi systemd[1]: mtf-pi-scout.service: Main process exited, code=exited, status=203/EXEC
Feb 24 10:34:54 raspberrypi systemd[1]: mtf-pi-scout.service: Failed with result 'exit-code'.
Feb 24 10:34:54 raspberrypi sudo[1048]: pam_unix(sudo:session): session closed for user root
Feb 24 10:35:08 raspberrypi sudo[1064]:       pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status networking
Feb 24 10:35:08 raspberrypi sudo[1064]: pam_unix(sudo:session): session opened for user root by pi(uid=0)
Feb 24 10:35:08 raspberrypi sudo[1064]: pam_unix(sudo:session): session closed for user root
Feb 24 10:35:43 raspberrypi sudo[1076]:       pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/chmod 755 /usr/local/mtf/bin/scout
Feb 24 10:35:43 raspberrypi sudo[1076]: pam_unix(sudo:session): session opened for user root by pi(uid=0)
Feb 24 10:35:43 raspberrypi sudo[1076]: pam_unix(sudo:session): session closed for user root
Feb 24 10:35:48 raspberrypi sudo[1086]:       pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/usr/sbin/service mtf-pi-scout restart
Feb 24 10:35:48 raspberrypi sudo[1086]: pam_unix(sudo:session): session opened for user root by pi(uid=0)
Feb 24 10:35:48 raspberrypi systemd[1]: Started The Measure the Future scout.
Feb 24 10:35:48 raspberrypi sudo[1086]: pam_unix(sudo:session): session closed for user root
Feb 24 10:35:49 raspberrypi systemd[1]: mtf-pi-scout.service: Main process exited, code=exited, status=1/FAILURE
Feb 24 10:35:49 raspberrypi systemd[1]: mtf-pi-scout.service: Failed with result 'exit-code'.
Please send help!

User avatar
rpdom
Posts: 25187
Joined: Sun May 06, 2012 5:17 am
Location: Essex, UK

Re: Service won't start. code=exited, status=1/FAILURE

Mon Feb 24, 2020 5:30 am

Well, the "Permission denied" message should be a bit of a clue.

How about you show us your systemd service file and also the permissions on the program

Code: Select all

ls -l /usr/local/mtf/bin/scout
What happens when you run the command manually, and what command do you type to do that?
Unreadable squiggle

kyljmn
Posts: 3
Joined: Mon Feb 24, 2020 2:49 am

Re: Service won't start. code=exited, status=1/FAILURE

Mon Feb 24, 2020 1:29 pm

rpdom wrote:
Mon Feb 24, 2020 5:30 am
Well, the "Permission denied" message should be a bit of a clue.

How about you show us your systemd service file and also the permissions on the program

Code: Select all

ls -l /usr/local/mtf/bin/scout
What happens when you run the command manually, and what command do you type to do that?
This is what show's up when I us ls -l /usr/local/mtf/bin/scout:

Code: Select all

-rwxr-xr-x 1 root root 4776016 Jan  4  2017 /usr/local/mtf/bin/scout
To restart the service I use

Code: Select all

sudo service mtf-pi-scout restart

kyljmn
Posts: 3
Joined: Mon Feb 24, 2020 2:49 am

Re: Service won't start. code=exited, status=1/FAILURE

Mon Feb 24, 2020 1:49 pm

rpdom wrote:
Mon Feb 24, 2020 5:30 am
Well, the "Permission denied" message should be a bit of a clue.

How about you show us your systemd service file and also the permissions on the program

Code: Select all

ls -l /usr/local/mtf/bin/scout
What happens when you run the command manually, and what command do you type to do that?
Also I'm new to linux. is this what you meant by systemd service file?

Code: Select all

[Unit]
Description=The Measure the Future scout
After=postgresql.service

[Service]
Environment=LD_LIBRARY_PATH=:/usr/local/lib
WorkingDirectory=/usr/local/mtf/bin
ExecStart=/usr/local/mtf/bin/scout

[Install]
WantedBy=multi-user.target

Return to “Troubleshooting”