Ubuntu

Jaunty 9.04 Blind to XP's Shared Network Printer

Reported by Ed Comer on 2009-04-27
30
This bug affects 4 people
Affects Status Importance Assigned to Milestone
samba (Ubuntu)
Undecided
Unassigned
system-config-printer (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: smbclient

I am using Ubuntu Jaunty 9.10 e/w all current updates.
smbclient: Installed: 2:3.3.2-1ubuntu3

First let me state that the Windows Networked/Shared printer can be utilized just fine by two other Linux computers on mine - (1) a Dell 910 Netbook running Ubuntu 8.04 and another computer running Xubuntu 8.10. I print just fine from these machines, but NOT Jaunty 9.04.

There are a number of posts in GENERAL regarding Jaunty having various problems with Networked Printers, but none quite like my problem. I feel that this is actually a networking/SAMBA issue, so that is why I posted it here.

When I try to add a printer attached to and shared on my Windows XP box with System->Administration->Printing, New->Network Printer->Windows Printer via SAMBA, Browse - I get right up to where clicking the little gray diamonds should reveal a networked printer and Poof the dialog crashes and is gone.

Note: Squirrel is the hostname of my Windows XP box.

If I browse Places->Network->Windows Network->MSHOME->SQUIRREL, the Windows shares are seen but without a printer. Instead there is a networked folder named Print$ which I suspect is the printer being incorrectly recognized. I have attached an image of what I see in the browse network window to my XP machine.

Ed Comer (celem) wrote :
Jeruvy (jeruvy) wrote :

I'm curious about the actual version of smbclient in question here.

I have TWO 8.04 LTS one server, one desktop both are running

$ smbclient --version
version 3.0.28a

Ed Comer (celem) wrote :

Here is my Ubuntu 9.04 Jaunty version output, collected two different ways:
ecomer@lsquirrel:~$ apt-cache policy smbclient
smbclient:
  Installed: 2:3.3.2-1ubuntu3
  Candidate: 2:3.3.2-1ubuntu3
  Version table:
 *** 2:3.3.2-1ubuntu3 0
        500 http://us.archive.ubuntu.com jaunty/main Packages
        100 /var/lib/dpkg/status
ecomer@lsquirrel:~$ smbclient --version
Version 3.3.2
ecomer@lsquirrel:~$

I am coming from a related discussion on UbuntuForums that concerns similar behaviour (although related to folders)

Having upgraded 3 systems from 8.10 to 9.04 (2 physical, 1 virtual) I have been seeing the exact same behaviour on them all. The SMBClient set up that was working perfectly on 8.10 was not functioning on 9.04 after upgrade.

It would not show member of the workgroup or domain ("smbtree" would come back empty), but I could navigate directly to a folder on a machine I knew to be shared using the nautilus address bar (smb://<ip address>/<shared folder>).

On all three systems I found that installing Firestarter, allowing ports 137-149 and 445 as well as editing "/etc/firestarter/inbound/setup" as shown below cured the issue.

From:
# Allow response traffic
$IPT -A INBOUND -p tcp -m state --state ESTABLISHED,RELATED -j ACCEPT
$IPT -A INBOUND -p udp -m state --state ESTABLISHED,RELATED -j ACCEPT

To:
# Allow response traffic
$IPT -A INBOUND -p tcp -m state --state ESTABLISHED,RELATED -j ACCEPT
$IPT -A INBOUND -p udp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT

I am not sure why this should have any effect, I did not need to do this on Intrepid.

SMBClient info:
user@machine:~$ apt-cache policy smbclient
smbclient:
  Installed: 2:3.3.2-1ubuntu3
  Candidate: 2:3.3.2-1ubuntu3
  Version table:
 *** 2:3.3.2-1ubuntu3 0
        500 http://gb.archive.ubuntu.com jaunty/main Packages
        100 /var/lib/dpkg/status
user@machine:~$ smbclient --version
Version 3.3.2

My apologies if this is not related.

Jakob Unterwurzacher (jakobunt) wrote :

Just to confirm this:
In Intrepid, printing to a Windows-XP-shared printer worked.
Now i upgraded to Jaunty and it's broken.

Attached is a network capture when trying to "browse" the printers in the add printers dialog (see next post for screenshot).

Jakob Unterwurzacher (jakobunt) wrote :

Well, me too.
In Intrepid, printing to a Windows XP shared printer worked.
I upgraded to Jaunty, now, it's broken.

Attached a packet capture of trying to browse the printers in the add printers dialog (see next post for screenshot).

Jakob Unterwurzacher (jakobunt) wrote :

Sorry for the double post, launchpad gabe me an error on the first try.

Here is the screenshot of the dialog i was capturing the network traffic for.

The popup just says something like "no printers found".

Ed Comer (celem) wrote :

I ran the Live-CD version of the 64 bit version of Ubuntu 9.04 as an experiment to see if the problem existed there also. This bug is NOT present in the 64-bit version. I can easily create a networked printer resident on a Windows XP machine on amb64 Ubunto 9.04.

Sofia Tahseen (sofia.tahseen) wrote :

I have the same bug on jaunty-armel... I have a printer connected to my other Jaunty linux box(Jauntyx86) and I try to print to that printer from Jaunty-armel. "Whenever I go to System->Administration->Printing, New->Network Printer->Windows Printer via SAMBA, Browse - I get right up to where clicking the little gray diamonds should reveal a networked printer and Poof the dialog crashes and is gone." This is the exact same thing I get when I connect my printer to Jauntyx86 box and print from Jaunty-armel.

Ed Comer (celem) wrote :

Workaround found, but bug remains:
I used my Windows box IP address instead of Browsing for the printer. This permitted me to go to the next steps and created a printer, although it didn't work, i.e. the test page didn't print. However, I then clicked a change URI button and it presented another opportunity to Browse. This time browsing found the Windows printer, correctly changed the path and then the test page printed. Screen snapshot is attached.

Thierry Carrez (ttx) wrote :

Even if the root cause might be in samba, the dialog crash is certainly a system-config-printer issue.

Thierry Carrez (ttx) wrote :

@Jakob, Ed:
Does adding "name resolve order = bcast host lmhosts wins" to your /etc/samba/smb.conf file change anything to the issue ?

Changed in samba (Ubuntu):
status: New → Incomplete
Ed Comer (celem) wrote :

I have changed the name resolve order in the past to resolve a total inability to browse Windows shares, but that is not the issue in this bug, consequentially, I have not changed the resolve order in smb.conf. I can access Windows shares without problem, transfer files, etc. This bug deals solely with the inability to create a Ubuntu printer from a networked Windows shared printer.

Tim Waugh (twaugh) wrote :

> the dialog crash is certainly a system-config-printer issue.

It is libsmb that segfaults. If system-config-printer is using the libsmb API correctly, this is a libsmb bug.

Crash happens in libsmb, closing system-config-printer task and leaving samba (source of libsmb) task open.

Changed in system-config-printer (Ubuntu):
status: New → Invalid
Thierry Carrez (ttx) wrote :

OK, would someone have evidence of that libsmb crash/segfault ? I could use a stack trace, crash dump or logged segfault... I don't have XP shared network printers to reproduce.

Ed Comer (celem) wrote :

Well - if you'll give me a clue as to how to obtain that I will try. I understand how to do that using gdb on a program that I invoke but what process for libsmb ?

Thierry Carrez (ttx) wrote :

@Ed:
Try enabling apport and see if it catches something: https://wiki.ubuntu.com/Apport

Ed Comer (celem) wrote :

Apport grabbed the crash and I reported it, linking it to existing bug report 361629. Related bugs are 329974, 344218, 359088, 360524 and 361629. Of interest, I had successfully built a windows shared printer using the workaround that I described in this bug report, 368273, but attempted adding a second Windows shared printer while apport was running. The printer correctly appeared in the dialogue. When I deleted the printer and tried again, the bug reappeared, this time captured by apport.

Thanks @Ed Comer in comment 10 - the workaround works for me!

@Thierry Carrez:
Does adding "name resolve order = bcast host lmhosts wins" to your /etc/samba/smb.conf file change anything to the issue ?

No, unfortunately.

Ed Comer (celem) wrote :

I will be unable to report further on the bug as I replaced 32-bit Ubuntu 9.04 with the 64-bit Ubuntu 9.04 on the exact same hardware, in the exact same environment and the bug is NOT present. With 64-bit Ubuntu 9.04 I easily created a networked shared printer resident on a Windows XP machine without incident. In fact 64-bit Ubuntu 9.04 works so well that I don't know why I was previously sticking with 32-bit. The reports in flash incompatibility, etc., have not proven to be true, at least for me. I am quite impressed with 64-bit Ubuntu 9.04.

64-bit Ubuntu 9.04's apparent immunity to this bug is telling in and of itself.

the motorman (rdoctors) wrote :

I do not know where to post this so forgive me if it is in the wrong place. I had a almost perfect printer system on a winxp machine accessed by my Ubuntu 8.4 when i upgraded to 9.04 I can not print. I can work with all the folders on my winxp machine from the Ubuntu machine. The printer seems to have become invisible to the Ubuntu machine. I am a newbie and although technically Ok I wanted to use Ubuntu so I wouldn't have all the irritations of a winxp system.. now It seems I cannot escape ..
I do not have Samba connected printers showing in the System>admin>printing dialog.. it does show other options none of which seem to apply, if I pick Networked printers then even with all the variations of IP for winxp ect I get nowhere. Is there a way to diagnose this bug ? If anyone can give me detailed info on doin g so I will be pleased to try. Maybe the bug can then be fixed for everyone.

Ed Comer (celem) wrote :

The Motorman - see post above - should cure your problem: "Workaround found, but bug remains:
I used my Windows box IP address instead of Browsing for the printer. This permitted me to go to the next steps and created a printer, although it didn't work, i.e. the test page didn't print. However, I then clicked a change URI button and it presented another opportunity to Browse. This time browsing found the Windows printer, correctly changed the path and then the test page printed. Screen snapshot is attached.".

Thanks, I tried the IP address did not make any difference cannot find
printer..The browse doesn't help either, it doesn't "browse " it seems to
want me to enter the location.
My printer selection doesn't show Samba connected printers and I am pretty
sure 8.4 did..

On Fri, May 29, 2009 at 7:24 PM, Ed Comer <email address hidden> wrote:

> *** This bug is a duplicate of bug 329974 ***
> https://bugs.launchpad.net/bugs/329974
>
> The Motorman - see post above - should cure your problem: "Workaround
> found, but bug remains:
> I used my Windows box IP address instead of Browsing for the printer. This
> permitted me to go to the next steps and created a printer, although it
> didn't work, i.e. the test page didn't print. However, I then clicked a
> change URI button and it presented another opportunity to Browse. This time
> browsing found the Windows printer, correctly changed the path and then the
> test page printed. Screen snapshot is attached.".
>
> --
> Jaunty 9.04 Blind to XP's Shared Network Printer
> https://bugs.launchpad.net/bugs/368273
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in “samba” source package in Ubuntu: Incomplete
> Status in “system-config-printer” source package in Ubuntu: Invalid
>
> Bug description:
> Binary package hint: smbclient
>
> I am using Ubuntu Jaunty 9.10 e/w all current updates.
> smbclient: Installed: 2:3.3.2-1ubuntu3
>
> First let me state that the Windows Networked/Shared printer can be
> utilized just fine by two other Linux computers on mine - (1) a Dell 910
> Netbook running Ubuntu 8.04 and another computer running Xubuntu 8.10. I
> print just fine from these machines, but NOT Jaunty 9.04.
>
> There are a number of posts in GENERAL regarding Jaunty having various
> problems with Networked Printers, but none quite like my problem. I feel
> that this is actually a networking/SAMBA issue, so that is why I posted it
> here.
>
> When I try to add a printer attached to and shared on my Windows XP box
> with System->Administration->Printing, New->Network Printer->Windows Printer
> via SAMBA, Browse - I get right up to where clicking the little gray
> diamonds should reveal a networked printer and Poof the dialog crashes and
> is gone.
>
> Note: Squirrel is the hostname of my Windows XP box.
>
> If I browse Places->Network->Windows Network->MSHOME->SQUIRREL, the Windows
> shares are seen but without a printer. Instead there is a networked folder
> named Print$ which I suspect is the printer being incorrectly recognized. I
> have attached an image of what I see in the browse network window to my XP
> machine.
>

--
Far better one rose to the living than sumptuous wreaths to the
dead...Rachael Doctors

twrock (taiwan-rock) wrote :

I was successful with this workaround. Hopefully it will work for others and it will be something even a newbie can do without having to figure out what their "Windows IP" is. So until there is a fix, ....

Click Main Menu>System>Administration>Printing
Click New>Network Printer>Windows Printer via SAMBA
Hit the "Browse" button. "SMB Browser" box pops up. Note the names under the headings labeled Share and Comment. (So in my case, under "Share" was MSHOME and under "Comment" was DESKTOP1.)
Cancel out of the "SMB Browser" window. Click in the entry box beside smb:// and enter those name in this form: ShareName/CommentName/
Click "Browse" again. This time the list should be populated in the "SMB Browser" popup box (after a short wait) with the names of your shared printers. Choose the one you want and proceed with the installation.

the motorman (rdoctors) wrote :

I don't even have the printing selection anymore!! And I never had the
windows printer via Samba.. I am going to reload 9.04 completely and wait..
I have spent much too much time on this already. Ubuntu is great for
everything it does but for even a moderate techy like me the command window
functions have too many pitfalls.
ron

On Fri, Jun 5, 2009 at 10:29 PM, twrock <email address hidden> wrote:

> *** This bug is a duplicate of bug 329974 ***
> https://bugs.launchpad.net/bugs/329974
>
> I was successful with this workaround. Hopefully it will work for others
> and it will be something even a newbie can do without having to figure
> out what their "Windows IP" is. So until there is a fix, ....
>
> Click Main Menu>System>Administration>Printing
> Click New>Network Printer>Windows Printer via SAMBA
> Hit the "Browse" button. "SMB Browser" box pops up. Note the names under
> the headings labeled Share and Comment. (So in my case, under "Share" was
> MSHOME and under "Comment" was DESKTOP1.)
> Cancel out of the "SMB Browser" window. Click in the entry box beside
> smb:// and enter those name in this form: ShareName/CommentName/
> Click "Browse" again. This time the list should be populated in the "SMB
> Browser" popup box (after a short wait) with the names of your shared
> printers. Choose the one you want and proceed with the installation.
>
> --
> Jaunty 9.04 Blind to XP's Shared Network Printer
> https://bugs.launchpad.net/bugs/368273
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in “samba” source package in Ubuntu: Incomplete
> Status in “system-config-printer” source package in Ubuntu: Invalid
>
> Bug description:
> Binary package hint: smbclient
>
> I am using Ubuntu Jaunty 9.10 e/w all current updates.
> smbclient: Installed: 2:3.3.2-1ubuntu3
>
> First let me state that the Windows Networked/Shared printer can be
> utilized just fine by two other Linux computers on mine - (1) a Dell 910
> Netbook running Ubuntu 8.04 and another computer running Xubuntu 8.10. I
> print just fine from these machines, but NOT Jaunty 9.04.
>
> There are a number of posts in GENERAL regarding Jaunty having various
> problems with Networked Printers, but none quite like my problem. I feel
> that this is actually a networking/SAMBA issue, so that is why I posted it
> here.
>
> When I try to add a printer attached to and shared on my Windows XP box
> with System->Administration->Printing, New->Network Printer->Windows Printer
> via SAMBA, Browse - I get right up to where clicking the little gray
> diamonds should reveal a networked printer and Poof the dialog crashes and
> is gone.
>
> Note: Squirrel is the hostname of my Windows XP box.
>
> If I browse Places->Network->Windows Network->MSHOME->SQUIRREL, the Windows
> shares are seen but without a printer. Instead there is a networked folder
> named Print$ which I suspect is the printer being incorrectly recognized. I
> have attached an image of what I see in the browse network window to my XP
> machine.
>

--
Far better one rose to the living than sumptuous wreaths to the
dead...Rachael Doctors

I think the problem is solved: I updated the system with third party canonical repositories on, and the bug disappeared. Now I can see the windows printers.

Kyle Sager (kyle-sager) wrote :

Bug still there as of 8-21-9 for Jaunty 9.04. Using the IP of the shared machine would not work for me.

ANOTHER WORKAROUND: Ubuntu Main Menu > Places >
  -Find the PC with the shared printer, and go into the shared "print$" subdirectory.
  -right click on any file/folder and choose "Properties"
  -Highlight the location, right click, and copy
 (on my network the directory copied was "smb://"PRINTER HOST PC NAME"/print$/ )

You will paste this directory into the printer set-up dialogue.

In New Printer Setup:
  -Choose "Windows Printer Via SAMBA"
  -In "SMB Printer" paste the complete directory you copied.
  This time when you click Browse and begin navigating the triangles, the directory will not bomb-out. Appears as though the pasted directory helps the browser find its way. Worked well repeatedly as I had to reinstall drivers to solve problems.

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

Other bug subscribers