Operating System - HP-UX
1823121 Members
3349 Online
109646 Solutions
New Discussion юеВ

Re: Copying printers from one server to another

 
Craig A. Sharp
Super Advisor

Copying printers from one server to another

SA's,

I have 83 printers on one server. I would like to have the same printers on another server.
Is there a way to duplicate these printers without having to enter each one on the second server?

Thanks,

Craig A. Sharp
Roush Industries
7 REPLIES 7
Rodney Hills
Honored Contributor

Re: Copying printers from one server to another

First copy over all files under /usr/spool/lp/interface/... from your old system to the new.

Create a shell script to run lpadmin for each printer. fyi- You can get a list of your current printers with "lpstat -a".
example print queue create-
lpadmin -plp1 -i/usr/spool/lp/interface/lp1 -v/dev/null

This will create the necessary print queue structures and use the same driver scripts as your older system.
There be dragons...
Jordan Bean
Honored Contributor

Re: Copying printers from one server to another

Assuming all servers are nearly identical and have the necessary software like JetAdmin, then the following should be sufficient:

save and tar the lp spooler config

# /usr/sam/lbin/lpmgr -S
# cd /var/sam; tar cf lp.tar lp

ftp lp.tar to each system's /var/sam dir and
untar and restore the lp spooler config

# cd /var/sam; rm -rf lp; tar xf lp.tar
# lpshut
# /usr/sam/lbin/lpmgr -R
# lpsched
Craig A. Sharp
Super Advisor

Re: Copying printers from one server to another

I only have a couple of jetdirect printer. All other printers are remote. Printer addresses are picked up via dns. Does this make a difference?

Craig
Victor_5
Trusted Contributor

Re: Copying printers from one server to another

Somebody else submitted a similar question a few days ago, see
http://forums.itrc.hp.com/cm/QuestionAnswer/1,1150,0xc09a663ce855d511abcd0090277a778c,00.html

Good luck!
Craig A. Sharp
Super Advisor

Re: Copying printers from one server to another

That is an interesting thread. It seems that the solution is based on the fact that they use all jetdirect connections.
I use a combination of jetdirect, axis and intel netport servers. I am concerned about weither or not moving by this method will still allow the print spooler to locate the printer by dns on the second server (assuming the second server has dns access).
Jordan Bean
Honored Contributor

Re: Copying printers from one server to another

/usr/sam/lbin/lpmgr makes no distinction between JetAdmin, Intel, Emulex, Lantronix, DEC, etc. It is only saving and restoring the lp spooler configuration as it is found in /etc/lp and /var/spool/lp. However, as a result of the LPD legacy, it does distinguish between local and remote printers, discussed later. How a document reaches a remote printer is the responsibility of the interface script in /etc/lp/interface, which may use software not native to HPUX LP Spooler system.

Local printers are not necessarily directly attached. If the local printer is directly attached, then the interface script will most likely be using the LP system's slp utility.

If the local printer is network attached, the interface software will use whatever is necessary to talk to the remote device. If JetDirect, then JetAdmin is used. If Emulex, then an Emulex utility is used.

Remote printers are nothing more than LPD accessible spoolers on remote servers, which could be UNIX, Windows NT/2k, JetDirect cards, or any other network device that understand LPD. For these printers the interface scripts will most likely be using the LP system's rlp utility.
Jordan Bean
Honored Contributor

Re: Copying printers from one server to another

long day... To answer Craig's question: Yes, or at least, most likely. If name resolution is appropriately configured and all the necessary "stuff" used by the lp interface scripts are available, then the spooler system will most be likely be able to find the remote printers. The saved configuration file /var/sam/lp/lpinfo will at least reveal how the rlp utility will locate a remote printer. For non-LP software, other config files, like /etc/printcap for example, will need to be manually duplicated (which was while we were maintaining DEC LPS spoolers).