TOS 5 upgrade changes router hostname (Samba 4 troubles)

Samba4/ksmbd package maintainer here, you guys should really use the wsdd2 package to avoid all those hostname/discovery errors. Also try use the default config/template first, a lot of parameters i see all over the place are old samba36 recommendations and there is a reason those are changed to other defaults in samba4.

The “modern” way for samba4 is to use the hostname and not the netbiosname anymore, thats why i removed the ability to set a separate netbios name, since Win10 removed netbios discovery from the explorer, netbios itself is still working and there but now considered a legacy feature. In its place we now have WSD which is what the wsdd2 package is for.

As a tip you can run testparm to check your samba config and compare it to the defaults.

PS: Not sure if this was ported to Omnia yet, but we have the ksmbd package for a while now as a drop-in samba3/4 replacement, its a tiny (400 kb) kernel/userspace package. The config/UI is nearly identically and other then its tiny size, users did report better speeds on some devices. So if you have this in your repo maybe give it a try, also works with wsdd2.

3 Likes

wsdd2 is indeed in the package feeed. Just tested it and it works like a charm, Cheers!

Thanks mate for you post :slight_smile:

So once i switch to 4.x branche , i can omitt option name 'somename' from template/config in general options? Or will be missing in template by default ?

I will post my notes/guides once i switch to samba 4.x :slight_smile:
btw: Is there some list with ‘mapping’ of smb.conf options for samb36 vs 4.x related to deprecated/default/legacy options?

It will be ignored as UCI option from the config and set by init script to the hostname, so it expects the template to have the placeholder aka netbios name = |NAME|. This netbios name, which is the hostname is than also used by wsdd2.

Yes and no you would need to compare the samba36 docu vs samba4 yet they did write a new async io framework and the internal smb server was also rewritten. So some of the older settings are not really the same for the new version, as example the old aio read size, read raw and several other buffer sizes don’t really match anymore and either do nothing or may hurt performance. Some other settings still work, but in general the defaults are pretty good, so you should only change them for a specific reason.
Yet we still have the same “samba speed magic” options, that for some users work and do nothing for others so its a case by case try&error similar to samba36.
I’m lucky and get maxed read/write speeds with just defaults on my wrt1200ac.

1 Like