1833051 Members
2486 Online
110049 Solutions
New Discussion

lpadmin problem

 
frans tigelaar
Occasional Advisor

lpadmin problem

Hi all,

I'm having problems to print to tray2 on a printer. This is what I do:

#lpadmin -p -v/dev/null -m -ob3 -tray2

And this is the answer:
lpadmin: illegal key "-otray2

Is it possible to upgrade "lpadmin" or am I doing something wrong. Btw also in jetadmin I can't select an other tray.
5 REPLIES 5
Graham Cameron_1
Honored Contributor

Re: lpadmin problem

Frans

You are using the wrong command.

"lpadmin" is for configuration.
"lp" is for printing.

The rest of your options look a little strange also.
try
"lp -d -ob3 -otray2 ".

This does depend on the printer scripts being set up to handle these options.

see
"man lp"
"man lpadmin"

-- Graham
Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done.
frans tigelaar
Occasional Advisor

Re: lpadmin problem

Hi Graham,

Thanks for the reply. it's not the "lp -d" command but the making of the queue "lpadmin" which is giving me troubles. The option "trayX" doesn't work (al my other queues are fine). I'm using HP-UX 11.00 B.

Is it possible that a newer version of "lpadmin" does support the "tray" option. A forum search learned me about this option. If so how do I upgrade this?
Bill Hassell
Honored Contributor

Re: lpadmin problem

lpadmin deletes, adds and modifies printer setup but has nothing to do with printer features. ALL option for printing occur using the lp command. The man page you need is: man net_ljx000 and your command would be:

lp -d -otray2

The word tray (or landscape or duplex, etc) does not appear anywhere in the lpadmin man page. All such options are controlled by the printer's model script which is located in /etc/lp/interface/model.orig and these options are triggered by the lp -o options.


Bill Hassell, sysadmin
frans tigelaar
Occasional Advisor

Re: lpadmin problem

Tnx Bill,

I have to give the option at "lp" instead of putting it in the queueu config file.
Bill Hassell
Honored Contributor

Re: lpadmin problem

Correct. The reason is that one job may need tray2 and another may want tray1. If lpadmin were to make the setting, it would apply to every job. Same thing goes for all the lp -o options like landscape, duplex, bannerpage, etc.


Bill Hassell, sysadmin