Date: Wed, 17 Apr 2002 09:13:21 -0700 From: chip.wiegand@simrad.com To: freebsd-questions@freebsd.org Subject: if-simple filter won't work with printer Message-ID: <OF42497E2B.EA92F22F-ON88256B9E.0056477C-88256B9E.005927FB@simrad.no>
next in thread | raw e-mail | index | archive | help
I am setting up a HP952C on my FreeBSD-4.5r box on lpt0 and have printed
to
#lptest > /dev/lpt0
When I try to print
#lptest 20 5 | lpr -Php
I get the following error -
Apr 17 07:57:42 cwiegand2 lpd[90655]:
cannot execv /usr/local/libexec/if-simple
Apr 17 07:57:42 cwiegand2 lpd[90654]: hp:
job could not be printed (cfA000cwiegand2)
The file if-simple is directly from the handbook
#!/bin/sh
# if-simple - Simple text input filter for lpd
# Installed in /usr/local/libexec/if-simple
# Simply copies stdin to stdout. Ignores all filter arguments.
/bin/cat && exit 0
exit 2
with permissions set chmod 555
I also did chmod +x to see if that would make any differance, but it
doesn't.
/etc/hosts.lpd has the ip address as well as the computer name of the
machines that
will be printing to this printer, but right now the print server itself is
printing, so the others
will have to wait.
According to the error the problem is with the if-simple filter, which is
direct from the
handbook.
I noticed that even without a lf statement in the printcap that the
lpd-err is still written to,
while the handbook says that the messages would be sent to stdout. I added
the line
lf=/var/log/lp.log
and created the file lp.log, yet it does not write to hp.log, it writes to
lpd.errs. Is this something
that should be corrected in the handbook?
Here is my printcap file -
hp|lp|952C|HP952C:\
:sh:sd=/var/spool/lpd/hp:\
:lp=/dev/lpt0:\
:if=/usr/local/libexec/if-simple:\
:lf=/var/log/hp.log
Oh yeah, I also noticed in the manual a section about certain HP printers
not working correctly
in interrupt mode, so I ran
#lptcontrol -p -d /dev/lpt0
But it has made no differance.
When I run
#lpc restart all
I get this response -
hp: no daemon to abort
hp: daemon started
every time I do lpc restart all. Does this indicate the daemon is not
working at all? Running
#ps -aux | grep hp
does not show any such process.
Hopefully this is enough information to troubleshoot this problem. If not,
I'll provide whatever
else I can.
--
Chip Wiegand
Computer Services
Simrad, Inc
www.simradusa.com
chip.wiegand@simrad.com
"There is no reason anyone would want a computer in their home."
--Ken Olson, president, chairman and founder of Digital Equipment
Corporation, 1977
(They why do I have 9? Somebody help me!)
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?OF42497E2B.EA92F22F-ON88256B9E.0056477C-88256B9E.005927FB>
