[HPADM] SUMMARY: Details for a print_queue created with addqueue.

From: Neil Paniraj (npaniraj@yahoo.com)
Date: Mon Jan 22 2007 - 11:21:10 EST


Fellow Admins:

Thanks for all those who responded. I am attaching the
solution sent by Bill Hassell which I made use of to
get my work done.

Thanks again.
NEIL
--- Bill Hassell <bill@billhassell.com> wrote:

> From: "Bill Hassell" <bill@billhassell.com>
> To: "'Neil Paniraj'" <npaniraj@yahoo.com>
> Subject: RE: [HPADM] Details for a print_queue
> created with addqueue.
> Date: Thu, 18 Jan 2007 15:27:55 -0500
>
> The addqueue command has been available in both hppi
> (HP Printer Installer)
> as well as the obsolete (and deprecated) jetadmin
> product. The details about
> the IP or hostname are available in one file (the
> interface file) while the
> modelscript is found in the subdirectory model.orig.
> The keyword: PERIPH=
> will always point to the printer's IP address or
> hostname (depends on how
> the printer was added). The what command will
> interrogate the model script
> for a what string (ie, $HEADER: ... line)
>
> This code will find the IP or hostname for each
> printer:
>
> grep ^PERIPH= /etc/lp/interface/*
>
> And for each script in the /etc/lp/directory that
> has a PERIPH= line,
> use this to find out the original model script's
> name:
>
> for JDPRN in $(echo /etc/lp/interface/model.orig/*)
> do
> MYPRN=$(basename $JDPRN)
> MYMODEL=$(basename $(what $JDPRN | tail -1 | awk
> '{print $2}') | cut -d.
> -f1)
> echo "printer $MYPRN uses $MYMODEL"
> done
>
> You can put the code together a bit better -- this
> was just a quicky.
>
> Bill
>
>
>
>
> > -----Original Message-----
> > From: hpux-admin-owner@DutchWorks.nl
> > [mailto:hpux-admin-owner@DutchWorks.nl] On Behalf
> Of Neil Paniraj
> > Sent: Thursday, January 18, 2007 1:17 PM
> > To: hpux-admin@DutchWorks.nl
> > Subject: [HPADM] Details for a print_queue created
> with addqueue.
> >
> >
> > Fellow SAs:
> >
> > We've been creating print queues using the command
> > /opt/hpnpl/bin/addqueue (not sure if it is still
> > called jetadmin).
> >
> >
> > Is there a way by which I can extract the details
> of
> > each printer from the command line. I need this to
> > write a script to collect details related to the
> > MODELSCRIPT and HOST IP Address of the printer and
> > other various details which I may need later.
> >
> > Thanks for your responses in advance.
> >
> > Regards,
> > NEIL
> >
> >
> >
> >
>
______________________________________________________________
> > ______________________
> > TV dinner still cooling?
> > Check out "Tonight's Picks" on Yahoo! TV.
> > http://tv.yahoo.com/
> >
> > --
> > ---> Please post QUESTIONS and
> SUMMARIES only!! <---
> > To subscribe/unsubscribe to this list,
> contact
> > majordomo@dutchworks.nl
> > Name: hpux-admin@dutchworks.nl Owner:
> > owner-hpux-admin@dutchworks.nl
> >
> > Archives:
> ftp.dutchworks.nl:/pub/digests/hpux-admin
> > (FTP, browse only)
> >
> http://www.dutchworks.nl/htbin/hpsysadmin (Web,
> > browse & search)
> >
> >
> >
>
>

 
____________________________________________________________________________________
Never miss an email again!
Yahoo! Toolbar alerts you the instant new Mail arrives.
http://tools.search.yahoo.com/toolbar/features/mail/

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:55 EDT