I have a new installation of FreeBSD:
I've enabled printing in rc.conf:
I've created a spool directory
I've created an interface file:
And I've edited /etc/printcap:
If I try to send a text file to the printer (# lp /etc/rc.conf) I get no output and lpq shows no queued files. I have another FreeBSD system which, although older (FreeBSD 10.3) seems to be set up identically, is on the same ntework and prints successfully to the target printer. Really I'm at a loss as to how to diagnose this. What tools should I be using to try to understand what's going on. Advice please. Ta.
Code:
uname -a
FreeBSD pr5.blank.blank 13.1-RELEASE FreeBSD 13.1-RELEASE releng/13.1-n250148-fc952ac2212 GENERIC amd64
I've enabled printing in rc.conf:
Code:
# more /etc/rc.conf
saver="blank"
blanktime="30"
clear_tmp_enable="NO"
usbd_enable="YES"
lpd_enable="YES"
samba_server_enable="YES"
#ftpd_enable="YES"
zfs_enable="YES"
# disable sendmail to avoid issues with DNS and hostname
sendmail_enable="NONE"
keymap="uk"
hostname="pr5.blank.blank"
ifconfig_re0="inet 192.168.0.5 netmask 255.255.255.0"
defaultrouter="192.168.0.2"
sshd_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
################## eof rc.conf #########################
I've created a spool directory
Code:
root@pr5:/var/spool # ls -lrt
total 29
drwx------ 2 root daemon 2 May 12 09:15 opielocks
drwxr-xr-x 2 root daemon 2 May 12 09:15 mqueue
drwxr-xr-x 2 root daemon 2 May 12 09:15 lpd
drwxrwx--- 2 root mail 2 May 12 09:15 dma
drwxr-xr-x 3 root daemon 4 Sep 12 11:15 output
drwxrwxr-x 2 uucp dialer 3 Nov 8 06:05 lock
drwxrwxrwx 2 root wheel 2 Nov 8 13:05 lp
drwxrwxrwx 2 root wheel 2 Nov 8 13:06 raw
drwxrwx--- 2 smmsp smmsp 830 Nov 8 13:46 clientmqueue
drwxrwxrwx 2 root wheel 5 Nov 8 13:46 brother
I've created an interface file:
Code:
more /usr/local/libexec/broif
#! /bin/sh
#/usr/local/libexec/broif
# interface file for Brother HL-2150N
printf "\033&k2G" && cat && printf "\033&l0H" && exit 0
# NB elle nought capital aitch in the second prinf
exit 2
################ eof broif ############################
And I've edited /etc/printcap:
Code:
/etc/printcap:
lp|printer|default|Brother HL-2150N:lp=:rm=192.168.0.11:rp=brother:sd=/var/spool/brother:if=/usr/local/libexec/broif:
################### eof printcap #######################
If I try to send a text file to the printer (# lp /etc/rc.conf) I get no output and lpq shows no queued files. I have another FreeBSD system which, although older (FreeBSD 10.3) seems to be set up identically, is on the same ntework and prints successfully to the target printer. Really I'm at a loss as to how to diagnose this. What tools should I be using to try to understand what's going on. Advice please. Ta.