Cannot browse CIFS share

Status
Not open for further replies.

strophy

Dabbler
Joined
May 6, 2014
Messages
19
Hi,

recently installed 9.2.1.3 then upgraded to 9.2.1.5 on a HP N54L, network card is Broadcom NetXtreme BCM5723 Gigabit Ethernet PCIe. Samba shares were not visible or browsable on the network, but could be accessed by directly typing the IP \\192.168.1.xxx. I don't control the DHCP server on this network so the IP tends to change sometimes, therefore Samba browsing is pretty important. It's a pretty simple network otherwise, can't figure out why the FreeNAS box doesn't appear in my workgroup.

Below is the output of the lanscan.exe utility and attached is my smb4.conf. Would really appreciate any help, thanks!


Code:
LANscanner v1.55 - ScottiesTech.Info
 
Scanning LAN...
 
Scanning workgroup: WORKGROUP...
 
BJ-NB-LEON        192.168.1.106    74-e5-0b-6b-05-ca  WORKGROUP  MASTER
OPENELEC          192.168.1.110    e0-b9-a5-7d-ab-e5  WORKGROUP
 

Attachments

  • smb4.txt
    2.4 KB · Views: 299

Yatti420

Wizard
Joined
Aug 12, 2012
Messages
1,437
Maybe try restarting and see if that helps.. Accessing by IP is always safest..
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
Was this working before upgrading to 9.2.1.5? If yes then I suggest moving back to 9.2.1.3 until 9.2.1.6 comes out. And you could be a beta tester if you like to help us work on problems like these, if you're willing that is.
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
Is the FreeNAS server set to be the local master browser?

Note that it can take several minutes for master browser election to occur and for FreeNAS to appear in Explorer.

You may also want to review the following log: /var/log/samba4/log.nmbd
 

strophy

Dabbler
Joined
May 6, 2014
Messages
19
Hi guys, sorry for my slow response - I only got one notification email for several replies it seems.

The network browsing wasn't working in 9.2.1.3 either, I had hoped the upgrade to 9.2.1.5 would help with that. I switched the box on again for the first time in a few days today and CIFS does not work at all anymore, even when directly entering the IP address from Windows 7 Professional. The console log shows the following:

Code:
May 16 23:13:04 freenas notifier: winbindd not running? (check /var/run/samba/winbindd.pid).
May 16 23:13:04 freenas notifier: smbd not running? (check /var/run/samba/smbd.pid).
May 16 23:13:04 freenas notifier: nmbd not running? (check /var/run/samba/nmbd.pid).
May 16 23:13:05 freenas notifier: Performing sanity check on Samba configuration: FAILED


I tried deleting /usr/local/etc/smb4.conf and regenerating it by clicking the CIFS wrench and the service started once, was inaccessible, and then could not be stopped again. When I tried this a few days ago I had configured it to be local master browser, after deleting the settings file the setting was disabled again and the problem with the service starting is preventing me from testing it again. I have been using the excellent lanscan tool to show all computers on the workgroup, and FreeNAS has not appeared there once, even after several hours uptime.

/var/log/samba4/log.nmbd is full of errors along these lines:
Code:
[2014/05/06 06:22:18,  0] ../source3/nmbd/nmbd.c:902(main)
  nmbd version 4.1.6 started.
  Copyright Andrew Tridgell and the Samba Team 1992-2013
[2014/05/06 06:22:18,  0] ../source3/lib/util_sock.c:485(open_socket_in)
  bind failed on port 137 socket_addr = 192.168.1.255.
  Error = Can't assign requested address
[2014/05/06 06:22:18,  0] ../source3/nmbd/nmbd_subnetdb.c:127(make_subnet)
  nmbd_subnetdb:make_subnet()
    Failed to open nmb bcast socket on interface 192.168.1.255 for port 137.  Error was Can't assign requested address
[2014/05/06 06:22:18,  0] ../source3/nmbd/nmbd.c:1047(main)
  ERROR: Failed when creating subnet lists. Exiting.



I'd love to help beta test 9.2.1.6 and get this working!
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
Have you run "testparm" from the terminal? Can you attach your smb4.conf file?

