Run Resilio Sync Service as root (linux)

Recommended Posts

Hello, I´ve installed Resilio Sync using the below link. I did the basic configuration and I can access the 8888 webgui successfully. The local user created is rslsync (with group same name), that is different from the Web Gui user.

The server I installed Resilio, is a production CPANEL server, and the idea is to have all Cpanel accounts and server configs backed up in another location (sync´d), without the need to use CPANEL backup function (that does not support syncing yet)

The problem is that resilio sync can´t access each account of Cpanel (folders and subfolders), nor server configurations as it have their own user/group for each account in system. I don´t want to change each folder permissions with chmod with risk to brake CPANEL.

So, based on all this. How to run Resilio (service in linux) as root, and/or have automatically access to all folders in CenOS 6 server, without compromising CPANEL system/server?

Thanks in advance!

Installation link:

Link to post
Share on other sites

Helen, thank you for your reply. I did what you said. 

This is how my resilio.sync.service is now, after the change:

Description=Resilio Sync service

ExecStartPre=/bin/mkdir -p /var/run/resilio-sync
ExecStartPre=/bin/chown -R root:root /var/run/resilio-sync
ExecStart=/usr/bin/rslsync --config /etc/resilio-sync/config.json


Also did a restart at its service and CentOS6 before test it again into Web Gui.

Still can´t acess all folders of server. It says "Its not possible to open destination folder". 

Any lights?

Thank you in advance


Link to post
Share on other sites

how's hd2 mounted - what are the parameters? 
do you see this error for other directories? 
In Terminal, can you do the listing of /mnt/hd2 without any error output? 

You have only one Sync running, and it's definitely running as root (checked with ps). Correct? 

Link to post
Share on other sites

here is how the /mnt/hd2 is mounted in etc/fstab:

"/dev/vdb        /mnt/hd2        ext4    auto,rw,usrjquota=quota.user,jqfmt=vfsv0"

PS listing of sync:

root@netvolt [/mnt/hd2]# ps aux|grep sync|grep -v grep
root        22  0.0  0.0      0     0 ?        S    Oct10   0:00 [async/mgr]
root        24  0.0  0.0      0     0 ?        S    Oct10   0:24 [sync_supers]
rslsync  14606  0.3  0.1 749856  5632 ?        Ssl  Oct20  13:29 /usr/bin/rslsync --config /etc/resilio-sync/config.json
root@netvolt [/mnt/hd2]#

- Yes, root can list all folders without problem in SSH;

- Resilio Web Gui also have same error to list "/home/some_accounts" but not all of them. Some are inside this folder, and some are linked to mnt/hd2


Link to post
Share on other sites
29 minutes ago, Julianno said:

rslsync  14606  0.3  0.1 749856  5632 ?        Ssl  Oct20  13:29 /usr/bin/rslsync --config /etc/resilio-sync/config.json

Sync here runs as rslsync, not root. Thus - no permissions to access the folder. 

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.