Score:0

Samba share folder not showing

cn flag
jjs

I'm pretty new to Ubuntu and having issues with Samba shares. I have Ubuntu 20.04 installed on the server and win10 on my desktop. None of the shared folders I create (smb.conf or Nautilus) show up. The weird part is that there are some folders showing up that is accessible from the server and win10 (hassio folders). I'm assuming samba is working just that I have missed some configuration or something is interfering.

jaco@jaco-server:~$ testparm -s

Load smb config files from /etc/samba/smb.conf Loaded services file OK. Server role: ROLE_STANDALONE

Global parameters

[global]

log file = /var/log/samba/log.%m
logging = file
map to guest = Bad User
max log size = 1000
obey pam restrictions = Yes
pam password change = Yes
panic action = /usr/share/samba/panic-action %d
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
passwd program = /usr/bin/passwd %u
security = USER
server role = standalone server
server string = %h server (Samba, Ubuntu)
unix password sync = Yes
usershare allow guests = Yes
usershare owner only = No
idmap config * : backend = tdb

[printers]

browseable = No
comment = All Printers
create mask = 0700
path = /var/spool/samba
printable = Yes

[public]

force create mode = 0777
force directory mode = 0777
force user = nobody
guest ok = Yes
guest only = Yes
path = /dell
read only = No

jaco@jaco-server:~$ net usershare info --long

[test] path=/test comment= usershare_acl=Everyone:F,S-1-5-21-3504275779-4099143243-3885546580-1000:F, guest_ok=y

Between server restarts it alternates between showing Public & test folder and showing the other 5 hassio folders in other locations on ubuntu. On the win10 machine at always shows the 5 hassio folders

This has solved it for me To enable access under the guest account from your computer, you need to use the Group Policy Editor (gpedit.msc). Go to the section: Computer Configuration -> Administrative templates -> Network -> Lanman Workstation. Find and enable the policy Enable insecure guest logons. These policy settings determine whether the SMB client will allow unsafe guest logon to the SMB server.

Score:1
es flag

Windows 10 if configured the way Microsoft wants you to configure it by default will never be able to "discover" your Ubuntu samba shares.

That does not mean you cannot connect to it from Win10. You have 2 options:

[1] Connect to it directly in explorer by it's ip address - for example:

\\192.168.1.100

[2] Win10 can use mDNS to connect to the server - addressed by it's host name with a .local attached at the end:

\\ubuntu-server-host-name.local

Just make sure avahi is installed on Ubuntu:

sudo apt install avahi-daemon

If you really want Win10 to be able to discover your server you really only have 2 options:

[A] Win10 uses something called WS-Discovery ( WSD ) to discover hosts. Samba doesn't do WSD but with a bit of work you can make it work:

Download the folder:

wget https://github.com/christgau/wsdd/archive/master.zip

UnZip it:

unzip master.zip

Rename the python script:

sudo mv wsdd-master/src/wsdd.py wsdd-master/src/wsdd

Copy it to bin:

sudo cp wsdd-master/src/wsdd /usr/bin

Copy the systemd service file to /etc/systemd/system:

sudo cp wsdd-master/etc/systemd/wsdd.service /etc/systemd/system

Reload the service:

sudo systemctl daemon-reload

Start the service:

sudo systemctl start wsdd

Enable the service so it starts at boot:

sudo systemctl enable wsdd

[B] Enable NetBIOS on both Win10 and Ubuntu - This is something Win10 is trying to get away from since it considers it a security issue:

In Win10: Control Panel > Programs and Features > Turn Windows features on or off > SMB 1.0/CIFS File Sharing Support > SMB 1.0/CIFS Client.

In Ubuntu: Edit /etc/samba/smb.conf and right under the workgroup = WORKGROUP line add this one:

server min protocol = NT1

You would think that a simple restart of the service would be enough - and it might be in your case:

sudo service smbd restart

But NetBIOS is a relic of a bygone era and you might have to reboot the box.

NetBIOS is a nasty thing to work with so you may need to do some other tweaks to get it working.

jjs avatar
cn flag
jjs
Thanks for that reply. I've done most of that in one of the guides I was following. I don't think I have a discovery issue at this point as I can see and access the linux server from win10. The issue I have is that the public share folder I created does not show up ( path = /test in smb.conf)
Morbius1 avatar
es flag
Edit your original post and add the output of this command from the server: `testparm -s`
Morbius1 avatar
es flag
I reread your post. It looks like you are creating shares in smb.conf and from Nautilus. We need to see the output of this command as well: `net usershare info --long`
Score:0
cn flag

This worked for me, it is similar to option A given by @Morbius1, but much easier:

$ sudo apt install wsdd

$ sudo systemctl enable wsdd
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.