Perhaps also post the output of ifconfig -a.

Are you on a /24 network? Have you tried setting up a small test network? (i.e. workstation + freenas + cheap router with a couple of LAN ports and a DHCP server) If, so were the results the same?
 

strophy

Dabbler
Joined
May 6, 2014
Messages
19
Thanks for the reply, anodos! Yes, this is a simple /24 network on a wired/wireless router. About 5 computers and a few phones/tablets. Here is what I tried next:

ifconfig -a output:
Code:
[root@freenas] ~# ifconfig -a
bge0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=c0099<RXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,VLAN_HWTSO,LINKSTATE>
        ether 9c:b6:54:0e:b9:ec
        inet 192.168.1.100 netmask 0xffffff00 broadcast 192.168.1.255
        nd6 options=9<PERFORMNUD,IFDISABLED>
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
ipfw0: flags=8801<UP,SIMPLEX,MULTICAST> metric 0 mtu 65536
        nd6 options=9<PERFORMNUD,IFDISABLED>
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
        options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
        inet6 ::1 prefixlen 128
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x9
        inet 127.0.0.1 netmask 0xff000000
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
bridge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        ether 02:28:1a:0c:6c:00
        nd6 options=1<PERFORMNUD>
        id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15
        maxage 20 holdcnt 6 proto rstp maxaddr 2000 timeout 1200
        root id 00:00:00:00:00:00 priority 32768 ifcost 0 port 0
        member: epair0a flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
                ifmaxaddr 0 port 11 priority 128 path cost 2000
        member: bge0 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
                ifmaxaddr 0 port 1 priority 128 path cost 200000
epair0a: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=8<VLAN_MTU>
        ether 02:93:a4:00:0b:0a
        nd6 options=1<PERFORMNUD>
        media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
        status: active


Code:
[root@freenas] ~# testparm
Load smb config files from /usr/local/etc/smb4.conf
max_open_files: increasing sysctl_max (11095) to minimum Windows limit (16384)
rlimit_max: increasing rlimit_max (11095) to minimum Windows limit (16384)
Loaded services file OK.
WARNING: lock directory /var/db/samba4 should have permissions 0755 for browsing to work
WARNING: state directory /var/db/samba4 should have permissions 0755 for browsing to work
WARNING: cache directory /var/db/samba4 should have permissions 0755 for browsing to work
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions


This was interesting, so I changed the permission to 755 on that file and the FreeNAS miraculously appeared on the network, completely browseable and everything. But only for a limited time, I think it may have caused trouble during the next master browser election and now I can't see any computers in my network anymore. Is this a familiar problem to anyone?

Thanks,
Leon
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
Leon,
I will review your smb4.conf file tomorrow when I have a chance, but I noticed that you have two shares: Storage (located at /mnt/Storage) and Video (located at /mnt/Storage/Video). You should create separate datasets for each CIFS share.
For example:

[STUFF]
/mnt/Storage/Stuff

[Video]
/mnt/Storage/Video

[More Stuff]
/mnt/Storage/MoreStuff

There is a hidden system dataset on /mnt/Storage that you don't want to get messed up by playing with ACLs and permissions. It is possible that something you did to troubleshoot or create your shares actually created the problems you are having. At this point it may be faster to have a do-over from the beginning (copy your data off the server, start with a fresh USB stick, create your zpool, users, groups, and shares). Follow the guide here: http://doc.freenas.org/index.php/Windows_(CIFS)_Shares.
 

strophy

Dabbler
Joined
May 6, 2014
Messages
19
Hi anodos,

I was under the impression that /mnt/Storage was a volume, and it contained datasets like /mnt/Storage/Video, is that right? I think I followed the guide pretty accurately, both the wiki guide and one of the more detailed guides on the forum. I've extended the network now through the house with two access points and set up an OpenELEC box, all of which went flawlessly. CIFS browsing on FreeNAS is the only part of my setup still hopelessly broken. I can ping the box, use the WebGUI and browse to it by IP address, but network browsing simply refuses to work.

Thanks for any more advice...
Leon
 

strophy

