pirkojm

Btsync Eats All Cpu On Raspberry Pi

Recommended Posts

hello, I setup btsync on my rapsberrypi model B, added some overclocking, serving as one way backup server with external disk.

 

Unfortunately btsync is eating all my cpu, even during time there is nothing to sycnhronize. I know raspberry is not very strong machine, however I wouldn't expect so bad performance with btsync. I read the manual and set all the properties refering somehow to performance. I even tried to send logs to /dev/null to prevent btsync write on sdcard too often. But nothing really helped.

 

Using btsync 1.2.82 from AUR. Here is the config file and service script:

/usr/bin/btsync --config /home/pi/.config/btsync/btsync.conf --nodaemon
 "storage_path" : "/mnt/backup/.btsyncStorage",  "check_for_updates" : false,  "use_upnp" : false,                              // use UPnP for port mapping  "disk_low_priority": true,  "lan_encrypt_data": false,  "folder_rescan_interval": 1800,  "lan_use_tcp": true,

Share this post


Link to post
Share on other sites

Hi pirkojm,

 

CPU (and, actually, RAM) usage is highly dependent on amount of files and folders that your Sync'ed folder has. To find out the difference BTSync has to calculate a large amount of hashes for the files stored on storage. 

 

Keeping in mind that Raspberry PI has not very strong CPU, even hashing task might be heavy for it. How many files and folders do you have? Is there any folders with excessive amount of files?

 

Your actions (especially - removing encryption) are fine to lower CPU usage. I would also advise to increase rescan interval even more (to, say, one day) and see how long is it going to take for RPI to index all of your files (the CPU usage should go down of no actual syncing is happening now).

Share this post


Link to post
Share on other sites

Thanks for ideas - well there are some folders with huge amount of small files. I sync 5 folders only, but with considerable amount of files. I will try to experiment a bit and will see

Share this post


Link to post
Share on other sites

If using Raspbmc - activate swap file ... helps on limited ram ... there is a touch command .... google it if on raspbmc ...syncing nearly 250.000 files on raspi without problems and running xbmc ... 

Share this post


Link to post
Share on other sites

running archlinux, considering swap too, however I have read, that too many writes on sd card are also not very efficient.

 

One of my synced folders have over 130000 files and there are also aften some changes - I will try to reduce it.

 

Thanks for ideas!

Share this post


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.

Guest
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.