Samba4 experience

To try samba 4, you have to do:

schnapps create "before samba experiments"
opkg update
opkg remove luci-i18n-samba-cs luci-i18n-samba-en luci-app-samba samba36-server samba36-client samba36-hotplug samba36-net
opkg install samba4-admin samba4-client samba4-libs samba4-server samba4-utils luci-app-samba4 luci-i18n-samba4-cs luci-i18n-samba4-en
/etc/init.d/samba4 enable

Use the i18n packages that belong to languages you have installed. It might happen that it is needed to run the first command several times.

Also, to prevent updater errors, create file /etc/updater/conf.d/disable-samba36.lua containing:

Uninstall("samba36-server", { priority = 60 })
Uninstall("samba36-client", { priority = 60 })
Uninstall("luci-app-samba", { priority = 60 })
Uninstall("luci-i18n-samba-en", { priority = 60 })
Uninstall("luci-i18n-samba-cs", { priority = 60 })

In my settings, CPU also throttles at ~100%, but with transfer speeds betwen 350 and 400 Mbps, I think that’s expected :slight_smile: The test was done by downloading from btrfs-formatted USB3 RAID drive connected to Omnia.

Does anybody have a tip for interesting non-default settings available with samba 4? I read about SMB direct, but haven’t figured out how do I enable it (if it’s not by default). Offloading some CPU work would probably allow for even higher speeds.

1 Like

I have this with original samba, USB disk attached to omnia:

LAN connection.

Two things that are worth looking at with Samba 4:

  • Disable SMB1 and make sure the SMB version is using 3.11(client and server)
  • Enable jumbo frames as one of the main benefits of newer SMB version is less protocol overheads.

Around 50MB/s is quite reasonable on a single 1Gbit connection.


Rising MTU to 9000 for eth2 will disconnect everything (LAN/WiFi) and because I dont have console cable, I cant tell You why this happens.

from this post encourages me not to even touch those values :smiley:

schnapps? I wouldn’t be that scared to experiment…

Why is there no nmbd in the samba4-server package? How is NetBIOS supposed to work?

Is NetBIOS even needed?

It is not a crucial element, but the naming services does not work without it. I don’t know the terminology, but you won’t see anything when you click on “Network” in the Windows file explorer.

So, you could only add samba disk manually in windows then, well that sucks…

Btw, NetBIOS kinda spams, seeing wireshark…

Please install package “wsdd2” and you see samba server in Windows “Network”.

1 Like

I have bad luck.
My Turris 1.0 + Samba4 + wdds2 does not work.
I have a PC with Win7 Enterprise and notebook with Win 10 Home, only works by IP address.
Restart the router and PC, did not help. Workgroup is DOMA.

net use r: \\turris\nas\tftp\images - error 53
net use r: \\\nas\tftp\images - no problem, all fine, folder available

root@turris:~# ps | grep smbd
8661 root 31112 S /usr/sbin/smbd -F
8801 root 28608 S {smbd-notifyd} /usr/sbin/smbd -F
8802 root 28608 S {cleanupd} /usr/sbin/smbd -F
8823 root 31104 S {lpqd} /usr/sbin/smbd -F
19288 root 31228 S /usr/sbin/smbd -F

Hi, @commar, I just want to tell you that I had same problem adding samba3+ disk via “net use” while NetBIOS was enabled, Window7 is weird and buggy, but I was able to add it via DDNS name. Just mine observation…

According to the description we it seems, that you have a poorly set up DNS. Launch a ping from the PC. Once with the IP address of the samba, and once with the DNS name. Ping should be working.
If does not work samba with DNS name, you need to set the DHCP.
(EDIT: no true! "and through foris/DNS/‘Register DHCP clients in DNS’).

Podľa popisu sa my zdá, že máš asi zle nastavené DNS. Spusť ping z PC. Raz s IP adresou samby a raz s DNS menom. Ping by mal byt funkčný.
Ak nefunguje samba s DNS menom, budeš musieť nastaviť DHCP.
(EDIT: už neplatí! "a cez foris/DNS/“Registrovat DHCP klienty v DNS”.

Meno “rutra” a meno samby servera ma byť také isté.
The name of the “rutra” and the name of the samba server should be the same.

D:>ping dgw
Pinging [] with 32 bytes of data:
Reply from bytes=32 time<1ms TTL=64

Server: UnKnow <<— not set reverse DNS

Non-authoritative answer: