Welcome, Guest. Please login or register.
April 20, 2014, 19:32:50 PM
Home Help Search Calendar Login Register
Show unread posts since last visit.
News: Let Pardus-Anka become #1: Pardus-Anka Bug ReportPardus-Anka World Google+ | The Pardus wiki  | Visit Pardus-Anka official website  | Register as forum member?  Email the moderator!

+  Pardus Worldforum
|-+  Assistance
| |-+  Configuring Pardus
| | |-+  [SOLVED]How to print from Pardus to remote Pardus+printer ?
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: [SOLVED]How to print from Pardus to remote Pardus+printer ?  (Read 2902 times)
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« on: November 22, 2008, 18:34:13 PM »

I have Pardus instaleld on a PC, and my Canon PIXMA printer is connected to it by means of USB.
The PC is connected to an ADSL router.

Also connected to the ADSL router but then wireless is my Pardus laptop.

I have a simple question but tried lots of features in Tasma/KDE Print but I can not manage to solve it:

How can I print from my Pardus laptop to the printer that is connected to my Pardus PC?

To me the most reasonable option seems to somehow print with the laptop as a sort of "guest" via the CUPS that is running on the PC.

I have tried several solutions in Tasma for adding a network printer, but I can not figure out how to get this realised.

Anyone a suggestion for me?
« Last Edit: November 23, 2008, 22:16:55 PM by Michiel » Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #1 on: November 22, 2008, 20:17:36 PM »

By means of Google and one of those many Ubuntu pages I started to try this solution which appears quite simple.

http://ubuntuguide.org/wiki/Ubuntu_dapper#How_to_print_on_remote_Ubuntu_machine_from_another_Ubuntu_machine

Thus, on my laptop (the client-side), I altered the file /etc/cups/client.conf and added ServerName 10.0.0.154 (my internal IP adress of the CUPS server-side Pardus PC), and restarted service cups.

This was easy, however I keep getting an Connection refused error once going to Tasma-Peripherals-Printers and following a short window saying "initialising administrator".

Somehow I do not get connection to my remote CUPS server, it IS nicely stated in Tasma where normaly it says localhost:631 now it states 10.0.0.154:631 as it should.

Of course I also altered cupsd.conf on the CUPS server side Pardus PC, allowing 10.0.0153 which is the internal IP of my client (laptop).

I put firewall on both sides off.

There are quite some options to configrue in cupsd.conf, and it appears a bit weird configurated by default, thatÅ› why (I guess) I always got a strange error window popping up once I cose Configure Printerserver in Tasma/KDE Print, some error window showing a lot of ALLOW, DENy strings.

How should the server-side CUPS be configrued to really allow my client(laptop) to print at the server-side?
Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #2 on: November 22, 2008, 22:17:28 PM »

I am making progress.
On the server side I have Ubuntu running.
On this Ubuntu-PC a Canon-BJC-1000 printer in connected to a lpt port.
On the client side  I have Pardus 2008 running.
From the Pardus-PC it is now printing a test page on the Canon-BJC-1000 printer, connected to the server-PC.
I hope I can also do this when I replace Ubuntu with Pardus on the server-PC.
That story (and I hope a wiki page) will come tomorrow.  Grin
Logged
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #3 on: November 22, 2008, 22:21:12 PM »

That sounds promising atolboo  Cheesy

I will myself dive into this additional HOWTO documentation tomorrow.
http://www.brennan.id.au/15-System_Printing.html

and

http://www.cups.org/documentation.php/doc-1.4/ref-cupsd-conf.html

particularly the Allow sections
« Last Edit: November 22, 2008, 22:26:57 PM by Michiel » Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #4 on: November 23, 2008, 10:37:06 AM »

My first instructions:
Change settings of firewall on server-PC:
Quote
Tasma > Internet &Network > Firewall Config
   Advanced > +
      Incoming
      Port Range = 631
      Accept
   OK > Apply > Back
Close Tasma

Change of /etc/cups/cupsd.conf on server-PC (see <== marker)
Quote
# Administrator user group...
SystemGroup pnpadmin
Port 631    <==

# Only listen for connections from the local machine.
.
.
# Restrict access to the server...
<Location />
  Order allow,deny
  Allow @LOCAL    <==
</Location>

