2

The maximum speed of my Pi can get is about 1.8 MB/s down when using BitTorrent Sync. On the same network, my MacBook Air is BT Sync at 9 to 10 MB/s down.

  • 512MB model
  • no swap
  • both Pi and MacBook Air write to the same Time Capsule NAS
  • Pi connects to Time Capsule via LAN cable
  • MacBook Air connects to Time Capsule via WiFi

How can I improve the performance?

From top:

top - 20:46:10 up 22:23,  1 user,  load average: 1.85, 1.67, 1.20
Tasks:  63 total,   1 running,  62 sleeping,   0 stopped,   0 zombie
%Cpu(s): 73.4 us, 16.9 sy,  0.0 ni,  0.0 id,  0.0 wa,  0.0 hi,  9.7 si,  0.0 st
KiB Mem:    448776 total,   407572 used,    41204 free,    30512 buffers
KiB Swap:        0 total,        0 used,        0 free,   314548 cached

  PID USER      PR  NI  VIRT  RES  SHR S  %CPU %MEM    TIME+  COMMAND                                                   
 2091 root      20   0 97604  34m 2976 S  95.4  7.8  45:06.60 btsync                                                    
 1855 root      20   0     0    0    0 S   2.3  0.0   0:32.65 cifsd                                                     
 9147 pi        20   0  4664 1388 1028 R   1.0  0.3   0:00.23 top          
3
  • Try another BT client. Maybe Transmission is less CPU intensive.
    – Gerben
    Commented Jul 15, 2013 at 16:53
  • 1
    @Gerben Bittorrent Sync is not just the Bittorrent filesharing protocol. See labs.bittorrent.com/experiments/sync.html Currently there are no alternative clients.
    – verpfeilt
    Commented Jul 15, 2013 at 20:10
  • Sorry, I didn't know that. Looks very interesting though!
    – Gerben
    Commented Jul 16, 2013 at 11:30

3 Answers 3

3

It looks like btsync has maxed out the processor:

  PID USER      PR  NI  VIRT  RES  SHR S  %CPU %MEM    TIME+  COMMAND                                                   
 2091 root      20   0 97604  34m 2976 S  95.4  7.8  45:06.60 btsync
                                          ^^^^

If that's generally the case, then the bottleneck is the processing, and nothing to do with the network. If the network were an issue, the processor usage would be less, reflecting the fact that the process must wait for input and spend more time idle.

Put another way: btsync on the pi's little processor can process 1.8 MB/s of data. So, eg, if the raw data from a bittorrent stream were saved on disk, and all the pi had to do was translate it into whatever form on the same disk, it would still not exceed 1.8 MB/s.

Not really anything you can do about that, unfortunately.

2

One unavoidable downside to the pi is that it's only method of major disk IO is through USB, which has a major processor overhead (20-30%). As goldilocks pointed out you're maxing out the processor at ~96%.

If you really want/need to improve your performance you could overclock the pi, but depending on how constant you're moving data that could lead into overheat issues. Make sure you address cooling concerns if you do so.

Edit: I just remembered, the ethernet port on the raspberry pi is actually connected through a usb 2.0 controller, so there's more overhead to deal with...

If you're really dealing with a large amount of data, I'd recommend looking into a private NAS box.

0

If your over a local network you can turn off encryption for btsync. You can also overclock the cpu on your raspberry pi.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.