Operating System - HP-UX
1833793 Members
2895 Online
110063 Solutions
New Discussion

Can I use jetdirect model script with lpadmin command?

 
SOLVED
Go to solution
Bonny Jose_2
Advisor

Can I use jetdirect model script with lpadmin command?

Hello Guys,
Have you ever tried copying one model script from /opt/hpnpl/sh/ to /usr/lib/lp/model to make use with lpadmin ? Will it work?

Basically I want to configure a laserjet printer (HP,lj1300)connected remotly on a D-Link Print server.None of the available script under /usr/lib/lp/model is working.But when i use the jetdirect model script net_lj4x with jetdirect printserver it works. But I want to make use of D-link printserver.
D-Link print server uses LPD.

Or is there any site I can download latest laserjet model scripts to use with lpadmin? I searched but all are for jetdirect.

All kinds of helps are appreciated
Thanks
Bonny Jose





3 REPLIES 3
Bill Hassell
Honored Contributor
Solution

Re: Can I use jetdirect model script with lpadmin command?

The model scripts are specific to HP products only, and more importantly, designed to work ONLY with HP's proprietary JetDirect protocol. The D-Link server, as you mentioned, is only LPD and specifically designed to have preformatted data files sent to the printer. This is a SysV implementation for lp and lpsched, and completely opposite to LPR/LPD which is a BSD standard. With BSD, all formatting is completed on the local machine while in SysV, formatting is accomplished on the remote machine--as long as the remote machine is SysV and understands the -o options.

What you are trying to do is to insert a local printer script in front of the remote printing (not network printing) feature and this only be done as a filter in front of the lp command such as:

myfilter -olandscape -vsi8.6 -oduplex /dir/file_to_print | lp -dsome_remote_printer

This limitation (feature) of SysV is common throughout the various SysV Unices. SO you'll have to live with a front-end filter to accomplish your preformatting. All printer scripts are shipped with HP-UX and can be modified to work as a filter as mentioned above. There is no way to easily integrate printer scripts into the design of remote printing for HP-UX.


Bill Hassell, sysadmin
Bonny Jose_2
Advisor

Re: Can I use jetdirect model script with lpadmin command?

Dear Bill,

What about the lpadmin command line remote printer setup?
lpadmin -p -v /dev/null -m -orp

see -m option, I am able to use modelscript for the remote printer. That means I should be able use any suitable modelscript instead of filter isn't it?

Bill Hassell
Honored Contributor

Re: Can I use jetdirect model script with lpadmin command?

No, the model script for a remote printer has nothing in common with local printers (like parallel or JetDirect). Read the rmodel script in /usr/lib/lp and you'll see that it is a front-end to the rlp command. Now with the clever script writing, you could insert code into the rmodel script to perform the filtering actions on $1, the print job for rlp.


Bill Hassell, sysadmin