I have a cups server with one shared printer configured on it. It prints test pages without problems.
printername (Idle, Accepting Jobs, Shared)
Description: desc
Location:
Driver: Zebra ZPL Label Printer (grayscale, 2-sided printing)
Connection: socket://172.20.50.26
Defaults: job-sheets=none, none media=oe_w288h432_4x6in sides=one-sided
This is the output from lpstat -t. it shows that the printer is idle and accepting requests
admin@SERVER:~$ lpstat -t
scheduler is running
no system default destination
device for printername: socket://172.20.50.26
printername accepting requests since Thu 26 Jan 2012 01:29:35 PM CET
printer printername is idle. enabled since Thu 26 Jan 2012 01:29:35 PM CET
Now when I want to send a printjob to it via an LPR command it won't recognize the printer
/usr/bin/lpr -P printername test.pdf
Result
lpr: ttn_seg_zebra1: unknown printer
What am I missing here ?
Per comment below:
Install cups-bsd instead of lpr. Cups-bsd contains its own lpr binaries.
This package provides the BSD commands for interacting with CUPS:
Your printer's name, according to lptstat output is literally "printername".
Running
lp -d printername test.pdf
orlpr -P printername test.pdf
will work.For example, here's the output from a running system:
In this, I have two printers defined;
label
andupstairs
. In order to print to them, I'd have to use those names on the lp/lpr command line.