18.7 Network Printing (Windows Clients UNIXSamba Print Servers)


18.7 Network Printing (Windows Clients ” UNIX/Samba Print Servers)

Since UNIX print servers cannot execute the Win32 program code on their platform, the picture is somewhat different. However, this does not limit your options all that much. On the contrary, you may have a way here to implement printing features that are not possible otherwise .

18.7.1 From Windows Clients to a CUPS/Samba Print Server

Here is a simple recipe showing how you can take advantage of CUPS' powerful features for the benefit of your Windows network printing clients:

  • Let the Windows clients send PostScript to the CUPS server.

  • Let the CUPS server render the PostScript into device-specific raster format.

This requires the clients to use a PostScript driver (even if the printer is a non-PostScript model. It also requires that you have a driver on the CUPS server.

First, to enable CUPS-based rinting through Samba the following options should be set in your smb.conf file [global] section:

 
  printing = cups   printcap = cups  

When these parameters are specified, all manually set print directives (like print command , or lppause command ) in smb.conf (as well as in Samba itself) will be ignored. Instead, Samba will directly interface with CUPS through its application program interface (API), as long as Samba has been compiled with CUPS library (libcups) support. If Samba has not been compiled with CUPS support, and if no other print commands are set up, then printing will use the System V AT&T command set, with the -oraw option automatically passing through (if you want your own defined print commands to work with a Samba that has CUPS support compiled in, simply use printing = sysv).

18.7.2 Samba Receiving Jobfiles and Passing Them to CUPS

Samba must use its own spool directory (it is set by a line similar to path = /var/spool/samba, in the [printers] or [printername] section of smb.conf ). Samba receives the job in its own spool space and passes it into the spool directory of CUPS (the CUPS spooling directory is set by the RequestRoot directive, in a line that defaults to RequestRoot/var/spool/cups ). CUPS checks the access rights of its spool dir and resets it to healthy values with every restart. We have seen quite a few people who had used a common spooling space for Samba and CUPS, and were struggling for weeks with this " problem ."

Figure 18.15. Printing via CUPS/Samba server.

graphics/18fig15.gif

A Windows user authenticates only to Samba (by whatever means is configured). If Samba runs on the same host as CUPS, you only need to allow " localhost " to print. If they run on different machines, you need to make sure the Samba host gets access to printing on CUPS.



Official Samba-3 HOWTO and Reference Guide
The Official Samba-3 HOWTO and Reference Guide, 2nd Edition
ISBN: 0131882228
EAN: 2147483647
Year: 2005
Pages: 297

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net