Having trouble running Syncthing as a service with systemd. Scoured the web, read forums, looked at wiki, and still can’t make sense of it.
Syncthing v0.11.25, Linux (ARM) on Pogoplug V2
Logged over ssh to the headless server as user:alarm, sudoer member.
Installed with ‘sudo pacman -S syncthing’, no errors.
Running ‘syncthing -gui-address=192.168.50.5:8384 -no-browser’ works correctly.
Add to systemd with the commands below:
sudo cp /usr/lib/systemd/system/syncthing@.service /etc/systemd/system/syncthing@.service
/etc/systemd/system/syncthing@.service:
[Unit]
Description=Syncthing - Open Source Continuous File Synchronization for %I
Documentation=http://docs.syncthing.net/
After=network.target
[Service]
User=%i
Environment=STNORESTART=yes
ExecStart=/usr/bin/syncthing -no-browser -logflags=0
Restart=on-failure
SuccessExitStatus=2 3 4
RestartForceExitStatus=3 4
[Install]
WantedBy=multi-user.target
sudo systemctl enable syncthing@alarm.service
sudo systemctl start syncthing@alarm.service
sudo systemctl status syncthing@alarm.service returns:
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: syncthing v0.11.25 "Aluminium Ant" (go1.5.1 l... UTC
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: My ID: NAL24GJ- FU4UGWV-RGXYNG4-PXWW6DO-KXETIU...NTQV
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: Database block cache capacity 8192 KiB
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] OK: Ready to synchronize default (read-write)
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: Starting web GUI on https://127.0.0.1:8384/
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: Starting local discovery announcements
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: Starting global discovery announcements
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: Completed initial scan (rw) of folder default
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: Device NAL24GJ-FU4UGWV-RGXYNG4-PXWW6DO-KXETIU...mic]
Sep 20 18:52:45 alarm syncthing[3428]: [NAL24] INFO: API listening on 127.0.0.1:8384
Hint: Some lines were ellipsized, use -l to show in full.
Navigating to http://192.168.50.5:8384 results in a ‘unknown device’ on the page.
It seems Syncthing is not reading the files in’/home/alarm/.config/syncthing/
I can’t figure out why and how to point to the correct config files.
Any help greatly appreciated, don’t have much hair left to pull out.
george.hormel