[cups.general] cannot invoke a interface script

Martin Kammerlander csad3934 at uibk.ac.at
Tue Aug 2 04:21:07 PDT 2005

Zitat von Johannes Meixner <jsmeix at suse.de>:

> I.e. it was actually sent from the As400 to the CUPS server via
> LPD protocol and accepted by the cups-lpd or did you copy it
> manually from the As400 on the CUPS server?
> If it was sent via LPD protocol and accepted by the cups-lpd
> then the problem is not the cups-lpd.

It was a manual copy!

When I add a normal physical printer than it is no problem to print from the
As400 example: lpadmin -p lp_file -E -v socket://pris05:9100

pris05 is a HP Laserjet..
This works fine!

When I would like to print it to a file and i create a queue:

lpadmin -p lp_file -E -v file:/path/to/file
Then nothing happens

Also nothing happens if I only add the interface:
lpadmin -p lp_file -E -i /path/to/interface

> Printer specific formatted files must be printed in "raw" mode
> because anything else confuses the CUPS filtering, see for example
> http://lists.suse.com/archive/suse-linux-e/2004-Nov/1186.html

Hmmm...But it is not possible to change the format of the file on the As400!!
Even if it would be possible we can not change the this format because this
would be have affect to other printing services :(

> If the As400 file appears as spool file in the CUPS spool directory
> (i.e. if there is a print job) then the cups-lpd has accepted it
> but further processing fails. To verify it, disable printing of
> this queue (but let it accept jobs).

further processing fails! (i.e. the print job appears on the queue but it never
invokes the interface: It forwards immediately after queueing the job to the
printer...if no real printer is specified then it takes the "file:/dev/null")

> Add an entry to /etc/cups/mime.types so that this file type
> can be recognized and then it is accepted by CUPS.
> Unknown file types are not accepted by the printing system.

This I haven't tried yet but I have really no Idea how this entry should look
like or what file type to take for the files of the As400!??

> A dirty workaround may be to enable 'application/octet-stream'
> in /etc/cups/mime.types but this way any user can "print" any
> nonsense data.
> E.g. any user can "print" the kernel using "lp /boot/vmlinuz"
> and then the printer would spit out tons of sheets with menaingless
> characters (/boot/vmlinuz contains several thousand formfeeds).
> Therefore it is good not to allow printing of unknown file types
> (in particular if normal users also use the print server).

This won't work I tried this in any possible combination!

> Alternatively it may work to force the cups-lpd to use
> -o document-format=application/vnd.cups-raw
> which indicates that the content is to be printed in "raw" mode
> (but then your filter script may not be started).

Hummm... unfortunatly is exactly the invoke of interface which I need ;)
I tried this altough but all remains the same

> Alternatively it may work to force the cups-lpd to use
> something like
> -o document-format=text/plain
> which forces CUPS to handle it as if it was plain text
> (regardless what it is in fact) and this should start your
> filter script.

Yea this seemed to be a good solution...I tried it but nothing changes

What is wrong with this first escape character in the As400 file?? any other
character written before the escape is accepted by cups and invokes the
interface :(

Any other Ideas?


More information about the cups mailing list