I have been workin for about an hour tryin to print to a smb printer, and
it doesnt work.  the smb server is win98.  win98 shows the file being
spooled but it never finishes spooling nor starts printing(so far just
trying plain text.
I am running potato, and samba 2.0.7 with a smbprint script:

logfile=/tmp/smb-print.log
TRANS=0
eval acct_file=\${$#}
spool_dir=`dirname $acct_file`
config_file=/var/spool/lpd/smb/.config
eval `cat $config_file`

while getopts t c; do
  case $c in
    t)
       TRANS=1
       ;;

    '?')  # Bad parameters, ignore it ...
       ;;
  esac
echo "server $server, service $service" >> $logfile

        if [ $TRANS -eq 1 ]; then
          echo translate
        fi
        echo "print -"
        cat
) | /usr/bin/smbclient "\\\\$server\\$service" $password -U $server -N -P
>> $logfile

my /var/spool/lpd/smb/.config is:

server=printserver-noc
service=HPLASERJET4
password=""

(the printer has no password)

sample output from the log /tmp/smb-print.log:

server printserver-noc, service HPLASERJET4
added interface ip=2xx.1xx.xx5.1xx bcast=2xx.xx2.1xx.255
nmask=255.255.255.0
Got a positive name query response from xx9.x6x.xx5.xx4 ( xx.xx.xxx.xxx
)
smb: \> print -
putting file - as stdin-9159 (206.937 kb/s) (average 206.938 kb/s)

that is printing a raw text file with the command 

cat filename.txt | smbprint

nothing comes out.  I can configure this to print direct to the printer's
IP but for compadiblity purposes i'd rather get it workin through SMB so i
can print to printers that don't have their own IP.

ideas ??

nate

:::
http://www.aphroland.org/
http://www.linuxpowered.net/
[EMAIL PROTECTED]
3:41pm up 21:42, 2 users, load average: 1.00, 1.00, 1.00

Reply via email to