LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 07-16-2004, 04:17 AM   #1
1kyle
Member
 
Registered: Feb 2004
Location: 'Ol Blighty
Distribution: SLED 10, SUSE 10.3
Posts: 722

Rep: Reputation: 32
CUPS Shared Printer problems Kernel 2.6


Hardware details -- all in the same LAN IP address range 192.168.7.2/24


LAPTOP A (SUSE 9.1 no printers attached)

DESKTOP B with local printer (SUSE 9.1) Blackdog
DESKTOP C with local printer (SUSE 9.1) Greyfox
DESKTOP D with local printer (WINDOWS XP PRO) Gingercat


LAPTOP A wants to use printers on DESKTOP B, DESKTOP C and DESKTOP D

Now setting up the LAPTOP as a CUPS CLIENT I get no problem connecting up to use the printer(s) on ONE machine (YAST Printer setup) whichever box I want --even the SAMBA printer shares are OK.

BUT if I want to add another (MACINE not Printer) it deletes the configuration and starts again -- even setting up to connect to the SAMBA SHARE (For the Windows box) the setup dialog deletes the previous configuration. There's no option to ADD extra queues / remote machines .

I can access as many printers as I like so long as they are connected to ONE BOX.

Note all these printers are LOCALLY attached to their respective machines.

I don't seem as a CUPS CLIENT to be able to access more than ONE BOX.

Is this a restriction or have I done something wrong or do I have to set one box up as a ROUTER BOX which I don't really want to do.

Surely I should be allowed to access ANY RESOURCE anywhere in the enitire NETWORK (provided I have the necessary permission authority).

Note on SUSE 9.1 there's no KPPrintersetup or setup printers via KDE -- It's all done in YAST.

Thanks

Last edited by 1kyle; 07-16-2004 at 04:26 AM.
 
Old 07-17-2004, 05:25 AM   #2
1kyle
Member
 
Registered: Feb 2004
Location: 'Ol Blighty
Distribution: SLED 10, SUSE 10.3
Posts: 722

Original Poster
Rep: Reputation: 32
I see plenty of people have viewed this topic -- but no suggestions.

I'm surely not the only person who surely needs to connect a computer to access a printer on more than 1 remote Box -- and what do you guys do in a network of mixed Windows and Linux machines when you need to access LOCAL printers on the remote machines.

CUPS seems to allow you only to configure print share access to 1 REMOTE machine , and if then you want to add SAMBA print shares you then lose your CUPS configuration for the remote Linux box.

Thanx
 
Old 07-17-2004, 06:12 AM   #3
andrewdodsworth
Member
 
Registered: Oct 2003
Location: United Kingdom
Distribution: SuSE 10.0 - 11.4
Posts: 347

Rep: Reputation: 30
Well I have pretty much the same setup as you (SuSE 9.0 rather than 9.1) but no local printers but using 2 remote Windows printers via samba client.

What I did was use the web CUPS admin tool - first you need to add a printer admin user before you can use this tool - in a shell as root 'lppasswd -a linux_user_name'.

Then - 'localhost:631 in Konqueror' - this should bring up a nice web interface - click on Manage Printers - you should see your existing printer there - click on add printer ..

at this point it prompts you for the username and password that you set up using lppasswd (moment of panic for me as I had to try and remember the password which was different from my linux one!)

Fill in the name location and description with whatever you want and Continue - for Samba printers device is Windows samba printer. When you get to the url the only configuration I found that worked for me was
smb://win_userassword@win_machinename/win_printer_sharename

You then need to select the model and diriver for your selected printer - on my CUPS installation there are separate lists for HP and Hewlett Packard so if it's an HP check both lists for the model - use the recommended driver if there is one. That's it - if you click on Printers again it should show you the printer active accepting jobs - try a test print. (Then when nothing happens turn on the Windows machine!).

