Windows 10 Share not accessible from Ubuntu 16.04 LTS

sharingubuntu 16.04windows 10

I am trying to connect/mount a point on my Ubuntu 16.04 LTS VM to a share on the host which is a Windows 10 with no success. The goal is so that I can download files on Ubuntu(VM) and transfer them to the Windows host. The Windows share is accessible from other windows hosts on the same network but not from the Ubuntu VM, even though there is network connectivity as I can ping(VM configured in "Bridged" mode).
I have tried running:

sudo mount -t cifs -o username=username //ip_address/Windows_Share /mount/point/Ubuntu

This comes back with an error indication that the host is down, which is not true since the share running on it can be accessed by other Windows boxes.
I have read some posts about it and someone mentioned there is a conflict with the SMB version used by Ubuntu and Windows 10, which now disables SMB1. So they advised to run the below to check:

smbclient -L <windows_ip> -U <windows_user> -d 256

And indeed I have got an error:

protocol negotiation failed: NT_STATUS_CONNECTION_RESET

Then I run:

smbclient -L <windows_ip> -U <windows_user> -m SMB2

And yet another error:

NetBIOS over TCP disabled — no workgroup available

Can anyone suggest a fix/advise how I can mount the Windows share on Ubuntu?

Best Answer

Sounds like you are on the right track. If the problem is related to SMB1 the following will resolve your issue.

First make a copy of smb.conf

cp /etc/samba/smb.conf /etc/samba/smb.conf.orig

After making the copy

sudo gedit /etc/samba/smb.conf

Feel free to use vi/vim/nano if you do not prefer gedit

In the file, add the following in the [global] section

client min protocol = SMB2
client max protocol = SMB3

After saving the edits to the file. Restart SMB

sudo service smbd restart

If this does not work please include errors.

Related Question