Operating System - HP-UX
1847524 Members
3248 Online
110265 Solutions
New Discussion

Re: Add a new print queue

 
Jagadesh_2
Regular Advisor

Add a new print queue

Hi,

I need to add a new print queue to one of my HPUX 11.11 server.

How can i go about in creating the same?

How to find which printer is configured with the server. I need to add the print queue xxxx to the same.
6 REPLIES 6
Pete Randall
Outstanding Contributor

Re: Add a new print queue

Well, you could use SAM.

You could also use the command line to add an lp spooler based printer:

lpadmin -p$PRNTR -orm[domainname] -orp[queuename] -mrmodel -v/dev/null -ob3 -ocmrcmodel -osmrsmodel

- or -

if you use hppi:
addqueue -h [ipaddress] -q [queuename] -b off


Pete

Pete
Jagadesh_2
Regular Advisor

Re: Add a new print queue

When i use lpstat -r it show scheduler running.
How to find the printer name? (hope remote printer is configured for the same.. i am not sure abt that)

How to find the scheduler name?

I am having information abt
Hostname
queue name.. i dont have other info.. to create a print queue.
How to go about in creating the same.

Thanks
Olivier LEGRAND
Frequent Advisor

Re: Add a new print queue

And with jetadmin?
Jagadesh_2
Regular Advisor

Re: Add a new print queue

Please let me how to create on both Jetadmin as well as lpadmin.
Jagadesh_2
Regular Advisor

Re: Add a new print queue

Hi Pete,

What does -b off mean in the addqueue command?
Bill Hassell
Honored Contributor

Re: Add a new print queue

Creating a printer queue that points to an existing printer queue is much easier than what is mentiond above. There are 3 different ways that printers can be connected (serial/parallel port, remote printer server and HP's proprietary JetDirect card) and each has very different ways to setup a printer queue.

The simplest way to do this is with a printer class. Create a printer class with the new print queue name and make the old printer queue a member. Now you can print to either queue name and the job goes to the same printer. Here are the steps assuming that prn001 is the old printer and prn002 is the new queue:

lpshut (turns off the spooler and stops all active printing)
lpadmin -pprn001 -cprn002
accept prn002
lpsched

Now you can print to either prn001 or prn002. Note that lpshut/lpsched are always required to make spooler changes. NOTE: lp commands (unlike most other Unix commands) requires that no space be between an option and the value, so lpadmin -p prn001 will not work, lp -pprn001 will work.

To answer your other questions:

JetAdmin has been obsolete for many years. The command is called hppi and it won't be useful UNLESS you have the printer connected directly to the network with an HP JetDirect interface card. If this is all true, then you can create as many queues pointing to the same printer as you want (the lp class technique above works just for one additional queue). In this case, use the addqueue command (but you need to know the printer's IP address or hostname). Assuming that prn001 has an IP address of 12.34.56.78:

/opt/hpnpl/bin/addqueue -q prn002 -h 12.34.56.78
/opt/hpnpl/bin/addqueue -q prn003 -h 12.34.56.78
/opt/hpnpl/bin/addqueue -q prn004 -h 12.34.56.78

And in the addqueue command (check the man page for addqueue), -b turns on/off the leading banner page, the page printed in fron of every job. You can always override the banner page setting on a per-job basis with the lp -onb or -ony options. Check the man page for net_ljx000 for more details.


Bill Hassell, sysadmin