Using samba to print to a win2003 shared printer
ive been rackin my brain over this for ages and i cant get my head around it.
The windows 2003 machine has a few shared printers running on it. At the moment it is just a basic install and it isnt a domain controller or part of a domain. When i setup the printer on my windows XP machine, it can print fine without any problems, but windows 2003.... nothing. Im pretty sure i need to supply a username and password but i have no clue on how to get it there.
im using the following command to print to the printer through samba
client="oak-2003" # client name here...
pshare="Comlaser" # and here printer share name
printfile="/tmp/smbspool.$$"
cat > $printfile 2>&1
if [ -s $printfile ] ; then
( echo "translate" ; echo "print $printfile" ; echo "quit" ) \
| /usr/bin/smbclient \\\\$client\\$pshare -N > /dev/null 2>&1
fi
rm -f $printfile
exit 0
The machine im trying to print from is running RedHat enterprise linux 3 and is running samba v3.
Thanks for any help!
|