Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
BitTorrent Sync linux service script

####Go to temp dir $ cd /tmp ####Download your version of btsync i386 or x64 $ curl -o btsync.tar.gz # i386 $ curl -o btsync.tar.gz # x64 ####Then unpack this shit $ tar -xf btsync.tar.gz ####And move to your local bin $ mv btsync /usr/local/bin/ ####Okey, generate sample config $ btsync --dump-sample-config > ~/.btsync ####Change "storage_path" to correct path, I'm use /home/andrii/.sync, if u want too $ mkdir ~/.sync $ nano ~/.btsync ####Autorun $ update-rc.d btsync defaults


This comment has been minimized.

Copy link

gr0undzer0 commented May 18, 2013

I'm trying to use this on Fedora 18 and I modified line 25 and line 19 to reflect the location of btSync and the sync.conf. Also the user to run as.

I'm getting an error at line 55 that start-stop-daemon command is not found. Should my changes work? This is for BTsync (the file syncing project) right?


This comment has been minimized.

Copy link

broerman commented Jun 25, 2013

  1. I changed the following to avoid this output , when callinig /etc/init.d/btsync
    ( X11 connection rejected because of wrong authentication. )

    config="su -c 'echo $HOME' $user/.btsync"
    homedir=$(getent passwd $user | awk -F: '{print $6}')

  2. in the config file $home/.btsync I set the PID file like in /etc/init.d/btsync

    "pid_file" : "/var/run/syncapp/",

  3. The system V Skript should always start on boot

    update-rc.d btsync defaults

Thank you for your work


This comment has been minimized.

Copy link

GITchristoph commented Jun 29, 2013

Dear Korzhyk
Never mind my initial question.

What was missing for me was to run the command

update-rc.d btsync defaults

to add btsync to the default startups.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.