ulimit -t for ghostscript

Christoph Litauer litauer at uni-koblenz.de
Thu Jul 1 07:44:17 PDT 2004

Suse 8.2
Cups 1.1.18

I have lots of problems printing to a HP Laserjet 4000. Using the 
Windows 2000 ppd file I had some documents that produced postscript 
errors. So I decided to use foomatic for that printer (with ijs).
Sometimes, documents printed from windows clients cause ghostscript to 
take 100% cpu usage and run forever (ESP ghostscript 7.07.1).
Because in that case the printers queue is blocked with those jobs I 
want to limit the amount of cpu time for that gs process (started by 
My first idea was writing a wrapper script:

ulimit -t 180
exec gs "$@"

Then I changed the FommaticCommandLine in the printers ppd file to point 
to the wrapper script.
This worked perfectly good except for one thing: The output is prepended 
with the following lines

%%[ ProductName: ESP Ghostscript ]%%
%%[Page: 1]%%

I wonder why this output does not appear if I don't use a wrapper. 
Anybody has an idea how to prevent those lines? Output redirection 
doesn't help because the lines and the ijs output are both written to 
stdout ...

Christoph Litauer                  litauer at uni-koblenz.de
Uni Koblenz, Computing Center,     http://www.uni-koblenz.de/~litauer
Postfach 201602, 56016 Koblenz     Fon: +49 261 287-1311, Fax: -100 1311
PGP-Key: http://www.uni-koblenz.de/~litauer/public-key.html

More information about the cups mailing list