Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FBSD 4.5 and /dev/lpt0 weirdness

Status
Not open for further replies.

chenn

Technical User
Nov 9, 2000
106
0
0
DE
Hi folks.
Tried to install LPRng on a box running FreeBSD 4.5. I took ports of LPRng and IFHP both previously configured under Linux and was running excellent.
However FBSD always informs me about /dev/lpt0 - device busy, although I can print via 'lptest > /dev/lpt0'. I got some weird errors about 'fcntl F_SETFD' too... I was using the GENERIC kernel first and switched to a custom-kernel without any impact on the errors... dmesg is fine, permissions too.

Any hints? regards
chenn
 

lptcontrol -i
made lpt0 work for HP2100
alhough by using native lpr/lpd
 
Thanks gheist,
but 'lptcontrol -i' didn't have the desired effect.
I cut'n'pasted some logs, maybe the errors is based on my knowledge about FBSD...

dmesg gives:
ppc0: <Parallel port> at port 0x378-0x37f irq 7 on isa0
ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode
ppc0: FIFO with 16/16/15 bytes threshold
ppbus0: IEEE1284 device found /NIBBLE/PS2/ECP
Probing for PnP devices on ppbus0:
ppbus0: <Brother HL-1270N series> PRINTER PJL,PCL,PCLXL,POSTSCRIPT
lpt0: <Printer> on ppbus0
lpt0: Interrupt-driven port
ppi0: <Parallel I/O> on ppbus0

I'd say the printer rests on lpt0 which is fine (I can print via lptest >/dev/lpt0).

/dev/lpt0 perms:
crw-rw---- 1 root wheel 16, 0 Apr 23 15:23 /dev/lpt0

I tried changing them from 777 to 600 but couldn't get it working...

'lpq' gives:
Printer: lp@grandton
Queue: no printable jobs in queue
Status: lp: Checkwrite: fcntl F_SETFL of '/dev/lpt0' failed - Operation not supported by device at 15:20:53.193
Filter_status: ifhp 14:48:46.152 [176] Open_device: open '/dev/lpt0' failed - Device busy

Any ideas?

regards
chenn
 
lpq cannot read back a printer status from lpt0 - maybe it prints blindly without checking port status or it needs to use polled mode to get printer status ??? lptcontrol -p ???
 
Problem solved.
I solved the problem in a very unprofessional: installing CUPS as a port.
Everything is working fine now.

It seesm as if there is a problem within the ports of IFHP and LPRNG on FBSD 4.5.

have a nice time
regards
chenn
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top