LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   SAMBA host... print with cups? (https://www.linuxquestions.org/questions/slackware-14/samba-host-print-with-cups-316918/)

hraposo 04-25-2005 06:13 AM

SAMBA host... print with cups?
 
When I trie print with samba and cups in slack10.1 appears the message:

"Unable to connect to SAMBA host, will retry in 60 seconds...ERROR: Connection failed with error NT_STATUS_ACCESS_DENIED"
I think that I must do anything in /etc/hosts

But, what I must do?

hraposo 04-25-2005 12:12 PM

I think you must add name_machine to /etc/hosts

hraposo 04-25-2005 12:13 PM

Just the name, and the ip?

gbonvehi 04-25-2005 04:31 PM

That error happens when CUPS connects to the server machine but it can't login succesfully or the user that logins doesn't have print permissions.
/etc/hosts are just "aliases" for some ips.

Until you discovery this values, you could use the command line to test for print
Code:

echo -en "\rHello\r\f" | smbclient "//NetBIOS-hostname/share" "password" -c "print -" -N -U "username" -W "workgroup"
You can ommit -U username, -W workgroup or "password" if not needed.
(that code should print Hello in a page and eject it).

davidsrsb 04-26-2005 12:13 AM

You can print to a printer on the server through Samba, but I find that printing directly to CUPS on the server on the IPP port works much faster, as you are bypassing several protocol layers.

I don't think that the /etc/hots is the problem, it looks more like a problem with cups.conf or samba passwords.

hraposo 04-26-2005 04:22 AM

Whith the command:
echo -en "\rHello\r\f" | smbclient "//NetBIOS-hostname/share" "password" -c "print -" -N -U "username" -W "workgroup"

The ptinter prints fine!!!

hraposo 04-26-2005 04:25 AM

Maybe the problem its cups.conf because I dont't use passwords in samba.

hraposo 04-26-2005 04:54 AM

all the lines of cups.conf are comment

davidsrsb 04-26-2005 06:26 AM

/etc/cups/cupsd.conf needs a bit of tuning to allow remote access to the cups server. There is a location section which needs to have something like 192.168.0.0/24 to allow access from the local network.

gbonvehi 04-26-2005 06:49 AM

Quote:

Originally posted by hraposo
Whith the command:
echo -en "\rHello\r\f" | smbclient "//NetBIOS-hostname/share" "password" -c "print -" -N -U "username" -W "workgroup"

The ptinter prints fine!!!

Put the exact line you gave to print (ommit the password if you want ;) ) so we can tell you how to configure cups.

killerbob 04-26-2005 07:38 AM

Just out of curiosity, since I'm a little unclear as to your exact setup....

Do you have a Windows system that's sharing the printer through Samba? If so, which version of Windows is it?
Do you have a *nix system that's got CUPS, and you're trying to share to Windows systems through Samba?


It's important to ask. Older versions of Windows do not support IPP, but Win2k and higher all have innate support for IPP, including Server capability. (maybe not XP Home, but I never had that). You may find it's a whole lot easier to just set up IPP properly. IPP is stabler and faster than Samba printing.

davidsrsb 04-26-2005 10:15 AM

XP Home works just fine with IPP and WinME can be persuaded to use it too. As said above it is much simpler and faster than going through Samba.

Getting XP Home to work with Samba is more of a challenge, thanks to the XP Home PC having a habit of sending the "Full Name" instead of the "Username" when authenticating.

killerbob 04-26-2005 10:50 AM

XP home prints TO IPP just fine. What I need to look into is whether it's able to SERVE IPP.

Well, no, I don't need to look into that. I'm quite happy with CUPS. :)

The question is whether he's sharing a printer from a winbox through Samba, and whether it would be possible to share that printer through IPP instead of Samba.....

hraposo 04-27-2005 02:35 AM

I put smbclient "//Pentium/Impressora" " -c "print -" -N
where mozilla have lpr, and the printer works but print strange caracters

gbonvehi 04-27-2005 09:17 AM

Then by using smb://Pentium/Impressora as Device URI in CUPS should work.
You can also try smb://YourWorkgroup/Pentium/Impressora

Oh, and also on Device choose Windows Printer via SAMBA

And I don't know if this can affect cups, but I would choose printing=cups in /etc/samba/smb.conf


All times are GMT -5. The time now is 02:54 AM.