Accounting and access control over a remote printer

From: <monica_at_alpha.qui.uam.es>
Date: Mon, 3 Mar 1997 15:28:59 +0100

Dear managers,

Until now, we had only one printer (HPlaserjet 5M) connected directly to
the net (it has its own IP address) for internal use. Now two color printers
are going to arrive (again with their own IP address) which should be
accessible remotely by other machines. On this two printers we want
to set up accounting so that we can charge for the printed jobs.


1) So my firs question is: how to do printer accounting on a remote printer??
Before we set up the new printers I wanted to be sure that one can
do printing-accounting. As all three printers are "remote" printers,
the af, if and of fields of the printcap ignored (it's assumed the remote
host will do this, but in this case there is no such remote host).

I found in the archives a summary of Raja Nagaraja explaining how to set
up a dummy printer so that he could do filtering on the jobs. I tried to
do the same in order to get accounting but it does not work.

Here is my printcap:

lp1|1|lp|lj5_ascii:\
        :af=/var/adm/printer/lj5_ascii.acct:\
        :if=/usr/lbin/hplaser4psof:\
        :lf=/usr/spool/lpd/lj5_ascii.log:\
        :lp=:\
        :of=/usr/lbin/hplaser4psof:\
        :rm=argos:\
        :rp=text:\
        :sd=/usr/spool/lpd/lj5_ascii:
# impresora del cccfc con accounting
lp2|2|text|nueva_lp1_con_acct:\
        :af=/usr/adm/lp2acct:\
        :lf=/usr/adm/lp2err:\
        :lp=/dev/null:\
        :mx#0:\
        :of=/usr/lbin/redirect:\
        :rs=true:\
        :sd=/usr/spool/lpd2:\
        :sh:\
        :xf=/usr/lbin/xf:

Where the file /usr/lbin/redirect is:
#!/bin/ksh
/bin/cat - | lpr -Plp1

It works fine except that nothing is written to /usr/adm/lp2acct nor
/var/adm/printer/lj5_ascii.acct.
What am I doing wrong??

2) My second question is the access permisions.
Is it possible to avoid everyone (except for a few privileged users) to use
the HPlaserjet printer and at the same time allow to everybody (also
remote machines) to access the new color printers??

Thanks in advace for your help
Monica
Received on Mon Mar 03 1997 - 15:55:40 NZDT

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:36 NZDT