Howdy! Been working on this project off and on for over a year. Last time I tried to set up Samba it was at 3.6 and someone suggested I try Samba 4. Searching configuration guides for Samba 4 seem to not exist. I think I managed to get it installed but it won't share anything as I would suspect over Netbios. On my Windows laptop, I see the name of domain name that I have named my OpenWRT device (espressobin v5) when when I try to open up the share from Windows it tells me I am not authorized. I don't use WORKGROUP on my Windows 7 laptop. I haven't tried it yet on my Windows 10 machines.
The USB drive I can access via WinSCP and I see under /mnt/sda2 some directories I set up previously including /Music and /Movies.
I tried to add a share such as this:
Network Shares
Samba Version 4.11.6
General Settings
Edit Template
Interface
lan: [Ethernet Adapter: "lan0"] [Ethernet Adapter: "lan1"]
Workgroup (sort of grayed-out)
Description Samba on OpenWRT
Force synchronous I/O blank
Enable macOS compatible shares blank
Allow legacy (insecure) protocols/authentication. blank
Allow legacy smb(v1)/Lanman connections, needed for older devices without smb(v2.1/3) support. box-checked
Disable Netbios blank
Added to SHARED DIRECTORIES: (example test line)
Name Movies
Path /mnt/sda2/Movies
Browse-able checked
Read-only blank
Force Root blank
Allowed users blank
Allow guests checked
Guests only blank
Inherit owner blank
Create mask 0666
Directory mask 0777
Vfs objects blank
Apple Time-machine share blank
Time-machine size in GB blank
And I get the error message in windows when clicking on my server in the windows network access panel that I am not authorized. Thanks in advance.
Strange isn't it the lack of response and the lack of documentation on this. My problem was apparently that my Windows 7 system was hosed. I spent the last couple of days going through everything I could find on the web to resolve the issue I was seeing with the error:
\\NAME-PC is not accessible. You might not have permission to use this network resource. Contact the administrator of this server to find out if you have access permissions.
The specified network provider name is invalid
It's all laid out here for what finally got me going. You may even have to do as I did and go further than all the steps this procedure lays out in order to resolve the issue with the network adapter where you can't access via Samba You may in fact have to do everything in this link AND go ahead and delete the option of "Client for Microsoft Networks", reboot your system and add "Client for Microsoft Networks" back. Additionally after going through all this, all that happened was that I got a completely different error message of which of course I didn't write down but basically I resolved that by disabling the old free AVG anti-virus on my Windows 7 system.
At last I can after tryng for over a year, access my Samba shared on OpenWRT. It is a shade disappointing that I can only obtain a speed of about 9M/sec uploading to the server but at least all my files are not disappearing off the ext4 partition I created using my Windows 7 machine and the best ext4 driver which is also flakey.
Everything is great now. I even added transmission and now the native SMB:xxxxxxx support of Kodi accesses this server and transmission can add new files as I desire. Great setup if you don't mind things a little slow. Kodi doesn't seem to have an issue with buffering or anything from using the SMB share, so I guess all is well that ends well and as far as a file server, this is going to be not anywhere near an acceptable file backup option but it will do in a pinch for an individual use media server.
Here's how to get started with any WIndows 7 access issues (and don't forget remove/re-add the Client for Microsoft and check disablign AVG):