Operating System - HP-UX
1825001 Members
2635 Online
109678 Solutions
New Discussion юеВ

Re: Restoring all my printers

 
Robin King_1
Regular Advisor

Restoring all my printers

Something happened today that basically removed all the printers on one of my servers.
I'm trying to see if I can recover them from the backup tape instead of manually recreating them all. I'm not having much luck.

I've restored the contents of /var/spool and /etc/lp. The printers now show up in SAM, but the "Enabled to Print" and "Accepting Requests" fields are blank, and sure enough you can't actually print to them.

I've tried the save/restore spooler option to see if that would resolve any problems but I guess it's just saving something it's not happy with, and restoring to the same point.

How can I recover all these printers?

9 REPLIES 9
Raj D.
Honored Contributor

Re: Restoring all my printers

Hi Robin,

Have you checked the entries in /etc/hosts is present for these printers, [ Assuming printers are remote ]

Also stop and start the scheduler , and check ,


hth,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "
Robert-Jan Goossens
Honored Contributor

Re: Restoring all my printers

Hi,

You would not happen to have an other server with the same printers configured ?

Robert-Jan
Robin King_1
Regular Advisor

Re: Restoring all my printers

All the printers defiinitions are in DNS, and I have tried stopping and restarting the scheduler.

I've got other systems that have similar printers, but I can't guarentee they are all going to be there. I guess you're suggesting dooing a spooler save on the other system, then ftp over /var/spool/lp, and restore?

Helen French
Honored Contributor

Re: Restoring all my printers

if you have a copy of an old 'save spooler' configuration, then restore that file and then restore the spooler configuration.

I would also check what cause this problem and that might give you a better idea to troubleshoot the issue. If only some files have been deleted, then restoring files is the option. Restore files from /usr/lib/lp, /etc/lp, /var/spool/lp and /var/adm/lp. Also make sure your print configuration is working okay by creating a new test print queue.
Life is a promise, fulfill it!
Leif Halvarsson_2
Honored Contributor

Re: Restoring all my printers

Hi,
It don't help you at this time but, maybe the next ...

In SAM, "Printers and Plotters" you can find an option, "Save/Restore Printer configuration" .
Robin King_1
Regular Advisor

Re: Restoring all my printers

The "issue" was human error ;o)

I'm restoring the files again, so I guess I'll wait and see if it works better this time.
Robert-Jan Goossens
Honored Contributor

Re: Restoring all my printers

Yes :-)

1) Save the currently defined printer configurations:

on a good system

# /usr/sam/lbin/lpmgr -S -v -xsavedir=/tmp/printers

2) copy directory /tmp/printers onto the other server

3) Restore the printer configurations:

# /usr/sam/lbin/lpmgr -R -v -xsavedir=/tmp/printers

Regards,
Robert-Jan
Raj D.
Honored Contributor

Re: Restoring all my printers

Hi Robin,


You need to restore all this , to get the printers work properly:


This all files are responsible for keeping the printer configuration and informations:
-----------------------------------------------------------------------------------------
drwxr-xr-x 2 root sys 1024 Sep 21 16:49 cinterface
drwxr-xr-x 2 root sys 96 Sep 21 16:49 class
-rw-r--r-- 1 root sys 8 Sep 21 16:49 default
drwxr-xr-x 2 root sys 96 Sep 21 16:49 dev
drwxr-xr-x 3 root sys 1024 Sep 21 16:49 interface
-rw-r--r-- 1 root sys 527 Sep 21 16:49 lpinfo
drwxr-xr-x 2 root sys 1024 Sep 21 16:49 member
-rw-r--r-- 1 root sys 13608 Sep 21 16:49 pstatus
drwxr-xr-x 2 root sys 1024 Sep 21 16:49 sinterface
-rw-r--r-- 1 root sys 18 Sep 21 16:49 timestamp
---------------------------------------------------------------------------------------


Cheers,
Raj.

" If u think u can , If u think u cannot , - You are always Right . "
Raj D.
Honored Contributor

Re: Restoring all my printers

Robin,

The dev directory above mentioned is not the /dev directory , but its /var/sam/lp/dev .

Cheers,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "