17

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 ?

4 Answers 4

7

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?

1
  • Just for the record: I found that my problem was related to Nikola's comment ((nikolagotovac) wrote on 2016-05-24: ) on @Alan's answer link. The authentication request is for the LOCAL account and not for a remote user in the Windows box. Commented Jun 1, 2016 at 14:56
6

Its possible you may be being affected by this bug

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.

8
  • nautilus-share is definitely installed. I'll try the other solutions and report with my results.
    – jmbouffard
    Commented Jul 11, 2011 at 11:22
  • I came back to this question to try the other solutions but it seems I need to modify smb.conf on the server. In my case it's on a DLink DNS323 so I don't have access to the file.
    – jmbouffard
    Commented Aug 18, 2011 at 15:35
  • I can't believe I cannot access to a DNS-323, which is quite a popular product, from Nautilus on a Ubuntu machine, this should have been fixed a long time ago!
    – jmbouffard
    Commented Aug 18, 2011 at 15:37
  • Hi can you check which gvfs packages you have installed I have gvfs,gvfs-fuse,gvfs-bin,gvfs-backends and libgvfscommon0
    – Allan
    Commented Aug 18, 2011 at 22:40
  • 1
    Basically whats happened is the samba in Ubuntu has been updated to use a more secure method of authentication which the NAS doesn't understand the solution is to tell samba to use the older less secure method of authentication by editing the smb.conf file on your computer(s) so they can connect with the NAS succesfully the additional auth lines suggested by James pakko "allow" the samba client on your system 3 more authentication types to try which are less secure than the default connection method.
    – Allan
    Commented Aug 19, 2011 at 15:47
5

my solution was: reinstall gvfs :

 sudo apt-get  install gvfs-*

stop nautilus:

 nautilus -q

start nautilus again:

 nautilus
2
  • I manually compiled the latest samba, but something was wrong so that I couldn't open smb in nautilus. It was solved this way.
    – sjlee
    Commented Jun 10, 2020 at 5:29
  • i already had samba-client samba-common and cifs-utils and i resolved the issues with only dnf install gfvs-smb on fedora and restarting nautilus (aka files) Commented Mar 14, 2023 at 4:39
2

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

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .