Cannot connect to Samba share from Nautilus

I have Ubuntu 10.04 and I would like to connect to my Samba shares which are on a DLink DNS323.

From Nautilus in "Places" -> "Network" I can easily navigate to the DND323 and see the available shares. When I select one of the password-less share I have access to it as expected. When I want to connect to a password protected share, it doesn't work. All it does is asking the password again and again.

I tried to mount the share manually and it worked the first time with

sudo mount -t cifs -o username=user,password=pass //xxx.xxx.xxx.xxx/share ~/share

Any idea why this is not working in Nautilus ?


I found a simple answer in this ubuntuforums.org thread

The newer versions of samba are not supporting anymore by default the LANMAN authentication scheme that is used by the DLink DNS323. To correct this issues, the only thing to do is:

Edit /etc/samba/smb.conf

Find the [global] section, and insert this line:

client lanman auth = yes

You don't even have to reboot and you will be able to mount your shared folders with Gnome Nautilus.

This is also required to connect to the samba shares of another Lucid box (if they're password protected). Ironic, isn't it?


Its possible you may be being affected by this bug

  • Gvfs keeps asking for password when trying to mount Samba Share

There are a few "fixes" which are proposed in the comments of the bug I'll summarise them here.


  • You can edit smb.conf

This is what we used at one time to fix this problem. Easy enough to try.

gksudo gedit /etc/samba/smb.conf

Find this section in the file:

####### Authentication #######
# “security = user” is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba-HOWTO-Collection/ServerType.html
# in the samba-doc package for details.
#security = user

Uncomment the security line, and add another line to make it look like this:

####### Authentication #######
# “security = user” is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba-HOWTO-Collection/ServerType.html
# in the samba-doc package for details.
security = user
username map = /etc/samba/smbusers

suggested by Richard Garvin


  • Another edit to smb.conf

in the global section below name resolve order add these lines

lanman auth = yes
client lanman auth = yes
client plaintext auth = yes

Suggested by James Pakko


  • Lastly the nautilus-share package is not installed by default make sure this is installed

This was suggested by Karl Kropf

Today I just happened to have exactly the same problem spooky didn't know you could actually catch a bug by being told about it 0.o

This last suggestion installing nautilus-share fixed my problem hopefully it will do the same for you.


my solution was: reinstall gvfs :

 sudo apt-get  install gvfs-*

stop nautilus:

 nautilus -q

start nautilus again:

 nautilus

For Ubuntu 12.04 Samba 3.6.3, must also add:

client NTLMv2 auth = No

or setting

client lanman auth = Yes

will not be used as

client NTLMv2 auth

defaults to Yes and forces client lanman auth to No.

Check with testparm -v