Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Fresh Ubuntu 21.10 installation – can't access a Windows 10 share

I’ve got a fresh install of Ubuntu Desktop 21.10 and it can’t access Windows Network and a Windows share. Other Windows PC can access the share.

When I click on the share, Ubuntu shows "Opening [share name] SMB" indefinitely. After a few minutes there’s a time out error. And that’s it.

I disabled the firewall and installed Samba. It didn’t help. What can I do?

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

I have a slight variation you might be interested in.

The samba client which the file manager uses to browse then connect to SMB servers will negotiate with the server to determine the best smb dialect to use between 2.1 and 3.X automatically. But a bug in the gvfs backend stops this process by forcing the connection to SMB1.

You can bypass this bug 2 ways:

Ask for the server and share by using Connect to Server in the file manager using one of these formats:

smb://asus-vivopc.local/pliki 
smb://192.168.X.X/pliki 
smb://asus-vivopc/pliki

You will connect with SMB3.

You can then bookmark that for future use.

You can connect with a cifs mount which doesn’t use the samba client or gvfs at all.

If you already have something defined in fstab and the mount point is in your home directory and you want the ability to mount and unmount on demand I would

Unmount the share: sudo umount /home/daerragh/Share

Change the line in fstab to something like this:

//asus-vivopc.local/pliki /home/daerragh/Share cifs uid=daerragh,noauto,user 0 0

Then make systemd happy:

sudo systemctl daemon-reload
sudo systemctl restart remote-fs.target

Note: I purposely did not add a vers=xxx option since cifs determines the best version to use on it’s own between 2.1 and 3.X. The way it is written above it will connect to Win10 using SMB3.X

Note2: It’s customary when accessing a share that allows guest access to supply the "guest" option in fstab:

//asus-vivopc.local/pliki /home/daerragh/Share cifs guest,uid=daerragh,noauto,user 0 0

But if it works without it that’s fine.

noauto == prevents the share from mounting at boot

user == allows an ordinary user ( not sudo ) the ability to mount the share.

uid=daerragh == will make you the owner of the mount so you can write to it.

Because the mount point is in your home directory it will create an icon on the side panel of your file manager labeled "Share" – in this case – that is "actionable".

Click on it and it will go to fstab to find out how to mount it.
THe same icon can be used to unmount it when no longer required.

You can also use a systemd automount feature which is slightly more complicated and you have to change the mount point location.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading