Browsing SAMBA shares impossible

Bug #26933 reported by Celso Pinto
18
Affects Status Importance Assigned to Milestone
nautilus (Ubuntu)
Fix Released
Medium
Ubuntu Desktop Bugs

Bug Description

I'm trying to browse some SAMBA shares in Nautilus and it's getting pretty
impossible to do it. The server is well configured as Windows machines have no
problems.

Going to "Places/Network servers", sometimes shows up "Windows Network",
sometimes it doesn't (and displays an error message).

When the "Windows Network" icon shows up, the workgroup sometime shows up,
mostly it doesn't. Same can be said to the SAMBA server and other machines in
the workgroup.

When I try to manually connect to a known share (i.e.
smb://<ipaddress>/sharename) I get this error message (which is the same for any
problems I've described so far): "Sorry, couldn't display all the contents of
... " so I guess that this is a catch-all message and doesn't point to any
possible problem (maybe include a "More info..." button or *log* the problems
somewhere?)

Also, about browsing, the [homes] share appears in every Windows machine I've
looked at but it doesn't show in Nautilus.

What concrete information must I provide to see if this doesn't find it's way
into Dapper?

System is up-to-date with the latest packages in the Dapper repository.

Revision history for this message
Patrice Vetsel (vetsel-patrice) wrote :

Please try with latest packages (samba/nautilus/gnome-system-tools/libgnomevfs2-0)

Changed in nautilus:
status: Unconfirmed → Needs Info
Revision history for this message
Celso Pinto (cpinto) wrote :

I think it was related to a restrictive firewall I was running on the remote SAMBA box. Weird thing though, that Windows worked without any problems. Anyway, I've turned off the firewall on that box and it's working.

Revision history for this message
Sebastien Bacher (seb128) wrote :

I don't really know of samba works but there seems to be different way to browse a network, going from talking to a PDC or using WINS feature to broadcasting. It's likely than samba (or maybe the gnome-vfs code, would be nice to try with smbc to know if it has the same issue) does use the broadcast way for whatever reason (maybe doesn't know how to talk with the windows controler). If you are interested to figure what is happening exactly could you describe your network (domain, workgroup, pdc used, ...), what your firewall is filtering and try with smbc if it does better than GNOME?

Changed in nautilus:
assignee: seb128 → desktop-bugs
Revision history for this message
Erich Pawlik (erichpawlik) wrote :
Download full text (8.9 KiB)

I have the same problem with the most recent version of Dapper on both PCs.

My network is:
1 Peer-to-Peer-Windows network, no domain controller
2 Four PCs, two with Win XP, two with Dapper (actually dual boot Dapper/Win XP)
3 All four PC are in the same workgroup (called avigato)
4 With smbc, I can browse the local machine, but no remote machines
5 Using <Crl>-L in the the network server browser in Gnome and entering a remote share or the name of a remote host produces the error message "Couldn't display all contents ...". Browsing the local machine is working.
6 Remote Windows printers are not accessible
7 I don't know where to check for the firewall settings. I am just using the default installation.

Regards

Erich

My smb.conf is as follows:

#
# Sample configuration file for the Samba suite for Debian GNU/Linux.
#
#
# This is the main Samba configuration file. You should read the
# smb.conf(5) manual page in order to understand the options listed
# here. Samba has a huge number of configurable options most of which
# are not shown in this example
#
# Any line which starts with a ; (semi-colon) or a # (hash)
# is a comment and is ignored. In this example we will use a #
# for commentary and a ; for parts of the config file that you
# may wish to enable
#
# NOTE: Whenever you modify this file you should run the command
# "testparm" to check that you have not many any basic syntactic
# errors.
#

#======================= Global Settings =======================

[global]

## Browsing/Identification ###

# Change this to the workgroup/NT-domain name your Samba server will part of
   workgroup = avigato

# server string is the equivalent of the NT Description field
   server string = Linux server (%h)

# Windows Internet Name Serving Support Section:
# WINS Support - Tells the NMBD component of Samba to enable its WINS Server
; wins support = no

# WINS Server - Tells the NMBD components of Samba to be a WINS Client
# Note: Samba can be either a WINS Server, or a WINS Client, but NOT both
; wins server = w.x.y.z

# This will prevent nmbd to search for NetBIOS names through DNS.
   dns proxy = no

# What naming service and in what order should we use to resolve host names
# to IP addresses
; name resolve order = lmhosts host wins bcast

#### Debugging/Accounting ####

# This tells Samba to use a separate log file for each machine
# that connects
   log file = /var/log/samba/log.%m

# Put a capping on the size of the log files (in Kb).
   max log size = 1000

# If you want Samba to only log through syslog then set the following
# parameter to 'yes'.
; syslog only = no

# We want Samba to log a minimum amount of information to syslog. Everything
# should go to /var/log/samba/log.{smbd,nmbd} instead. If you want to log
# through syslog you should set the following parameter to something higher.
   syslog = 0

# Do something sensible when Samba crashes: mail the admin a backtrace
   panic action = /usr/share/samba/panic-action %d

####### Authentication #######

# "security = user" is always a good idea. This will require a Unix account
# in this s...

Read more...

Revision history for this message
Erich Pawlik (erichpawlik) wrote :

One thing that might be related to this bug:

If I try to add an smb printer via gnome-cups-manager, a login box pops up asking me to log into "Avigato" which is the workgroup name. There is no security setup requiring to log into the workgroup (I don't know whether this is even possible). Could it be that somewhere is the expectation that you need to log into a domain controller?

Regards

Erich

Revision history for this message
Erich Pawlik (erichpawlik) wrote :

Any relationship to bug #39990?

Regards

Erich

Revision history for this message
none (ubuntu-bugs-nullinfinity-deactivatedaccount) wrote :

I have what I believe to be the same problem. I've configured a subdirectory of my home directory to be shared via samba (see attached smb.conf) . I can browse the directory with smbclient or KDE's konqueror.

If I attempt to access it in nautilus via "Go menu->Network->Windows Network->Jupiter" and then finally click on "junk" I get a dialog saying

Cannot open junk

The filename "junk" indicates that this file is of type "x-directory/smb-share". The contents of the file indicate that the file is of type "desktop configuration file".
[...]

Revision history for this message
none (ubuntu-bugs-nullinfinity-deactivatedaccount) wrote : My smb.conf

My smb.conf

Revision history for this message
none (ubuntu-bugs-nullinfinity-deactivatedaccount) wrote :

This seems to be a thorny subject. On the net, I found another smb.conf that works well with nautilus. Attaching...

Revision history for this message
none (ubuntu-bugs-nullinfinity-deactivatedaccount) wrote : New smb.conf

New smb.conf

Revision history for this message
Patrice Vetsel (vetsel-patrice) wrote :

Seems like they are many hacks by hand in configuration files. So trying to understand what's the problem is impossible.

Please do a fresh/clean install and give us a step by step of what you do to reproduce your bug.
Explain us exactly what you do to share a directory !

Revision history for this message
none (ubuntu-bugs-nullinfinity-deactivatedaccount) wrote :

That's probably a good idea. I purged all samba-related packages, started nautilus, right-clicked on the "themes" directory in my home directory and selected "share folder" from the nautilus menu. I then chose "smb" for file sharing, which led to samba being installed. I then filled out some names for the share. This resulted in the following /etc/samba/smb.conf:

---------------------------
[global]
workgroup = Linux
server string = jupiter
wins support = yes

[Blopp]
path = /home/j/themes
comment = Muppet
available = yes
browseable = yes
public = yes
writable = yes
-----------------------------

I then clicked on "Go->Network" in the Nautilus menu. This takes me to "Windows Network", which I click on.

I'm then presented with an empty Nautilus window.

HOWEVER: If I press Ctrl-L in Nautilus and then type "smb://jupiter" I see the share, just as expected. It seems that the problem is that
Nautilus does not automatically recognize the smb share. To investigate, I do "tcpdump -s 0 -ni wlan0 port 445 or port 137 or port 138 or port 139".

I see packets such as

tcpdump: listening on wlan0, link-type EN10MB (Ethernet), capture size 65535 bytes
00:09:59.653810 IP (tos 0x0, ttl 64, id 2, offset 0, flags [DF], proto: UDP (17), length: 236) 192.168.0.3.138 > 192.168.0.255.138: [udp sum ok]
>>> NBT UDP PACKET(138) Res=0x110A ID=0x345 IP=192 (0xc0).168 (0xa8).0 (0x0).3 (0x3) Port=138 (0x8a) Length=194 (0xc2) Res2=0x0
SourceName=JUPITER NameType=0x00 (Workstation)
DestName=LINUX NameType=0x1D (Master Browser)
[...]

To my complete amazement, for a second I could actually go to "Windows Network" under Nautilus and see the share, but when I try again one minute later it no longer works.

To summarize, when I go to "Windows Network" in Nautilus I get one of the following, seemingly at random, in decreasing order of frequency:

1. A blank page (most common)

2. A popup saying "The contents of the folder could not be displayed".

3. A login window asking me for a user name and password.

4. A correct display of the share (very rare).

I am *very* confused.

Revision history for this message
Erich Pawlik (erichpawlik) wrote :

I was experiencing similar problems. They have disappeared after installing the latest Ubuntu Dapper update (as of May 16).

Regards

Erich

Revision history for this message
Sebastien Bacher (seb128) wrote :

Does anybody still get that issue?

Revision history for this message
Patrice Vetsel (vetsel-patrice) wrote :

"Browsing SAMBA shares impossible" is ok for me

Revision history for this message
none (ubuntu-bugs-nullinfinity-deactivatedaccount) wrote :

It's okay for me too, at least for now. When I tried before, sometimes I thought the bug had been fixed, just to have it reappear.

Anyway, now I can't reproduce the bug at all.

Revision history for this message
Sebastien Bacher (seb128) wrote :

Marking as fixed then, feel free to reopen if that happens again

Changed in nautilus:
status: Needs Info → Fix Released
Revision history for this message
Ricardo L. Febrero (rlfebrero) wrote :

I'm getting exactly the same problems on Ubuntu Gutsy: empty network:///, but I can connect directly to the server. Sometimes no password/user is asked, but then nothing is shown... The best I can get is just that: connecting directly, putting in password & user. Sometimes things get detected, sometimes not. And sometimes, many shortcuts appear, but when I try to open them (like smb:///KAMALEON), it tries to open them with a notepad.

I'm going to attach some screenshot when possible.

Can someone confirm this??
Thanks!

Changed in nautilus:
status: Fix Released → New
Revision history for this message
Sebastien Bacher (seb128) wrote :

Don't reopen a closed issue, open a new bug rather

Changed in nautilus:
status: New → Fix Released
Revision history for this message
Mark Ellse (markellse) wrote :

Please see the bug below showing similar behaviour on Intrepid, together with some steps to isolate the problem.

https://bugs.launchpad.net/ubuntu/+source/nautilus/+bug/316862

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.