Change of /etc/cups/client.conf on client-PC (see <== marker)
Quote
ServerName localhost
ServerName 192.168.0.100    <==
192.168.0.100 is the IP address of the computer to which the printer is connected.
This means that this is only an example.
 
Configuration of printer in Pardus
Quote
[Pardus]>[Tasma]>{Peripherals]>[Printers]>{Add}>{Add Printer/Class...}
[Next >]
[Remote CUPS server (IPP/HTTP)]
[Next >]
{Anonymous (no login/password))}
[Next >]
Host: = IP address of the computer to which the printer is connected
Port: = 631
[Next >]
..............

As Pardus 2008 is using cups 1.3.9, its better to have a look in
Quote
« Last Edit: November 23, 2008, 16:56:59 PM by atolboo » Logged
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #5 on: November 23, 2008, 22:16:32 PM »

Confirmed: working now, thanks atolboo and make this another nice wiki.

I have one partially related problem left:
My laptop and my PC were assigned a different internal IP than yesterday (yesterday they were at 10.0.0.153 and 10.0.0.154, today they are at 10.0.0.155 and 10.0.0.156).

Do I have to change ServerName in client.conf every time?


Do you have any clue how to arrange fixed internal IPs so that my laptop and my PC do always have the same internal IP?

I can manage my Speedtouch 580 ADSL router by a webinterface on internal IP 10.0.0.138, do you have some sort of general clue on how to set routers assigning always the same internal IP to the same devices in the local network?
« Last Edit: November 23, 2008, 22:20:12 PM by Michiel » Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #6 on: November 24, 2008, 14:00:58 PM »

Do I have to change ServerName in client.conf every time?
Yes, as the client-PC sends its printer commands with "ServerName 192.168.0.100" to the printer.

First of all, I am not a network expert.  Grin
This is how I solved the problem on my system.
As I have a Sitecom WL-535 Wireless Network Broadband Router 54g the numbers  are ONLY valid when you use this router.
With another router they are probably different.
In between {} is the Dutch text.

From my Sitecom WL-535 router:
Quote
TCP/IP Configuration
   Subnet Mask     255.255.255.0
   Default Gateway   192.168.0.1
LAN
   IP Address: 192.168.0.1
   Subnet Mask: 255.255.255.0
   Default Gateway: 0.0.0.0
   DHCP Client Range:   192.168.0.100 - 192.168.0.200
(in the LAN section I can change the values)

I changed the network connection of the server-PC to which the printer is connected from
Automatic Query (DHCP) {Automatische aanvraag (DHCP)} to
Quote
Manual {Handmatig}
Adddress: {Adres:}192.168.0.201
Net mask: {Netmasker:} 255.255.255.0 (pull-down menu)
Gateway: {Poort:} 192.168.0.1
and /etc/cups/client.conf on the client-PC
Quote
ServerName localhost
ServerName 192.168.0.201

I hope this will help to solve the problem !  Wink
(it will make the wiki more complicated)
Logged
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #7 on: November 26, 2008, 10:17:23 AM »

I hope this will help to solve the problem ! 
Did this solve the problem? Any feedback is welcome!  Smiley
Logged
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #8 on: November 26, 2008, 12:39:24 PM »

atolboo for the moment I keep it as it is, I am a bit cautious in changing my internal network settings, everything is working now, and you do not know what happens when you start engineering your network settings.
Also, printing form my laptop is not performed on a daily base, as long as it works it is alright like this and if not I will manually change client.conf to direct to the IP then needed.

Perhaps when i find the need, time and courage I will try the last part of your suggestions also, and of course I will then provide feedback here.\

Maybeyour solution t iactually s easier then I am suggesting/fearing, so we'll keep in touch ;-)
« Last Edit: November 26, 2008, 12:41:42 PM by Michiel » Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #9 on: November 26, 2008, 14:21:44 PM »

......... I will try the last part of your suggestions also, and of course .........
The numbers in the last part depends on the numbers from the router.
And can be different as they depend on how the IP protocol in implemented in the router.
I have taken an IP address just above the DHCP Client Range.

If you do something wrong, it is always possible to return to the old situation by selecting "Automatic Query (DHCP)" in the network manager.
I hope this gives you more information in order to try it.  Wink
Logged
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #10 on: November 26, 2008, 21:48:39 PM »