Dabbler
Joined
May 6, 2014
Messages
19
Actually, some other stuff is broken too. When I try to delete a folder from Windows, it completes successfully but nothing is actually deleted. Deleting individual files works. I cannot move any folders or files, I get an error saying the file is in use. I have set up ACL so that the group which my user is in has full and recursive rights to the /mnt/Storage/Video share.

Thanks again.
 

junior

Dabbler
Joined
Jun 16, 2014
Messages
26
Hello,

I've got the same issue, I can't brownse via internet explorer network view. I can delete and move things. Testparm doesn't see problem.
\\nas\Myshare works. It's not really a problem for computers but it's when I try to use WdTV Live since I can't select my shares.

Thanks.
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
Hi anodos,

I was under the impression that /mnt/Storage was a volume, and it contained datasets like /mnt/Storage/Video, is that right? I think I followed the guide pretty accurately, both the wiki guide and one of the more detailed guides on the forum. I've extended the network now through the house with two access points and set up an OpenELEC box, all of which went flawlessly. CIFS browsing on FreeNAS is the only part of my setup still hopelessly broken. I can ping the box, use the WebGUI and browse to it by IP address, but network browsing simply refuses to work.

Thanks for any more advice...
Leon


I was referring to data in your smb4.conf file. Specifically the following lines:
Code:
[Storage]
    path = /mnt/Storage
    printable = no
[video]
    path = /mnt/Storage/video


You should not select "/mnt/Storage" as a share. You should move the files you are trying to share through [Storage] to a dataset (i.e. /mnt/Storage/Foo) and point [Storage] to that dataset as well. Once you do that, go back and run "chmod 0755 /var/db/samba4".

The following is conjecture: "/var/db/samba4" is a symlink to "/mnt/Storage/.system/samba4". When you share out /mnt/Storage and start fiddling with permissions (especially actions that recursively take effect) it will break samba by changing permissions to your .system dataset.

In short, fix your shares, fix your permissions on /var/db/samba4, then try again.
 

strophy

Dabbler
Joined
May 6, 2014
Messages
19
Got it anodos, thanks. I'm going to wait for 9.2.1.6 to come out, do a clean install and try and fix the filesystem permissions after that. Will update this thread later.
 

junior

Dabbler
Joined
Jun 16, 2014
Messages
26
Hello Anados,
since I've got the same problem I followed your instructions. Unlike strophy I didn't mess with datasets and shares.
I created a dataset "Media" then shared it. The permissions are 777 nobody:nobody. ls -al confirms it.
So I checked /var/db/samba4.
I've got 0644 root:wheel on few files and 0600 root:wheel on others.

Shares work fine in mac and linux. In windows explorer view, \\freenas\media works but not with browse networks and the WDTV doesn't see the shares.

I tried a brand new install -> same results.

Edit : I've got the following bug :

https://bugs.freenas.org/issues/4874

Don't know if it is relevant or not. I applied the patch.
 

strophy

Dabbler
Joined
May 6, 2014
Messages
19
That bug matches my problem as well, although I started on 9.2.1.3 and then upgraded. I tried it last night on a clean install with only a USB drive shared and the entire machine was still not visible. Is it possible there is something common in our network setups causing this to happen?
 

junior

Dabbler
Joined
Jun 16, 2014
Messages
26
MMMM ... we're on something. There are some errors related to broadcast.

