Bug 501778 - Duplicate printer entry causes remainder of printers.conf to be ignored
Summary: Duplicate printer entry causes remainder of printers.conf to be ignored
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: cups
Version: 4.9
Hardware: All
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Tim Waugh
QA Contact: BaseOS QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-05-20 16:44 UTC by Jeremy Kindy
Modified: 2009-06-01 12:05 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-06-01 12:05:01 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Jeremy Kindy 2009-05-20 16:44:09 UTC
Description of problem:
Duplicate printer entry in printers.conf causes cups to stop reading printers.conf file and any entry below the duplicate entry is not loaded

Version-Release number of selected component (if applicable):
Version     : 1.1.22
Release     : 0.rc1.9.32.el4

How reproducible:
Always

Steps to Reproduce:
1. Create a duplicate printer in printers.conf located above a printer that works and returns "ready" when queried with lpq -P printer_name.
2. Restart cups.
3. lpq -P printer_name
  
Actual results:
Printers defined below duplicate printer are not loaded.  Querying printer results in:

# lpq -P FSWPC2205BW
lpq: Unknown destination "FSWPC2205BW"! 

Expected results:
Printers defined below duplicate printer are loaded and available via cups.  Querying printer results in:

# lpq -P FSWPC2205BW
FSWPC2205BW is ready
no entries


Additional info:
This may have come about due to a bugfix in this advisory: RHBA-2009:0989-1

* printers in CUPS should have unique names. However, if a CUPS
configuration file somehow contained entries for more than one device
with the same name, the CUPS scheduler would create a segmentation
fault and crash while starting up. CUPS now includes code that examines
each printer while loading it from the configuration file. CUPS will not
attempt to load duplicate entries, but will log an error.

Our particular config contained printers that had different names case-wise: e.g. printer and PRINTER.  All entries after PRINTER (that weren't duplicates themselves) were not available for printing.  Also tested with exact duplicate names with the same results.

The following errors occurred in /var/log/cups/error_log:

E [20/May/2009:00:11:23 -0400] Duplicate printer on line 873 of printers.conf.

E [20/May/2009:00:11:15 -0400] LoadAllJobs: Unable to queue job for destination "http://machine.example.com:631/printers/printername"!

Comment 1 Tim Waugh 2009-06-01 12:05:01 UTC
Print queue names are not case-sensitive and so this configuration is invalid.


Note You need to log in before you can comment on or make changes to this bug.