[Techtalk] Pathetic Mini How-To on CUPS & MacOSX Clients

Beth Johnson linux.chick at verizon.net
Wed Feb 5 18:45:43 EST 2003


My situation:
*RH Linux 8.0 kernel 2.4.18-19.8.0, CUPS version 1.1.17-0.2, HP LaserJet
1100 on lp0
*Nice, fast Linksys router on a home network with static IP addresses
*Mac OSX 10.2.3, CUPS version ? (but very recent--how do I find this on
a Mac?)

My Problem:
*My Mister, running a G4 Cube, wants to print to my LaserJet.

 By default Macs under OSX aren't set up to listen for print requests
via CUPS or generally recognize a network printing environment other
than AppleTalk.  Editing the configuration file with vi is the only way
I've found to change this so far.

Now, here's a caveat: once I set this up our G4 Cube stopped being able
to print PDF files and lost the ability to "print" to the fax.  Undoing
what I did on the Cube (reverting the cupsd.conf file) helped.  So my
Linux boxen can't print to the Macs, because they are autistic, for lack
of a better word.  Forcing them to be social in ways they aren't
prepared for causes them to malfunction.

On the Tux box:
Edit the file /etc/cupsd.conf as shown below.  Realize that there is
some oddness created with network settings sometimes.  People describe
not being able to print a test page to a printer (getting a Forbidden
message) via the web admin page, but can print just fine.  Go figure.

In the Server Options section, change this:
	Loglevel info
to this:
	# LogLevel info
	LogLevel debug

In the Network Options section make sure you have this:
	#Port 80
	#Port 443
	Port 631
	# Listen 127.0.0.1:631

In the Browsing Options section change this:
	BrowseAllow 127.0.0.1
	BrowseDeny All
to this:
	BrowseAllow 127.0.0.1 192.168.1.* <or your local subnet>
	BrowseDeny All

In the Security Options section, change this:
	<Location />
	Order Deny,Allow
	Deny From All
	Allow From 127.0.0.1
	</Location>
to this:
	<Location />
	Order Deny,Allow
	Deny From All
	Allow From 127.0.0.1 192.168.1.* <or your local subnet>
	</Location>

Restart the daemon: /etc/init.d/cups restart, or the similiar command on
your system.

Put a tail on the log file, as root:
	tail -f /var/log/cups/error_log
This will give you good troubleshooting stuff.

On the Mac:
If you have printers attached to the Mac that you want to print to from
Linux machines, edit the file /etc/cups/cupsd.conf.  If not, skip to
Step Two.

Step One (optional, and breaks some Mac printing--I have to play with
this some more)
In the Server Identity section:
	#
	ServerName 127.0.0.1
Comment this out and add your server name
	#
	# ServerName 127.0.0.1
	ServerName <actual name, like from your hosts file>

In the Server Options section, change this:
	Loglevel info
to this:
	# LogLevel info
	LogLevel debug

In the Network Options section change this:
	#Port 80
	#Port 443
	#Port 631
	Listen 127.0.0.1:631
to this:
	#Port 80
	#Port 443
	Port 631
	# Listen 127.0.0.1:631

In the Browsing Options section change this:
	BrowseAllow 127.0.0.1
	BrowseAllow @LOCAL
	BrowseDeny All
to this:
	BrowseAllow 127.0.0.1 192.168.1.* <or your local subnet>
	BrowseAllow @LOCAL
	BrowseDeny All

In the Security Options section, change this:
	<Location />
	Order Deny,Allow
	Deny From All
	Allow From 127.0.0.1
	</Location>
to this:
	<Location />
	Order Deny,Allow
	Deny From All
	Allow From 127.0.0.1 192.168.1.* <or your local subnet>
	</Location>

Step Two

Install the ESP Ghostscript, GimpPrint drivers (both from
http://gimp-print.sourceforge.net/MacOSX.php3) and/or HPIJS drivers</a>
(http://www.linuxprinting.org) if you need them.  Run 
	sudo killall -HUP cupsd 
to restart CUPS.  Put a tail on the logfile:  
	sudo tail -f /private/var/log/error_log

Step Three

Open the Print Center.
Hold down the [Option] key and click on [Add Printer].  Select
"Advanced".  Select "IP Printing (http)".  Type in server & queue
address of the Linux printer in this format:
	http://<ip address>:631/printers/<queue name>
Select the appropriate driver and add the printer.

You should be able to print to the Linux server, via IPP through CUPS!

Now, if you have questions, realize that I might not be able to help
you!  I did a lot of munging different snippets of information together
to come up with this, and haven't really wrapped my brain around all of
it yet myself.

regards,
Beth
-- 
  /\/\    Beth Johnson
 / o o\   Cosmic Wonderer
( / ^^\)  Springfield, MA USA
 \ M_M/   "Ruling a country is like cooking a small fish--
           you have to handle it with care."--Lao Tzu
	




More information about the Techtalk mailing list