Newsgroups: gmane.linux.debian.user Date: Tue, 05 Sep 2006 03:42:02 -0400
Newsgroups: gmane.linux.debian.user Date: Tue, 05 Sep 2006 03:42:02 -0400
This letter documents,
How I set up printing on debian sid remotely ie: from 1 computer running sid to another computer running sid.
Here are my brief notes. My network is 192.168.10.* and I have the server set up at 192.168.10.18 key things are:
On server:
edit /etc/cups/cupsd.conf
1) delete the following two lines
Localhost:631 /var/run/cups/cups.sock
substitute with the line
Port 631
2) add the line
Browsing On
3) In Location stanza allow the following
<Location /> Order allow,deny Allow localhost AuthType None Allow From 192.168.10.64 Allow From 192.168.10.0/255.255.255.0 # alternative Allow From 192.168.*.* </Location>
????????????? possibly may need a line ServerName 192.168.10.18
?????????????? possiby may need a line BrowseAddress 192.168.10.255
I then set up a printer. i called it hplaserjet on the server. I used cups web administration
localhost:631
On the client machine I created a file called /etc/cups/client.conf
which has the line
ServerName 192.168.10.18
where the ip address is that of your printer server.
i then needed to go into the web based adminstration module on the client to install the printer
in web browser open up
localhost:631
go into administrative module
i needed to set up the printer.
click add a printer
call it anything you want then enter this location
ipp://192.168.10.18:631/printers/hplaserjet
where 192.168.10.18 is the printer server.
then select the right driver
then this should work.
i dont know why this is so darn difficult now on debian.
Mitchell
Note On both machines I had the following packages
$dpkg -l|grep cups ii cupsys 1.2.2-2 CUPS - server ii cupsys-bsd 1.2.2-2 CUPS - BSD commands ii cupsys-client 1.2.2-2 CUPS - client progr ii cupsys-common 1.2.2-2 CUPS - common files ii cupsys-driver-gimpprint 5.0.0-2 printer drivers for CUPS ii cupsys-driver-gutenprint 5.0.0-2 printer drivers for CUPS ii gnome-cups-manager 0.31-2 CUPS printer admin tool for GNOME ii libcupsimage2 1.2.2-2 CUPS - image libs ii libcupsys2 1.2.2-2 CUPS - libs ii libgnomecups1.0-1 0.2.2-5 GNOME library for CUPS interaction ii libgnomecupsui1.0-1c2a 0.31-2 UI extensions to libgnomecups
Newsgroups: comp.os.linux.misc
> If you know how the printer filter driver works within Linux, > you will understand what I am talking about here. > > I want to use a laser printer which are hooked to the ethernet RJ45 > from Linux hosts. A printer can have an IP number. However, > if you use it that way, the Linux lpd simply sends a raw request > to the host, i.e., the printer. In this case, unlike a Linux or > MSWindoes > host, the printer does not have any printer filter software, i.e., the > ghostscript software in the case of a Linux. > So, basically, printing will fail. > > What can we do about this? In the case of HP printers, they > provide Solaris JetDirect Software. However, there is no > such thing for Linux.
On your Linux system, configure the printer settings as if the printer was on the parallel port. This will result in the printer filters being set up and an entry in the /etc/printcap with a part like:
lp:lp=/dev/lp0:sd=/var/spool/lpd … etc
now change the 'lp=/dev/lp0' part into:
'rm=<host name>:rp=<queue name>'
in order to let lpd contact the print server <host name> and submit the job to <queue name>.
Roel Brand.
documented on: 2000.06.24
The print job is not passed through a filter until it reaches the lpd program on the remote system.
Once a print job has been submitted to a remote system, the local lpd daemon has nothing more to do with it. You cannot query the remote print queue or learn more about the print job without first logging in to the remote system.
Unless the default settings have been changed in the printcap or lpd.perms file, any user on the same network can connect to a printer and submit print jobs.
Leaving print job filtering to be done on the remote server makes sense in most case, but it causes a problem when the printer is attached directly to the network, This is a common situation. The printer is considered remote because it is not connected to a serial or parallel port on the Linux computer. Network printers in many companies have their own IP addresses, which make it possible to send data directly to the printer without connecting it first to a computer's parallel or serial port. Because Linux applications do not preprocess a file based on a printer driver before submitting it for printing, the print filter must do this job. A network printer, however, does not have the ability to run a Linux-style print filter. To solve this problem, a bounce queue command is used.
A bounce queue (bq) is an option code in the printercap file that cause print jobs to be processed by the pint filter before being sent to a remote printer. For example, if the printcap file includes the folllowing lines, each print job will be processed by the filer, then sent to the print queue named cs4 on the server 131.162.130.250.
lp: :sd=/var/spool/lpd/lp: :mx#0: :sh: :bq=cs4@131.162.130.250: :if=/var/spool/lpd/lp/filter:
Note that no rm or rp lines are used here, because the bq option contains the remote printer information. In addition, no lp line is required, because no local printer port will be used to print files. However, as when using the rm and rp options to specify a stanard remote lpd-based server, you should include the sd option to specify a print spool directory so that lpd has a lcoation to store files between the time they are submitted and when they are processed.
http://www.linuxdoc.org/HOWTO/Printing-HOWTO/network.html
To allow remote machines to print to your printer using the LPD protocol, you must list the machines in /etc/hosts.equiv or /etc/hosts.lpd. (Note that hosts.equiv has a host of other effects; be sure you know what you are doing if you list any machine there). You can allow only certain users on the other machines to print to your printer by usign the rs attribute; read the lpd man page for information on this.
11.1.1. With pdq
With PDQ, you define a printer with the interface type "bsd-lpd". This interface takes arguments for the remote hostname and queue name; the printer definition wizard will prompt you for these.
11.1.2. With lpd
To print to another machine, you make an /etc/printcap entry like this:
# REMOTE djet500 lp|dj|deskjet:\ :sd=/var/spool/lpd/dj:\ :rm=machine.out.there.com:\ :rp=printername:\ :sh:
Note that there is still a spool directory on the local machine managed by lpd. If the remote machine is busy or offline, print jobs from the local machine wait in the spool area until they can be sent.
11.1.3. With rlpr
You can also use rlpr to send a print job directly to a queue on a remote machine without going through the hassle of configuring lpd to handle it. This is mostly useful in situations where you print to a variety of printers only occasionally. From the announcement for rlpr:
Rlpr uses TCP/IP to send print jobs to lpd servers anywhere on a network.
Unlike lpr, it *does not* require that the remote printers be explicitly known to the machine you wish to print from, (e.g. through /etc/printcap) and thus is considerably more flexible and requires less administration.
rlpr can be used anywhere a traditional lpr might be used, and is backwards compatible with traditional BSD lpr.
The main power gained by rlpr is the power to print remotely *from anywhere to anywhere* without regard for how the system you wish to print from was configured. Rlpr can work as a filter just like traditional lpr so that clients executing on a remote machine like netscape, xemacs, etc, etc can print to your local machine with little effort.
Rlpr is available from Metalab. ftp://metalab.unc.edu/pub/Linux/system/printing/
Many printers come with an ethernet interface which you can print to directly, typically using the LPD protocol. You should follow the instructions that came with your printer or its network adaptor, but in general, such printers are "running" lpd, and provide one or more queues which you can print to. An HP, for example, might work with a printcap like:
lj-5|remote-hplj:\ :sh:\ :sd=/var/spool/lpd/lj-5:\ :rm=printer.name.com:\ :rp=raw:
or, using the PDQ bsd-lpd interface arguments of REMOTE_HOST=printer.name.com and QUEUE=raw.
HP Laserjet printers with JetDirect interfaces generally support two built in lpd queues - "raw" which accepts PCL (and possibly Postscript) and "text" which accepts straight ascii (and copes automatically with the staircase effect). If you've got a JetDirect Plus3 three-port box, the queues are named "raw1", "text2", and so forth.
In a large scale environment, especially a large environment where some printers do not support PostScript, it may be useful to establish a dedicated print server to which all machines print and on which all ghostscript jobs are run. This will allow the queue to be paused or reordered using the topq and lprm commands.
This also allows your Linux box to act as a spool server for the printer. To do this, set up a queue on your linux box that points at the ethernet equipped HP LJ (as above). Now set up all the clients on your LAN to point at the Linux queue (eg lj-5 in the example above).
Some HP network printers apparently don't heed the banner page setting sent by clients; you can turn off their internally generated banner page by telnetting to the printer, hitting return twice, typing "banner: 0" followed by "quit". There are other settings you can change this way, as well; type "?" to see a list.
Newsgroups: comp.os.linux.setup Date: Mon, 10 Feb 2003 14:52:33 GMT
>Now i have got another problem, how to set two or three print queues >to one printer, can Linux do that?
Yes. Just make sure that each print queue is implemented with a seperate spool subdirectory, and that all the printcap entries point to the same device. I.e.
printer1:lp=/dev/lp0:sd=/var/spool/lpd/printer1:if=/usr/share/printfilter:
printer2:lp=/dev/lp0:sd=/var/spool/lpd/printer2:if=/usr/share/printfilter:
printer3:lp=/dev/lp0:sd=/var/spool/lpd/printer3:if=/usr/share/printfilter:
Lew Pitcher
> Is there a way to print from UNIX workstation to a printer which is set > up for NT.
Use smbclient from the SAMBA package
Set up your NT printer as an LPR printer by installing Microsoft TCP/IP printing
Here's instructions for setting it up for HP which uses lp printing. If you use lpr printing, the Unix side will be different as will the options you pass to lpr.
Dan Mercer
On the NT side you have to install and configure TCP-IP services. Go to the help. In the Index, look up TCP/IP. Double-click on "Printing" and then on "To configure a computer running Windows NT for TCP/IP Printing" and follow the instructions. They will show you how to start the LPR service for the NT. Make sure the NT printers you want to connect to have simple names (no included spaces). Next, on the HP side, use SAM to install the Printer as a Remote BSD printer giving the internet name of the host and the printer name. I haven't tried it but I wouldn't be surprised if the printer name was case insensitive.
Finally, to print to the thing.
To print an unformatted file (the NT device driver will format it):
lp -d printer file
To print formatted files, you must pass the appropriate lpr options to lp. You do that by prefacing them with the BSD marker (caps required). For instance, to print a Postscript file to a Postscript printer:
lp -d printer -o BSDo file
To print a formatted (non-Postscript) file (PCL, for example):
lp -d printer -o BSDl file ^(small L)
To see what the other lpr options are, consult the man page for lpr which I include below. Do not use the "lpr" command HP provides. It is a shell script and a fraud and does not correctly encapsulate or translate lpr options to lp options.
lpr(1)
SYNOPSIS
lpr [-Pprinter] [-#num] [-C class] [-J job] [-T title] [-U user] [-i [numcols]] [-1234 font] [-wnum] [-cdfghlnmprstv] [name ...]
documented on: 2000.12.19
Newsgroups: comp.os.linux.misc
> >We have an intranet server with RH6.1 - however we are mainly a Novell > >Netware 4.11 site with our printing being controlled by NDS print > >queues.
> There is a package for netware support. It contains ncpmount, nprint etc. > nprint can be used to send a file to the print q. > It works for me at least with Netware 3.xx, did not test it with Netware 4.xx > I just don't know it's name.
ncputils
>Could you summarize how to mount axe and plato respectfully? Thanks
Okay, here are the steps I had to do to get AXE and PLATO mounted. Please note that I had installed Slackware on my computer myself so some of the options in the kernel may be a bit different on the laptops as the options may already be compiled in! Also I am using kernel version 2.2.18 so the names of the kernel options may differ a bit depending on your kernel options.
1) Recompile the kernel with IPX/SPX support (either as modules or right into the kernel) as well as support for NCP(Novell) File systems (under File systems, network file systems). If you do not know how to do this please refer to the Linux-HOWTO's.
2) Reboot with new kernel, load modules if necessary.
3) Download and install ncpfs 2.2.0.18 (or later) found at: ftp://platan.vc.cvut.cz/pub/linux/ncpfs/
4) Configure your IPX devices by typing (as root) ipx_configure —auto_primary=on —auto_interface=on This will enable IPX for your ethernet cards (eth0 in my case) This is required by the novell file systems.
5) Mount the Novell file systems (may need to be root, depends on how you have your permissions set up. ncpmount -S AXE -U <username> <mount-point> ncpmount -S PLATO -U <username> -b <mount-point>
Plato is the one that I had problems with mounting before because I did not include the -b option, If you do not include that option you will get "No Entry Point" errors. Also there are many other options that you can use with ncpmount, such as -V … to see the full list just type ncpmount -h, and it will list them all . Also, to see a list of NCP servers, user the command "slist" which will produce a server list"
Hope this clears some things up, and not confuses them even more
-Rob
documented on: 2001.10.25