BananaPi as a fileserver -- some personal thoughts and experiences.

15 25912
Edited by tkaiser at Wed Nov 12, 2014 04:39

Just a small follow-up for "single user NAS" use cases. In this special scenario when just one network client wants to use the services of the Banana Pi then one can manipulate scheduler settings as well as assign specific tasks to dedicated CPU cores.

In my setup I delegated all network interrupts to CPU 1 (the remaining stuff will be processed on CPU 0 since IRQ balancing seem not work on armhf) and made some experiments with ionice and taskset (assigning specific processes to specific CPU cores):

The taskset default is 03 (using all available CPU cores) but I got the best results when I set the CPU affinity to 1 (means CPU 0). Playing with ionice and therefore process scheduler settings will probably only have noticeable effects when the system is busy doing other tasks.

In my scenario (using OS X as client and Netatalk as AFP server) I manipulated the settings of the three processes responsible for doing file services (Netatalk/AFP is not just a file server but has also an integrated database daemon to maintain ID <--> path relationsships for every file and directory inside a sharepoint). In case you're using eg. Samba you have to adjust the settings of the smbd process serving the specific client. Therefore these settings can't be applied at startup time when only the master smbd process is running but have to be adjusted at runtime when the client is already connected and the PID of the forked smbd process serving the client is known.

My processes had the process IDs 1890, 3168 and 3170 so I simply adjusted this as root:
  1. for i in 1890 3168 3170 ; do
  2.         taskset -p 01 $i && ionice -c1 -p $i
  3. done
Copy the Code
This is stuff for eg. crontab running every minute. If for example the client in question authenticates as user 'john' and one wants to adjust CPU affinity and/or scheduler settings of the specific smbd process then something like this in crontab would do the magic (but the results below show that you better not touch the scheduler stuff and do not use '; /usr/bin/ionice -c1 -p $JohnsPID'):
  1. JohnsPID=$(/bin/ps auxww | /bin/grep smbd | /usr/bin/awk -F" " '/^john/ {print $2}') && /usr/bin/taskset -p 01 $JohnsPID ; /usr/bin/ionice -c1 -p $JohnsPID
Copy the Code
You get these few MBytes/sec for free if the Banana Pi is just serving one user and not many (in the latter case it's way better to rely on the defaults regarding scheduler settings and CPU affinity)

taskset -p 01 $i && ionice -c1 -p $i:

taskset -p 02 $i && ionice -c1 -p $i:

taskset -p 01 $i && ionice -c2 -p $i:

taskset -p 01 $i && ionice -c1 -p $i:

taskset -p 03 $i && ionice -c2 -p $i:

taskset -p 01 $i && ionice -c2 -p $i:

Which OS do you use?
I use the Ubuntu distro for my pi, and I can only get my network speed at around 300Mb/s im using iperf for monitoring.

I had tweaked my network setting and cpu0 to be used primarly for network.
Now I get speeds at around 830Mb/s - I think it's good without OC.
My read speed on a sata disk i around 43MB/s and write speed is around 10MB/s.

I have gone through your personal experience which you have shared here. But I didn’t much data from it. I think I need some more clarifications about the book. Share more details here if wedding

3 pointers noThere would be no memory for us to hold on to, Cooper Helfet game jersey only the stories of our fore fathers telling us of the glory days of Rangers hockey. On the contrary the Broadway Blueshirts may have been more successful through the 1990's having not made those trades. Adding Wayne Gretzky to a team with Tony Amonte, Todd Marchant and Mike Gartner amongst others could have made for something special and perhaps more years of success in New York beyond the fabled year of 1994.Attorneys announced a plea deal in March to resolve the Oakland Raiders jersey charges in all jurisdictions. On March 23, Sharper pleaded guilty to sexual assault in Arizona and no contest in David Amerson jersey authentic California. Raiders jerseys He was sentenced to nine years in Arizona and is expected to draw a nine year sentence when sentenced in California in July..

trying to find guiding

Mcallister Mark Ingram And Cameron Cheap Jerseys China Store Jordan Were In Attendance As

Nfl Officiating Does Merely Keeps Getting Worse

The Perfect Gift In A Sports Fanatic

Thanks for the information, I'm currently writing paper for on computers subject. And I'm going to mention the single board computer which you described.

You have to log in before you can reply Login | Sign Up

Points Rules