[HC2] [Armbian] Slow transfer speed via Samba

Moderators: odroid, mdrjr

[HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Wed Nov 28, 2018 12:02 am

Why is samba out of the box so slow on the HC1/HC2?

I'm running latest armbian stretch stable on my HC2 but I read this also from many other os.
Filesystem on attached hdd is ext4.
I simply installed samba and samba-common, made sure it runs on the big cores and also used these settings in smb.conf to make transfer speed faster:

Code: Select all
write cache size = 524288
getwd cache = yes
use sendfile = yes
min receivefile size = 16384


With these settings I "just" get 60 mb/s transfer speed! :roll:
Initially I installed OMV via armbian-config and with this tweaked OMV and its samba I got 100 mb/s!
Ran into issues and removed OMV, I don't need it anyways, for my use it's overkill.

Are there settings I'm missing here? The speed difference is enormous :o
I think with HC1/HC2 gigabit nas speeds shouldn't be a problem.
Is there maybe a custom built samba debian package out there that takes care of some tweaks for a 100 mb/s transfer speed via samba?
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby odroid » Wed Nov 28, 2018 9:28 am

There must be no special custom built samba.

Try to see "cat /proc/interrupts" output first.
Code: Select all
#!/bin/bash                                                                                                                                                                             
USB3_IRQ=`cat /proc/interrupts | grep "GICv2 104" | awk -F : '{print $1}'`                                                                                                               
USB5_IRQ=`cat /proc/interrupts | grep "GICv2 105" | awk -F : '{print $1}'`                                                                                                               
echo 5 > /proc/irq/${USB3_IRQ}/smp_affinity_list                                                                                                                                         
echo 6 > /proc/irq/${USB5_IRQ}/smp_affinity_list                                                                                                                                         
                                                                                                                                                                                         
if [ -f /sys/class/net/eth0/queues/rx-0/rps_cpus ]; then                                                                                                                                 
        echo f > /sys/class/net/eth0/queues/rx-0/rps_cpus                                                                                                                               
fi


And check CPU governor and minimum frequency in cpufreq sysfs.
User avatar
odroid
Site Admin
 
Posts: 29098
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Thu Nov 29, 2018 2:39 am

Cpu governor set is ondemand.
Output of cpufreq-info: https://pastebin.com/2Jp5741N
Output of /proc/interrupts:https://pastebin.com/CARuEHHf

Should I put the posted lines of code in a script and execute it or what? :?:
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Thu Nov 29, 2018 2:52 am

trohn_javolta wrote:Should I put the posted lines of code in a script and execute it or what? :?:


Did that, but speed is still at like 50 mb/s.
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby rooted » Thu Nov 29, 2018 8:11 am

Didn't you ask this question on Armbian's forum?
User avatar
rooted
 
Posts: 5908
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby odroid » Thu Nov 29, 2018 9:35 am

Try "performance" governor on both big and little cores.
User avatar
odroid
Site Admin
 
Posts: 29098
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Thu Nov 29, 2018 5:32 pm

rooted wrote:Didn't you ask this question on Armbian's forum?

I did and got the answer to search myself.
I did search the forum but couldn't find anything new. Just found this script for tweaked settings https://pastebin.com/8AE5sZFz
But all settings from the samba section where already in my smb.conf.
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Thu Nov 29, 2018 5:35 pm

odroid wrote:Try "performance" governor on both big and little cores.


At the moment I can't, I copy stuff from int. hdd to ext. hdd via usb. But I'll try that. Is there a command to set that for all cores?
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby rooted » Fri Nov 30, 2018 4:18 am

trohn_javolta wrote:
rooted wrote:Didn't you ask this question on Armbian's forum?

I did and got the answer to search myself.
I did search the forum but couldn't find anything new. Just found this script for tweaked settings https://pastebin.com/8AE5sZFz
But all settings from the samba section where already in my smb.conf.


I was just wondering what they said?
User avatar
rooted
 
Posts: 5908
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby odroid » Fri Nov 30, 2018 9:47 am

trohn_javolta wrote:
odroid wrote:Try "performance" governor on both big and little cores.


At the moment I can't, I copy stuff from int. hdd to ext. hdd via usb. But I'll try that. Is there a command to set that for all cores?


You have to run below commands with superuser privileges.
For LITTLE cores,
Code: Select all
echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

For big cores,
Code: Select all
echo performance > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
User avatar
odroid
Site Admin
 
Posts: 29098
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Mon Dec 03, 2018 8:27 pm

odroid wrote:
trohn_javolta wrote:
odroid wrote:Try "performance" governor on both big and little cores.


At the moment I can't, I copy stuff from int. hdd to ext. hdd via usb. But I'll try that. Is there a command to set that for all cores?


You have to run below commands with superuser privileges.
For LITTLE cores,
Code: Select all
echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

For big cores,
Code: Select all
echo performance > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor


Unfortunately that did not help either. Any other ideas? I don't understand how there can be such a difference in speed...
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby odroid » Tue Dec 04, 2018 12:27 pm

You might need to post a question on OMV forum to find a tweak what they made.
User avatar
odroid
Site Admin
 
Posts: 29098
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby rooted » Tue Dec 04, 2018 1:54 pm

I'm not understanding your issue really.

You installed OMV on Armbian, installed samba through OMV interface, uninstalled OMV and it uninstalled samba also? If not then SMB should still be set-up?

After a bit of reading I don't think OMV is doing anything special to the samba configuration.

If you read this page you will see ryecoaaron says as much.

https://forum.openmediavault.org/index. ... ork-Drive/
User avatar
rooted
 
Posts: 5908
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby trohn_javolta » Thu Dec 06, 2018 5:05 pm

rooted wrote:I'm not understanding your issue really.

You installed OMV on Armbian, installed samba through OMV interface, uninstalled OMV and it uninstalled samba also? If not then SMB should still be set-up?

After a bit of reading I don't think OMV is doing anything special to the samba configuration.

If you read this page you will see ryecoaaron says as much.

https://forum.openmediavault.org/index. ... ork-Drive/


Samba was a dependency of OMV and I had to purge OMV install due to a PHP error I couldn't resolve. So yes I also removed Samba. Before I backed up smb.conf. Reinstalled samba and copied back smb.conf.
I also don't understand the sudden speed change..
But yeah.. seems I have to start over again with a fresh armbian OMV install.
trohn_javolta
 
Posts: 46
Joined: Fri Nov 03, 2017 6:16 am
languages_spoken: english, german
ODROIDs: none (plans for XU4)

Re: [HC2] [Armbian] Slow transfer speed via Samba

Unread postby rooted » Thu Dec 06, 2018 5:08 pm

That would be my suggestion, reinstall and copy the configuration.

Please share the differences here if you don't mind.
User avatar
rooted
 
Posts: 5908
Joined: Fri Dec 19, 2014 9:12 am
Location: Gulf of Mexico, US
languages_spoken: english


Return to Other OS

Who is online

Users browsing this forum: No registered users and 2 guests