I´d like to start testing PaperCut (installed by
http://www.dungog.net/wiki/Papercut ) using a fake printer.
So I think: create one pointing to /dev/null !
I do a copy of /etc/e-smith/web/functions/printers and find
<field id="location" type="select" options="'lp0'=>'LOCAL_PRINTER_0',
'lp1'=>'LOCAL_PRINTER_1','lp2'=>'LOCAL_PRINTER_2','remote'=>'NET_PRINTER',
'usb/lp0'=>'FIRST_USB_PRINTER','usb/lp1'=>'SECOND_USB_PRINTER'"
value="remote" validation="nonblank">
<label>LOCATION</label>
and add a new option
<field id="location" type="select" options="'lp0'=>'LOCAL_PRINTER_0',
'lp1'=>'LOCAL_PRINTER_1','lp2'=>'LOCAL_PRINTER_2','remote'=>'NET_PRINTER',
'usb/lp0'=>'FIRST_USB_PRINTER','usb/lp1'=>'SECOND_USB_PRINTER',
'nul'=>'DevNull'"
value="remote" validation="nonblank">
<label>LOCATION</label>
and create a new printer (named: blackhole hehehe) using DevNull as printer port.
BUT:
[root@guepardo ~]# lpr -Pblackhole /etc/motd.jm
[root@guepardo ~]# lpq -Pblackhole
Printer: blackhole@guepardo 'Buraco Negro de Impressoes'
Queue: 1 printable job
Server: pid 31630 active
Unspooler: pid 31631 active
Rank Owner/ID Pr/Class Job Files Size Time
active root@guepardo+628 A 628 /etc/motd.jm 2962 14:28:13
error root@guepardo+317 A 317 ERROR: too many errors
Any ideas why this do not just works ? And how to make it work ?
Thanks
Jáder
EDIT: Jun 22nd 2011 - 21:12 GMT-0300 I JUST FOUND IT, was a TYPO!!!! The line was with "nul" (just ONE L).
The correct new fragment is:
<field id="location" type="select" options="'lp0'=>'LOCAL_PRINTER_0',
'lp1'=>'LOCAL_PRINTER_1','lp2'=>'LOCAL_PRINTER_2','remote'=>'NET_PRINTER',
'usb/lp0'=>'FIRST_USB_PRINTER','usb/lp1'=>'SECOND_USB_PRINTER',
'null'=>'DevNull'"
value="remote" validation="nonblank">
<label>LOCATION</label>
Now I have a fake printer!

And can create lot of new fake printer as needed! using SME interface.
Should I add a NFR to include this ?

Regards
Jáder