System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

Will the following work to move printer files from multiple machines?

 
SOLVED
Go to solution
Highlighted
Jack C. Mahaffey
Super Advisor

Will the following work to move printer files from multiple machines?

1- Run lpmgr -S .... on each machine.
2- Copy the cloned 'lp' directories to a single machine.
3- Create a diretory structure with the saved info from the lpmgr -S commands for all the hosts.
4- Consolidate the directories. i.e. place the files in the member directories in a consolidated member directory that has entries for all the hosts. Ditto for other directories.
5 - Append the contents from the lpinfo files into a single file.
6 - Run lpmgr -R ... against the diretory that contains the printer directories and files for all the hosts.

Seems like it should work.


Question: Will it fail if printer names/IP addresses cannot be resolved?

4 REPLIES 4
Highlighted
Jim Mulshine
Frequent Advisor

Re: Will the following work to move printer files from multiple machines?

I don't know if that will work...never tried it. If it doesn't work for you maybe this will:

Run lpmgr -S and then lpmgr -R on each source machine. This will save the configuration and restore it again. It shouldn't change your spooler config, but it will provide you with all the lpadmin commands necessary to create each source machines spooler config. These commands will be found in /var/sam/log/samlog. You could create a script filled with lpadmin commands from each source machine and then run the scripts on the machine that you want to consolidate everything on.
Highlighted
Bill Hassell
Honored Contributor
Solution

Re: Will the following work to move printer files from multiple machines?

Using lpmgr will indeed save and restore the state of the spooler. Resolving names/IPaddresses is independent of the spooler. If you are not using a DNS server, just add the names to /etc/hosts and you're done. If you are using a DNS server, add them to the server. If that is not possible, add them to /etc/hosts and change /etc/nsswitch.conf to look in /etc/hosts when DNS fails to locate a name:

hosts: dns [NOTFOUND=continue UNAVAIL=continue] files [NOTFOUND=return UNAVAIL=return]

(the above is all on one line)


Bill Hassell, sysadmin
Highlighted
Jose Mosquera
Honored Contributor

Re: Will the following work to move printer files from multiple machines?

Hi,

In this case you must need resolution names just for mnemonic reason in a specific requirement (i.e. ping laser10 instead 192.1.234.8), always is easier and confortable rememember a name that an IP address.


Rgds.
Highlighted
Jack C. Mahaffey
Super Advisor

Re: Will the following work to move printer files from multiple machines?

Thanks all for the input. I think it worked!!! :)