1823415 Members
2614 Online
109655 Solutions
New Discussion юеВ

Printing

 
SOLVED
Go to solution
Ron Brown_2
Frequent Advisor

Printing

Is there a way around the ping feature in hppi? I need to print from our main location to a printer at a remote location and the bandwidth provider has turned off ICMP.
should work...
11 REPLIES 11
Ron Brown_2
Frequent Advisor

Re: Printing

I should clarify that this is for a new printer setup.
should work...
Bill Hassell
Honored Contributor

Re: Printing

I am assuming that you are adding the printer using hppi or SAM. Use addqueue instead. Much, much faster and I don't believe that it uses ping. To add the printer at IP address 12.34.56.78 and call it ljet1200:

/opt/hpnpl/bin/addqueue -h 12.34.56.78 -q ljet1200


Bill Hassell, sysadmin
Ron Brown_2
Frequent Advisor

Re: Printing

How does one add a dumb printer? -q dumb? Thanks!
should work...
Ron Brown_2
Frequent Advisor

Re: Printing

Hmm...I still get an error that the host cannot be contacted. The man page for addqueue states that this uses SNMP to determine which devices are available. I do not have SNMP enabled at the remote site. Any thoughts?
should work...
Geoff Wild
Honored Contributor

Re: Printing

You need at least the following ports:

515 (spooler) , 9100, 9101,9102 (HP Jet Admin)

I think you need snmp as well - as programs like hpnpadmin use it.

For example, I use the following script to test remote connectivity to a printer through a firewall:

#!/bin/sh
#
# check printer status
# Geoff Wild

if [ $# -lt 1 -o \( $# -gt 1 -a $# -lt 4 \) ]
then
echo "Usage:"
echo "lpst \"printer\""
echo "Example:"
echo "lpst W052"
exit 1
fi
echo " "
/opt/hpnpl/bin/hpnpadmin $1
echo " "
lpstat -p$1 -v$1
echo " "
echo "Output Requests"
echo "-----------------------------------------------------------"
lpstat -o$1
echo " "
lpstat -r
echo " "


Output like:

# lpst.ibu LZA3

Printer State : ready to print


printer LZA3 is idle. enabled since Apr 4 13:13
fence priority : 0
device for LZA3: /dev/null

Output Requests
-----------------------------------------------------------
no entries

scheduler is running


Rgds...Geoff

Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Bill Hassell
Honored Contributor

Re: Printing

For a dumb printer, use -i 9998 (see the man page for addqueue and the -l option to list all the printer types). The JetDirect software (addqueue) assumes that a smart printer is attached so identification of the printer is tried for assignment of the correct model script.


Bill Hassell, sysadmin
Ron Brown_2
Frequent Advisor

Re: Printing

Geoff: thanks for the script, but I am still trying to get the printer configured.
should work...
Bill Hassell
Honored Contributor

Re: Printing

If hpnpadmin can't contact the printer, you'll have to get a network trace to see where the packets are being blocked. To see all the details about the remote printer, use:

/opt/hpnpl/bin/hpnpadmin -v

If hpnpadmin doesn't get through, then JetDirect will not work through your current firewall settings.


Bill Hassell, sysadmin
Geoff Wild
Honored Contributor
Solution

Re: Printing

Yes - in order to configure, use the addqueue command:

For example:

addqueue -i 9998 -h 10.128.26.107 -q TST9

That way you don't need ping...

But as I said above, in order to print you need the following ports open between the firewalls:

515 (spooler) , 9100, 9101,9102 (HP Jet Admin)



Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Ron Brown_2
Frequent Advisor

Re: Printing

That did it! Thanks. Now, I just have to figure out why control codes are not being passed to the printer...
should work...
Bill Hassell
Honored Contributor

Re: Printing

Keep in mind that there are no special codes in the 'dumb' model script. Those must be in the print file you send to the printer. Start with a simple text file (no speciall application) and add the escape sequences you need and see if they work.


Bill Hassell, sysadmin