Hi Andy, thanks for your help.
avahi-dbus-daemon was already installed (although I recall my original error on install was something to do with dbus?) and I installed
wsdd2 . No sign of the share on Windows, and I tried the Finder option
Go -> Connect to server -> smb://192.168.1.1/NAS1 and also NAS (share-name in Luci) and also just the ip, no luck connecting on any attempt.
Hi Andy, thanks for your help.
Is your actual share name "NAS1"? You need to use the name of the network share name, you have setup in the samba4 luci setup page.
That's 'NAS1' yep.
So even from windows explorer
\\192.168.1.1\NAS1 wont work?
smbd process running on the router?
That was it! I disabled Samba last night. Enabled, I have access on both PC and Mac. I'm really sorry about this Andy, I'm a complete plonker. Solved! Thanks for your help!
I've done a couple of research and I'm trying to get my personal NAS running.
I've followed this guide, which already creates users, groups, and assigns them to the directory correctly, and helps configuring the samba4.
But despite all I'm getting this error message:
And it got me as far as I could. Can the problem be that I'm using windows 8.1?
I also get this on explorer:
Can someone help please?
Hello - I'm an OpenWRT / Linux Novice.
I'm trying to use OpenWRT to resurrect my Netgear Stora MS-2110 NAS, it essentially bricked its self because the UI that shipped with it was build on Flash. So its now dead, even though the fundamental hardware is perfectly serviceable for the application.
So far with the help of this forum and the OpenWRT platform... I'm tantalizingly close to success because I now have functioning firmware, and a partitioned RAID1 config up and running, and Samba fileshare broadcasting that other computers in my local network can see.
I'm not exactly sure what the problem is, but the situation is essentially:
1 - Computers can write files to the Samba share, they don't seem to get acknowledgement that the copy process has occurred successfully (so they hang), but I can SSH in and see that files have been created. 2 - I can also generate dummy files in the shared directories and the Windows & Linux PC's can see them near instantly
3 - I can not copy a file off the share drive to the remote pc. It hangs and doesnt appear to commence file copy
Notes - I don't understand how the permissions / user structures work in Samba Vs the rest OpenWRT and for now I dont have any users configured. I was hoping to start with the most simple config (no users / passwords) to validate the functionality.. and if it all works ok, I'll drop in some new large HDD's and do it again.
Should I be able to openly share files without user permissions set up? Is it likely user profile related, or something else? What config should I post to help diagnose the problem?
Your OpenWRT version and Samba version/packages installed. Also make sure your root samba share has full access aka 0777.
PS: Btw the default case is to allow guest read/write access, so no special user setup should be needed.
@Andy2244 FYI I'm trying to configure it all via the Luci UI, so I have not done any samba related config directly to the backend (other than a chmod to make sure root has open access to the partition.) The partition is located in: /mnt/md0/Dir1
LuCI openwrt-21.02 branch (git-21.046.64947-cb0979f)
OpenWrt 21.02-SNAPSHOT r15818-c6319239d8
And the template:
netbios name = |NAME|
interfaces = |INTERFACES|
server string = |DESCRIPTION|
unix charset = |CHARSET|
workgroup = |WORKGROUP|
## This global parameter allows the Samba admin to limit what interfaces on a machine will serve SMB requests. bind interfaces only = yes ## time for inactive connections to-be closed in minutes deadtime = 15 ## disable core dumps enable core files = no ## set security (auto, user, domain, ads) security = user ## This parameter controls whether a remote client is allowed or required to use SMB encryption. ## It has different effects depending on whether the connection uses SMB1 or SMB2 and newer: ## If the connection uses SMB1, then this option controls the use of a Samba-specific extension to the SMB protocol introduced in Samba 3.2 that makes use of the Unix extensions. ## If the connection uses SMB2 or newer, then this option controls the use of the SMB-level encryption that is supported in SMB version 3.0 and above and available in Windows 8 and newer. ## (default/auto,desired,required,off) #smb encrypt = default ## set invalid users invalid users = root ## map unknow users to guest map to guest = Bad User ## allow client access to accounts that have null passwords. null passwords = yes ## The old plaintext passdb backend. Some Samba features will not work if this passdb backend is used. (NOTE: enabled for size reasons) ## (tdbsam,smbpasswd,ldapsam) passdb backend = smbpasswd ## Set location of smbpasswd ('smbd -b' will show default compiled location) #smb passwd file = /etc/samba/smbpasswd ## LAN (IPTOS_LOWDELAY TCP_NODELAY) WAN (IPTOS_THROUGHPUT) WiFi (SO_KEEPALIVE) try&error for buffer sizes (SO_RCVBUF=65536 SO_SNDBUF=65536) socket options = IPTOS_LOWDELAY TCP_NODELAY ## If this integer parameter is set to a non-zero value, Samba will read from files asynchronously when the request size is bigger than this value. ## Note that it happens only for non-chained and non-chaining reads and when not using write cache. ## The only reasonable values for this parameter are 0 (no async I/O) and 1 (always do async I/O). ## (1/0) #aio read size = 0 #aio write size = 0 ## If Samba has been built with asynchronous I/O support, Samba will not wait until write requests are finished before returning the result to the client for files listed in this parameter. ## Instead, Samba will immediately return that the write request has been finished successfully, no matter if the operation will succeed or not. ## This might speed up clients without aio support, but is really dangerous, because data could be lost and files could be damaged. #aio write behind = /*.tmp/ ## lower CPU useage if supported and aio is disabled (aio read size = 0 ; aio write size = 0) ## is this still broken? issue is from 2019 (NOTE: see https://bugzilla.samba.org/show_bug.cgi?id=14095 ) ## (no, yes) #use sendfile = yes ## samba will behave as previous versions of Samba would and will fail the lock request immediately if the lock range cannot be obtained. #blocking locks = No ## disable loading of all printcap printers by default (iprint, cups, lpstat) load printers = No printcap name = /dev/null ## Enabling this parameter will disable Samba's support for the SPOOLSS set of MS-RPC's. disable spoolss = yes ## This parameters controls how printer status information is interpreted on your system. ## (BSD, AIX, LPRNG, PLP, SYSV, HPUX, QNX, SOFTQ) printing = bsd ## Disable that nmbd is acting as a WINS server for unknow netbios names #dns proxy = No ## win/unix user mapping backend #idmap config * : backend = tdb ## Allows the server name that is advertised through MDNS to be set to the hostname rather than the Samba NETBIOS name. ## This allows an administrator to make Samba registered MDNS records match the case of the hostname rather than being in all capitals. ## (netbios, mdns) mdns name = mdns ## Clients that only support netbios won't be able to see your samba server when netbios support is disabled. #disable netbios = Yes ## Setting this value to no will cause nmbd never to become a local master browser. #local master = no ## (auto, yes) If this is set to yes, on startup, nmbd will force an election, and it will have a slight advantage in winning the election. It is recommended that this parameter is used in conjunction with domain master = yes, so that nmbd can guarantee becoming a domain master. #preferred master = yes ## (445 139) Specifies which ports the server should listen on for SMB traffic. ## 139 is netbios/nmbd #smb ports = 445 139 ## This is a list of files and directories that are neither visible nor accessible. ## Each entry in the list must be separated by a '/', which allows spaces to be included in the entry. '*' and '?' can be used to specify multiple files or directories as in DOS wildcards. veto files = /Thumbs.db/.DS_Store/._.DS_Store/.apdisk/ ## If a directory that is to be deleted contains nothing but veto files this deletion will fail unless you also set the delete veto files parameter to yes. delete veto files = yes
################ Filesystem and creation rules ################
## reported filesystem type (NTFS,Samba,FAT)
#fstype = FAT
## Allows a user who has write access to the file (by whatever means, including an ACL permission) to modify the permissions (including ACL) on it. #dos filemode = Yes ## file/dir creating rules #create mask = 0666 #directory mask = 0777 #force group = root #force user = root #inherit owner = windows and unix
mhh Snapshots with Samba4 and default settings should work with guest access out of the box for a default share, you can try enable "Force Root" mode in the UI settings.
Btw what filesystem are you using on the mount?
I had success by changing the create mask to 0777 from 0666. I don't understand why it works, but it works.
I suspected that things were being written with incorrect privileges to access them.
@Andy2244 have you by chance tried to set up a share for use with Apple time machine? I havn't had much luck getting it to work natively. I got it to work by creating an image file in a share, and mounting it within OS X but the performance was woeful (I realized what I had done as soon as the second backup started.. poor little Stora IO hasn't worked that hard ever I suspect).
There are Luci UI options specifically for this at the end of the share setup? Did you try create a second share and just enabling those options?
Yeah, I did, but time machine refused to recognize it as an option. I'm going to have another go with a few added settings I got from a friend.
I hope I am in the right place for questions on samba 4, but it seems that I should be
So, I am trying to setup samba4 shares in OpenWRT and it seems pretty forward, but is not working, i.e. I cannot access from Windows 10 clients.
There was also an error message after installing
dbus: Unknown group "netdev" in message bus configuration file
Am I missing a package or why is it not working?
I setup a test share for /mnt/sdb1
config samba option workgroup 'WORKGROUP' option charset 'UTF-8' option description '1' config sambashare option path '/mnt/sdb1' option name 'sdb1' option create_mask '0666' option dir_mask '0777' option read_only 'yes' option guest_ok 'yes'
I then tried to simply enter \192.168.5.71 (IP of NAS) in the Windows Explorer but it cannot connect.
Clearly I am missing something :duh:
P.S.: I did not edit the template yet. Do I maybe need to edit something there? NAS is not broadcasting the share.
P.P.S.: As it is a NAS and not a router, I did not edit any firewall rules. Everything is still OpenWRT defaults.
\\192.168.5.71\sdb1, also try install the
wsdd2 package and than check my problems sections here: https://github.com/Andy2244/openwrt-extra, especially try restart the
Function Discovery Resource Publication windows service on your clients.
What filesystem do your use? You can also try
chmod -R 0777 /mnt/sdb1 or try enable the
force root option on the share.
PS: No, you should not need to edit the template.
I can see the server now that I switched to WORKGROUP.
However, I cannot access the server.
I tried mounting the network drive.
I tried \192.168.5.71
I tried \192.168.5.71\sdb1
I tried \192.168.5.71mnt\sdb1
I tried \192.168.5.71\sambashare
Nothing seems to work.
Filesystem is ext4.
Try create a share on
/tmp just to make sure its not a filesystem/external problem and see if you can browse/mount this share.
Also what does
net use H: \\192.168.5.71\sdb1 in a windows shell/powershell yields?
Could also be a interface problem, check the
/etc/samba/smb.conf file and what interface is it trying to bind to and if this interface actually exists and is the correct one.
[global] interfaces =
For testing only you could allow samba to bind to any interface via changing the template:
bind interfaces only = no
This is driving me mad.
Suddenly, and I don't know what I changed, one device is working and the other is not. Configs seem to be identical.
Now I wanted to check the packages and one system has 193 packages installed and the other 197. I would like to compare which packages are missing.
Is there a file that contains this information? I don't want to compare 197 lines one by one.
So, after following your guide and googling some more and trying different stuff, I found that I had to manually set the credentials in Windows 10 via the user accounts.
I was not prompted on the second NAS but after adding it manually via user accounts, it worked immediately!
So thank you for your support and anybody facing a similar problem: check User Accounts - Manage your credentials and then add them manually.