Linux - /etc/systemd/system/service: Invalid user/group name or numeric ID: user
Hello, I have one question. On VPS Ubuntu I installed Caliber-Web, everything works without problems, but when the server restarts, the library will not find. I have to run it with the command in the caliber-web nohup python cps.py folder. I found the tutorial and created the file "cps.service" as root in the / etc / systemd / system folder with the following content:
But the service is still not working, I have an error when restarting the server
/etc/systemd/system/cps.service:6: Invalid User / Group Name or Numeric ID: [archos]
I tried to enter root instead of the user, but still the same. I tried it without parentheses, instead of / usr / bin / python just python.
Thank you very much for any advice.
Good day,
I would definitely put those square brackets off the roads and users:
Furthermore, those paths are functional (do they exist?), Verify this by listing:
Python usually has multiple versions, try to enter
and press tab - python2.7, python3.7 etc .. I don't know what the application requires.
[Unit]
Description=Calibre-Web
[Service]
Type=simple
User=[archos]
ExecStart=[/usr/bin/python] [/home/archos/calibre-web/cps.py]
WorkingDirectory=[/home/archos/calibre-web/cps.py]
[Install]
WantedBy=multi-user.target
But the service is still not working, I have an error when restarting the server
/etc/systemd/system/cps.service:6: Invalid User / Group Name or Numeric ID: [archos]
I tried to enter root instead of the user, but still the same. I tried it without parentheses, instead of / usr / bin / python just python.
Thank you very much for any advice.
REPLY
Good day,
I would definitely put those square brackets off the roads and users:
[Unit]
Description=Calibre-Web
[Service]
Type=simple
User=archos
ExecStart=/usr/bin/python /home/archos/calibre-web/cps.py
WorkingDirectory=/home/archos/calibre-web/cps.py
[Install]
WantedBy=multi-user.target
Furthermore, those paths are functional (do they exist?), Verify this by listing:
ls /usr/bin/python
ls /home/archos/calibre-web/cps.py
Python usually has multiple versions, try to enter
ls /usr/bin/python
and press tab - python2.7, python3.7 etc .. I don't know what the application requires.