Off Topic: print accounting.

Joerg Lenneis lenneis at
Wed Sep 17 16:04:09 GMT 1997

Celso Kopp Webber <celsinho at> writes:

> 	Hi all, sorry for this off-topic message, but I would like to know
> if anyone is using any print accounting package under Linux, so that one
> could integrate with Samba in such a way that:
> 1. if a user print anything to a Samba shared printer, I would like to
> have an account system that counts how many pages he/she have printed,
> perhaps based on the number of bytes received by the spool system. I know
> that I can count the number of pages on a PostScript file, but I cannot do
> that when the data come from Windows drivers;
> 2. if a user has its print quota expired, than the system would not allow
> him to print, and send a message to his Win95 console, or perhaps send an
> e-mail.

[sig deleted]

Since we have been there, a couple of suggestions:

Accounting works best if you measure the pages that are physically
printed out as opposed to counting the pages in the print job. All
other solutions are prone to disgruntle users. Consider a scenario
where someone sends a 50+ pages document to the printer and there is a
paper jam halfway through that forces you to reset the printer. How
should the accounting systems know how many, if any pages, were
actually printed?  What about somebody who sends a 60 MB graphics file
that stuffs up the printer?

If this is an option for you, you might want to consider a networked
printer that supports a control language sent over the network. Both
HP and Lexmark offer these kind of printers and there are probably
others as well. I am familiar with the HP version and it allows you to
do things like to set or enquire about practically all of the printer
settings including an internal counter of the number of pages the
printer has printed over its lifetime (this counter is never
reset). You could then

	- get the current page count over the network
	- send the print job
	- get the page count again and charge the difference to the
	  user account

Please feel free to mail me if you need more details.



Joerg Lenneis

email: lenneis at

More information about the samba mailing list