For remote linux CUPS printers I don't know the answer (yet - as it's one of the things on my to-do list) but presumably if you set up one of the remotes first then look at the configuration in the CUPS web manager you should be able to work it out (if it's there).

Good luck

Last edited by andrewdodsworth; 07-17-2004 at 07:00 AM.
 
Old 07-17-2004, 06:22 AM   #4
1kyle
Member
 
Registered: Feb 2004
Location: 'Ol Blighty
Distribution: SLED 10, SUSE 10.3
Posts: 722

Original Poster
Rep: Reputation: 32
Thanks Andrew -- That's great for the Windows printers -- works OK

Now for the Linux one's. I see your in the UK as well - so being a horrible rainy Saturday I'll try and investigate this further -- Can't wait for the Footy to start again --Aug 15 Chelsea V Man Utd -- great game for season start.

Thanks again
-K
 
Old 07-17-2004, 07:51 AM   #5
andrewdodsworth
Member
 
Registered: Oct 2003
Location: United Kingdom
Distribution: SuSE 10.0 - 11.4
Posts: 347

Rep: Reputation: 30
The sun's now shining but what the heck - had a look at YaST (I've got SuSE 9.0 also on a laptop and I haven't bothered adding printers yet) and if you go into printers it has already installed 'Listen to remote CUPS servers..' is there but like you I can't get it to see any! Although my main server is linux running CUPS server and is the one that has the remote Windows printers, to my mind they should also be available for remote CUPS clients to attach to.

Anyway went to configure (top box) .. Other kind of setup (bottom button) .. Other Printer (set URL) .. smb://userassword@server/queue .. and the rest of it follows the CUPS configuration routine and it works!

Now in YaST printers I have 'New Queue for Already Configured Printer' in the top box and my new installed printer in the bottom box.

Now back to my server to see what YaST can find:

Well apart from listen to remote it has under Already installed printers (and I guess you have something similar)
- not Yast2 -
Configured as:
queue1, queue2

Now to hit change .. Advanced .. CUPS server settings

Browsing is on
Access .... tried adding IP address of laptop - no dice - time to read the manual!

Well at least I now know that you can successfully use YaST to add a Windows printer!
 
Old 07-17-2004, 11:43 AM   #6
andrewdodsworth
Member
 
Registered: Oct 2003
Location: United Kingdom
Distribution: SuSE 10.0 - 11.4
Posts: 347

Rep: Reputation: 30
Yes - I see what you mean. Ithought that I'd cracked it by configuring the client to use CUPS client only and then attaching to the remote CUPS server. However, as you pointed out you can only have one server. In my case, that server does in fact have connections to all the remote printers. So therefore I can print to any of the printers it can see. Therefore could you set up one of your linux desktops to be able to print to all your printers and then use that as a gateway for the laptop as CUPS client only.

A nasty fixit but until I work out how to get the CUPS to CUPS stuff working it may do.
 
Old 07-17-2004, 04:22 PM   #7
andrewdodsworth
Member
 
Registered: Oct 2003
Location: United Kingdom
Distribution: SuSE 10.0 - 11.4
Posts: 347

Rep: Reputation: 30
Got it!

You need to make sure that all linux machines are running CUPS server and in their /etc/cups/cupsd.conf find the bits that relate to Browsing and <location />

In server with printer you want to share

BrowseAllow @LOCAL
Browsing On
<Location />
Order Deny,Allow
Deny From All
Allow From 127.0.0.1
Allow From 127.0.0.2
Allow From 192.168.1.0/24
Allow From @LOCAL
</Location>

{192.168.1.0 is my local network}

In client

BrowsePoll 192.168.1.250:631

where 192.168.1.250 is the IP address of the server with the printer.

If you want to poll more than one print server I think you just add more addresses.

Restart cups and it'll find all the printers on the remote server.

I also found out that you can use a shell command to add remote printers :

lpadmin -p <printername> -E -v ipp://192.168.1.250/printers/<printername>

{replace 192.168.1.250 with the IP address of the server}

Once again you can add more remote printers

This is appears to be persistent - I now need to undo that one now I've found the other way as I've got duplicate printers now!

{edit}
/etc/cups/printers.conf apparently gets written by cups - it contained my command line remote printers - deleting the entries here removed them from my printers list.


Last edited by andrewdodsworth; 07-18-2004 at 04:40 AM.
 
Old 07-18-2004, 04:46 AM   #8
1kyle
Member
 
Registered: Feb 2004
Location: 'Ol Blighty
Distribution: SLED 10, SUSE 10.3
Posts: 722

Original Poster
Rep: Reputation: 32
Thanks for your time and effort Andrew.

That's what I like about this Forum -- people are always willing to post their answers / expriences.

Cheers
-K
 
Old 07-18-2004, 05:46 AM   #9
andrewdodsworth
Member
 
Registered: Oct 2003
Location: United Kingdom
Distribution: SuSE 10.0 - 11.4
Posts: 347

Rep: Reputation: 30
No problem - as I said it's been on my to-do list for a while - good to get it ticked off! I'll double check it later on by setting up another linux box with remote printers to make sure multiple remote servers are found.

By the way it also triggered some more research - as a result of changing my configuration for CUPS it reset the order of my init scripts back to the default which in SuSE 9.0 is network before PCMCIA (SuSE 9.1 is the other way round) - no good for a laptop with cardbus wireless card!

Now about to crack that one and learn how to write my own init.d script!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help printer from a samba shared printer from linux (using cups) epod69 Linux - Networking 3 12-04-2005 10:44 PM
CUPS problem with shared printer: lp works, lpr doesn't HeavyTortoise Linux - Software 1 10-03-2005 02:59 PM
CUPS and Shared Printer cthomas Linux - Networking 1 09-17-2005 05:22 PM
getting Firefox to print to CUPS with shared printer Lleb_KCir Linux - Software 5 07-27-2005 09:43 AM
Linux cups shared printer - What a mess! Discoboy Linux - Networking 4 09-21-2004 07:20 AM


All times are GMT -5. The time now is 12:43 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration