[cups.general] Cups High availability

Johannes Meixner jsmeix at suse.de
Tue Nov 10 06:59:34 PST 2009


Hello,

On Nov 10 05:50 Rubinas wrote (shortened):
>>>
>>> I have question regarding cups configuration sharing or other way of doing
>>> things. We have such case that we will have few cups in different servers
>>> and everyone cups server should have same configuration. So when we
>>> add/change configuration in one server other should change accordingly.
>>> Any suggestions?
>>
>> A method that will not require too much knowledge about the CUPS internals
>> would be:
>> Define one of the servers running CUPS as the master server.
>> Whenever modifying the master server's configuration, shut down all the cups
>> servers (including the master cups) and use rsync to distribute the modified
>> configuration to the other servers. Then restart all cups instances.
>> You only need to know the files which may be affected by a configuration
>> change.
>>
>> Helge
>>
>
> Similar way we think through. Just wanted to know if there more robust way
> to do it or Cups just support such thing :)

I don't like this file copying stuff because it is not really robust
when you don't have exact same installations on the various servers
(not only exact same CUPS installations but also exact same printer
drivers, Foomatic, Samba... whatever else is needed).

I would recommend what I wrote at
http://en.opensuse.org/SDB:CUPS_in_a_Nutshell
"Command-line Tools":
----------------------------------------------------------------
Never copy configuration files from other systems to your system
unless you know exactly what you are doing.
Use command-line tools instead.

For example, to set up the same queues on several machines
(e.g., for a backup server), do not copy /etc/cups/printers.conf
and /etc/cups/ppd/*, but write the respective commands
in a script (usually a sequence of lpadmin commands)
and run the script on the various machines.
In this way, any error messages will be displayed on the
respective machines (e.g., if a PPD file is not available
on a machine or if a backend is not available or not ready
to use).
Furthermore with such a script you have something like a log-file
of the settings, enabling you to restore the settings by running
the script at any time.

If you are not sure which graphical tool is best suited for
certain special configurations, use command-line tools instead. 
----------------------------------------------------------------

I.e. use rsync to distribute such a script of lpadmin commands
to the other servers and run this script on the other servers.

The only exception is /etc/cups/cupsd.conf (and perhaps
/etc/cups/client.conf but you don't use it on a server)
which you could also distribute via rsync.
After modifications in cupsd.conf the cupsd must be restarted.


Kind Regards
Johannes Meixner
-- 
SUSE LINUX Products GmbH, Maxfeldstrasse 5, 90409 Nuernberg, Germany
AG Nuernberg, HRB 16746, GF: Markus Rex





More information about the cups mailing list