[2014/06/18 10:21:56, 0] ../source3/nmbd/nmbd.c:902(main)
nmbd version 4.1.6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
[2014/06/18 10:21:56, 0] ../source3/lib/util_sock.c:485(open_socket_in)
bind failed on port 137 socket_addr = 10.255.255.255.
Error = Can't assign requested address
[2014/06/18 10:21:56, 0] ../source3/nmbd/nmbd_subnetdb.c:127(make_subnet)
nmbd_subnetdb:make_subnet()
Failed to open nmb bcast socket on interface 10.255.255.255 for port 137. Error was Can't assign requested address
[2014/06/18 10:21:56, 0] ../source3/nmbd/nmbd.c:1047(main)
ERROR: Failed when creating subnet lists. Exiting.
[2014/06/18 11:06:29, 0] ../source3/nmbd/nmbd.c:902(main)
nmbd version 4.1.6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
[2014/06/18 11:06:29, 0] ../source3/lib/util_sock.c:485(open_socket_in)
bind failed on port 137 socket_addr = 10.255.255.255.
Error = Can't assign requested address
[2014/06/18 11:06:29, 0] ../source3/nmbd/nmbd_subnetdb.c:127(make_subnet)
nmbd_subnetdb:make_subnet()
Failed to open nmb bcast socket on interface 10.255.255.255 for port 137. Error was Can't assign requested address
[2014/06/18 11:06:29, 0] ../source3/nmbd/nmbd.c:1047(main)
ERROR: Failed when creating subnet lists. Exiting.
[2014/06/18 11:09:24, 0] ../source3/nmbd/nmbd.c:902(main)
nmbd version 4.1.6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
[2014/06/18 11:09:24, 0] ../source3/lib/util_sock.c:485(open_socket_in)
bind failed on port 137 socket_addr = 10.255.255.255.
Error = Can't assign requested address
[2014/06/18 11:09:24, 0] ../source3/nmbd/nmbd_subnetdb.c:127(make_subnet)
nmbd_subnetdb:make_subnet()
Failed to open nmb bcast socket on interface 10.255.255.255 for port 137. Error was Can't assign requested address
[2014/06/18 11:09:24, 0] ../source3/nmbd/nmbd.c:1047(main)
ERROR: Failed when creating subnet lists. Exiting.
[2014/06/18 11:37:19, 0] ../source3/nmbd/nmbd.c:902(main)
nmbd version 4.1.6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
[2014/06/18 11:37:19, 0] ../source3/lib/util_sock.c:485(open_socket_in)
bind failed on port 137 socket_addr = 10.255.255.255.
Error = Can't assign requested address
[2014/06/18 11:37:19, 0] ../source3/nmbd/nmbd_subnetdb.c:127(make_subnet)
nmbd_subnetdb:make_subnet()
Failed to open nmb bcast socket on interface 10.255.255.255 for port 137. Error was Can't assign requested address
[2014/06/18 11:37:19, 0] ../source3/nmbd/nmbd.c:1047(main)
ERROR: Failed when creating subnet lists. Exiting.
[2014/06/18 11:41:11, 0] ../source3/nmbd/nmbd.c:902(main)
nmbd version 4.1.6 started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
[2014/06/18 11:41:11, 0] ../source3/lib/util_sock.c:485(open_socket_in)
bind failed on port 137 socket_addr = 10.255.255.255.
Error = Can't assign requested address
[2014/06/18 11:41:11, 0] ../source3/nmbd/nmbd_subnetdb.c:127(make_subnet)
nmbd_subnetdb:make_subnet()
Failed to open nmb bcast socket on interface 10.255.255.255 for port 137. Error was Can't assign requested address
[2014/06/18 11:41:11, 0] ../source3/nmbd/nmbd.c:1047(main)
ERROR: Failed when creating subnet lists. Exiting.

I'm going to check my network.
 

enemy85

Guru
Joined
Jun 10, 2011
Messages
757
What happens to me is a bit different:
Freenas 9.2.1.5 64bit ZFS
I created a dataset /mnt/NAS/PRIVATE (owner:nobody - group:Ghome permission 770) and a CIFS windows share pointing at that dataset;
Inside PRIVATE i created more datasets USER1...USERn (owner:USER1...USERn - group:Ghome permission 700)
What happens is that windows7 cannot find the freenas share if it scans automatically the network, but if i browse to //freenas from command line, i found the PRIVATE share and inside that all the other USER folders working with the right permissions.
Why is not available directly on the network as i was used to with the old 9.1.1 version? Am I missing something?
 

junior

Dabbler
Joined
Jun 16, 2014
Messages
26
Hello,

The logs suggested I've got a problem with mdns responder and it was the case. I fixed it by adding mdns responder inside my gentoo server.
Sorry, if it doesn't help others as I'm in specific situation using a linux server as master operator on my network.

Thanks.
 
Status
Not open for further replies.
Top