RedHat (actually, CentOS 4.4)
I need to have a way to install a serial printer (I think!) via the command line, using the lpadmin tool or any other program that can be run in a script.
I say 'I think!' because my client seems to want this to be a serial printer but he keeps discussing having the printer's URI be a file /var/isd/SER-A07/printdata
Whatever -- when he sets up the printer using the printconf-tui tool, these are the steps that he takes:
Quote:
For the non-interactive option, I only need to pass one parameter which would be a sitename (i.e. SER-A07). Using printconf, the equivalent options would be:
Add
Queue Name = SER-A07
LOCAL printer
Custom
Device File = /var/isd/SER-A07/printdata
Text Only printer
Finish
|
When following these instructions, I get the following entry in the /etc/cups/printers.conf file:
Code:
<Printer SER-A07>
Info Created by redhat-config-printer 0.6.x
DeviceURI file:/var/isd/SER-A07/printdata
State Idle
Accepting Yes
JobSheets none none
QuotaPeriod 0
PageLimit 0
KLimit 0
</Printer>
We want the same entry to appear in printers.conf as above, but done with a non-interactive command or script. Currently when I try to do this I get:
Code:
[root@linux ~]# lpadmin -p serial_test -v file:/var/isd/SER-A07/printdata -E
lpadmin: add-printer (set device) failed: client-error-not-possible
[root@linux ~]#
What am I doing wrong from the command line? Do I need to specify the interface ('-i' flag) somehow, and if so what the heck is that?? (I've not found any real info on that, anywhere). Do I need to specify a PPD file, and if so, what would that be for a text-only printer? Notice when doing it via printconf-tui there is never a question about the printer model, because its text; I don't think the PPD is used.
Anyone familiar with CUPS and lpadmin and can help me? I tried a few times in #rhel and #cups and #centos on IRC but no one knows.