Operating System - HP-UX
1834662 Members
2783 Online
110069 Solutions
New Discussion

Re: Restore print Queue....with jobs that were backed up????

 
SOLVED
Go to solution
jmckinzie
Super Advisor

Restore print Queue....with jobs that were backed up????

I have a request to restore the print queue

/etc/lp/interface/printqueue from a few weeks ago....

The user community is expecting that a job will be returned to the queue...is this actually the case?

Thanks,
8 REPLIES 8
Steven E. Protter
Exalted Contributor
Solution

Re: Restore print Queue....with jobs that were backed up????

Shalom,

Yes this is actually the case if you are spooling using lp. This means you are actually restoring to /var/spool because thats the actual location where lp jobs are spooled.

If you are using a third party spooler, you'll need to refer to the documentation that came with it.

So a qualified yes, if my assumptions are correct.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
jmckinzie
Super Advisor

Re: Restore print Queue....with jobs that were backed up????

Steven,

Do i actually need to restore the /var/spool files or will the /etc/lp/interface/queue be sufficient?

Thanks,

Jody
jmckinzie
Super Advisor

Re: Restore print Queue....with jobs that were backed up????

Anyone have any ideas on this?

i sybolic links from /var/spool/lp/interface to /etc/lp/interface/queue

Any ideas on how i would restore this?
jmckinzie
Super Advisor

Re: Restore print Queue....with jobs that were backed up????

We are using lp...

root@server:/var/spool/lp
# ll
total 1088
prw------- 1 lp lp 0 Mar 29 16:10 CLD_FIFO
prw------- 1 lp lp 0 Mar 29 16:10 FIFO
-rw-r----- 1 lp lp 0 Mar 7 16:30 SCHEDLOCK
lrwxrwxrwt 1 root sys 14 May 3 2006 Tclass -> /etc/lp/Tclass
lrwxrwxrwt 1 root sys 15 May 3 2006 Tmember -> /etc/lp/Tmember
lrwxr-xr-t 1 root sys 18 May 3 2006 cinterface -> /etc/lp/cinterface
lrwxr-xr-t 1 root sys 13 May 3 2006 class -> /etc/lp/class
lr-xr-xr-t 1 root sys 18 May 3 2006 cmodel -> /usr/lib/lp/cmodel
-rw-r--r-- 1 lp lp 8 Dec 20 15:14 default
lr-xr-xr-t 1 root sys 17 May 3 2006 fonts -> /usr/lib/lp/fonts
lrwxr-xr-t 1 root sys 12 May 3 2006 info -> /etc/lp/info
lrwxr-xr-t 1 root sys 17 May 3 2006 interface -> /etc/lp/interface
lrwxrwxrwt 1 root sys 15 May 3 2006 log -> /var/adm/lp/log
lrwxrwxrwt 1 root sys 21 May 3 2006 lpana.log -> /var/adm/lp/lpana.log
lrwxrwxrwt 1 root sys 19 May 3 2006 lpd.log -> /var/adm/lp/lpd.log
lrwxr-xr-t 1 root sys 14 May 3 2006 member -> /etc/lp/member
lr-xr-xr-t 1 root sys 17 May 3 2006 model -> /usr/lib/lp/model
-rw-r--r-- 1 lp lp 413008 Mar 29 16:10 outputq
-rw-r--r-- 1 lp lp 77868 Mar 29 16:10 pstatus
-rw-r--r-- 1 lp lp 19364 Mar 7 16:30 qstatus
drwxr-xr-x 2 lp bin 96 Nov 15 2000 receive
drwxr-xr-x 106 lp bin 8192 Mar 7 16:30 request
-rw-r--r-- 1 lp lp 5 Mar 29 16:10 seqfile
lrwxr-xr-t 1 root sys 18 May 3 2006 sinterface -> /etc/lp/sinterface
lr-xr-xr-t 1 root sys 18 May 3 2006 smodel -> /usr/lib/lp/smodel
A. Clay Stephenson
Acclaimed Contributor

Re: Restore print Queue....with jobs that were backed up????

This is one of those "it depends" answers and rather than restoring the print queue as it was, let's try a Plan B.

If you have a nice backup/restore utility like Data Protector then examine your backups for the desired time. Look in /var/spool/lp/request/YOURPRINTQUEUE. The files spooled themselves will be named "dAxxxxx". Restore these files to a new location and then submit NEW lp jobs for each of these files. If you are not running a nice backup/restore system then the process is the same but more difficult to do. If you have DP, you can select the files of interest in a GUI, with other backups, it will be a bit more painful.

If it ain't broke, I can fix that.
jmckinzie
Super Advisor

Re: Restore print Queue....with jobs that were backed up????

Ok, sounds pretty good. I am restoring the files now but how do i submit new LP jobs for them?

An example of one of my files is: da3069

But that is what we want them to be....

So, again how do i submit another print job for each of these files?

Thanks,

TIA

-Jody

A. Clay Stephenson
Acclaimed Contributor

Re: Restore print Queue....with jobs that were backed up????

Where did you go to UNIX school? That part is trivially simple.

Question: How would I send the file "/Huey/Louie/Dewey" to the print queue DonaldDuck?

Answer: lp -dDonaldDuck /Huey/Louie/Dewey

You should be able to extrapolate from that point. Note that I said that you should restore the dA* files to an alternate location because only the lp subsystem should ever write to the /var/spool/lp/requests directories.
If it ain't broke, I can fix that.
jmckinzie
Super Advisor

Re: Restore print Queue....with jobs that were backed up????

restored files to :

/var/spool/lp/requests