#StackBounty: #rhel #cups How to edit /etc/printcap?

Bounty: 200

We recently changed domain and host name on a RHEL8 server from old.domain.name to more.better.name.

I happened to notice a reference in /etc/printcap to old.domain.name.

[user@box ~]# cat /etc/printcap 
# This file was automatically generated by cupsd(8) from the
# /etc/cups/printers.conf file.  All changes to this file
# will be lost.
office_printer_123|office_printer_123:rm=old.domain.name:rp=office_printer_123:
[user@box ~]# 

Correct hostname shows

[user@box ~]# hostname
more.better.name
[user@box ~]# 

The server has been restarted a few times since changing the hostname.

I found zero other references to old.domain.name with

[user@box ~]# grep -r "old.domain.name" /etc/
[user@box ~]# 

old.domain.name is not found in /etc/cups/printer.conf

[user@box]# cat /etc/cups/printers.conf
# Printer configuration file for CUPS v2.2.6
# Written by cupsd on 2021-08-24 10:01
# DO NOT EDIT THIS FILE WHEN CUPSD IS RUNNING
<Printer office_printer_123>
UUID urn:uuid:e74ed8e4-e5e6-30b9-64b9-2283cc9c93e7
AuthInfoRequired none
Info office_printer_123
MakeModel HP LaserJet 600 M601 M602 M603 Postscript (recommended)
DeviceURI ipp://111.222.111.222
State Idle
StateTime 1629813648
ConfigTime 1618257051
Type 8425668
Accepting Yes
Shared Yes
JobSheets none none
QuotaPeriod 0
PageLimit 0
KLimit 0
OpPolicy default
ErrorPolicy stop-printer
</Printer>
[user@box]# 

How do I change what’s in the printcap file? And where could it be pulling old.domain.name?


Get this bounty!!!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.