7.3 Example Configuration


The examples, Example 7.1, and link linkend="SimplePrintServer"/>, are designed to inspire simplicity. It is too easy to attempt a high level of creativity and to introduce too much complexity in server and network design.

7.3.1 Reference Documentation Server

Configuration of a read-only data server that everyone can access is very simple. Example 7.1 is the smb.conf file that will do this. Assume that all the reference documents are stored in the directory /export , and the documents are owned by a user other than nobody. No home directories are shared, and there are no users in the /etc/passwd UNIX system database. This is a simple system to administer.

Example 7.1 smb.conf for Reference Documentation Server
 # Global parameters  [global]   workgroup = MIDEARTH   netbios name = GANDALF   security = SHARE   passdb backend = guest   wins server = 192.168.1.1   [data]   comment = Data   path = /export   guest only = Yes  

In Example 7.1 above, the machine name is set to GANDALF, the workgroup is set to the name of the local workgroup (MIDEARTH) so the machine will appear together with systems with which users are familiar. The only password backend required is the "guest" backend to allow default unprivileged account names to be used. As there is a WINS server on this networki, we of obviously make use of it.

7.3.2 Central Print Serving

Configuration of a simple print server is easy if you have all the right tools on your system.

A SSUMPTIONS:

  1. The print server must require no administration.

  2. The print spooling and processing system on our print server will be CUPS. (Please refer to Chapter 18, CUPS Printing Support for more information).

  3. The print server will service only network printers. The network administrator will correctly configure the CUPS environment to support the printers.

  4. All workstations will use only postscript drivers. The printer driver of choice is the one shipped with the Windows OS for the Apple Color LaserWriter.

In this example our print server will spool all incoming print jobs to /var/spool/samba until the job is ready to be submitted by Samba to the CUPS print processor. Since all incoming connections will be as the anonymous (guest) user, two things will be required:

E NABLING A NONYMOUS P RINTING

  • The UNIX/Linux system must have a guest account. The default for this is usually the account nobody . To find the correct name to use for your version of Samba, do the following:

     
     $ testparm -s -v  grep "guest account" 

    Make sure that this account exists in your system password database ( /etc/passwd ).

  • The directory into which Samba will spool the file must have write access for the guest account. The following commands will ensure that this directory is available for use:

     
     root# mkdir /var/spool/samba root# chown nobody.nobody /var/spool/samba root# chmod a+rwt /var/spool/samba 

The contents of the smb.conf file is shown in Example 7.2.

Example 7.2 smb.conf for Anonymous Printing
 # Global parameters  [global]   workgroup = MIDEARTH   netbios name = GANDALF   security = SHARE   passdb backend = guest   printing = cups   printcap name = cups   [printers]   comment = All Printers   path = /var/spool/samba   printer admin = root   guest ok = Yes   printable = Yes   use client driver = Yes   browseable = No  

N OTE

graphics/round_pencil.gif

On CUPS-enabled systems there is a facility to pass raw data directly to the printer without intermediate processing via CUPS print filters. Where use of this mode of operation is desired, it is necessary to configure a raw printing device. It is also necessary to enable the raw mime handler in the /etc/mime.conv and /etc/mime.types files. Refer to Section 18.3.4.




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

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