Ok then, little update, I changed my network-settings according to your example, treid to reconnect to the internet and...it worked, I am now on local IP 10.0.0.201 with the laptop and typing this online.
My DHCP internal IP range is 10.0.0.150-10.0.0.200.

Anyway if all is as it theoretically should be I am from now on (with my laptop) always online via internal IP 10.0.0.201.

The most difficult of the three settings for me was to find the gateway {poort}, but in my case I thought it also had to start with the same numbers as other internal IPs so I chose 10.0.0.138 at which IP also my webinterface tot the router configuration resides.

So in my case I have:
Manual {Handmatig}
Adddress: {Adres:}10.0.0.201
Net mask: {Netmasker:} 255.255.255.0 (pull-down menu)
Gateway: {Poort:} 10.0.0.138

That worked for me.

Thanks!

I will adjust the client.conf file and test printing later on (I guess it works like it did, will let you know)
« Last Edit: November 26, 2008, 21:51:21 PM by Michiel » Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #11 on: November 26, 2008, 21:59:55 PM »

My DHCP internal IP range is 10.0.0.150-10.0.0.200.
Is this info supplied by your router (when you connect to your router)?
Didn't you router give any "Gateway" information? Huh?

...... I am now on local IP 10.0.0.201 with the laptop and typing this online.
Is the printer connected to your laptop?  Huh?
This sounds very strange to me.
The hole purpose of this change is to give the computer (server-pc)  to which your printer is connected a fixed IP address.
« Last Edit: November 26, 2008, 22:27:56 PM by atolboo » Logged
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #12 on: November 26, 2008, 23:01:53 PM »

Ah, atolboo I am a fool, I did this trick to the client-side, i.e. the laptop  Grin
But of course I can do something similar to the server-side (PC) I guess.

About the gateway, my webinterface of the Speedtouch router gives LOTS of menu's, submenu's with lots of IP adresses and so on, but I did not recognize instantly which IP adress I should choose, especially since I did not have ONE menu in my router webinterface with the settings you provided in one view. Thus I collected the DHCP range from a tab "DHCP", and then a subitem, whilst the "Gateway" (I cannot find that term in my router webinterface) is the IP assigned to eth0 and found under "IP adresses" tab.
Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
Michiel
Administrator
Pardus Guru
*****
Posts: 799



View Profile
« Reply #13 on: November 29, 2008, 14:22:09 PM »

Ok atolboo it's working.

I assigned a fixed internal IP adress to my printer server-side PC (in my case 10.0.0.202) just as you suggested (and what I erroneously did with my client-side laptop earlier, however it is nice to have a fixed internal IP for my laptop as well).

Also I changed /etc/cups/client.conf at the client side as suggested (although I did not add but rather replaced ServerName localhost with ServerName 10.0.0.202).

(I think I can even switch off the automatic start of CUPS at the client-side when booting the system, since I actually send the print request to the CUPS at the server-side PC)

For the wiki from my experiences you could add one last note:

After doing all this and restarting cups (sudo service cups restart) at both server- and client-side, the printer was functioning from the client-side when doing a Test Page from within Tasma-Peripherals-Printers) but it did NOT function when printing from applications such as Oo Writer (also no printing tasks appeared in Tasma-Perpipherals-Printers).

Although CUPS was restarted obviously KDE and/or the entire Pardus OS still used the old internal links when calling the printer from within applications.

To make a long story short: just add at the end of the wiki that one should reboot the system (i.e. Pardus) once, and then the modified printersettings are used, also within applications.
(I noticed e.g. in the Writer printer dialog window that the properteis of the printer were slightly different then befroe rebooting, and that was just my objective  Cheesy ).

Thanks for this nice excerscise atolboo, I think that the fact that I changed DHCP to fixed internal IPs for this purpose, which is indeed really a piece of cake, may pay out for some other applications using the internal network as well)
« Last Edit: November 29, 2008, 14:27:49 PM by Michiel » Logged

Former Pardus user, now on OpenSUSE 12.2 (KDE)
atolboo
Pardus Guru
****
Posts: 2317



View Profile
« Reply #14 on: November 29, 2008, 14:54:50 PM »

Good to hear and I will start working on the wiki.  Wink
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  


Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!