Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

copy users and printers from one server to another

Status
Not open for further replies.

Scunningham99

Programmer
Sep 20, 2001
815
GB
Hi

What is the best method, if any at all for the following:-

Copy all users from the old box to the new box
Copy all the printers from the old box to the new box

Thanks in advance!



Sy UK
 
For the users, simply copy the entries from /etc/passwd and /etc/shadow to the corresponding files on the new server, and then copy their home directories.

For printers I think if you copy /etc/printers.conf and the entire contents of /etc/lp/printers and /etc/lp/interfaces and restart LP you should be fine.

Annihilannic.
 
Hi

I copied over /etc/lp/printers, /etc/lp/interfaces then edited /etc/printers.conf :-

more /etc/printers.conf
#
# If you hand edit this file, comments and structure may change.
# The preferred method of modifying this file is through the use of
# lpset(1M)
#
192_1:\
:bsdaddr=eurrccunx001,192_1,Solaris:

192_2:\
:bsdaddr=eurrccunx001,192_2,Solaris:


Changing :bsdaddr=<to new hostname>

printers does not seem to be working. Is there anything i need to do to devs dir.

one more note i have updated /etc/hosts file to reflect printers.





Sy UK
 
I forgot the /etc/hosts entries and hostname changes in printers.conf, well spotted.

Have you restarted LP? Use lpshun to stop it, and lpsched to start it again, then check the output of lpstat -p.

Annihilannic.
 
hi where are lpshun and lpsched located as cannot find on server ?

find / -name lpshun* -print



Sy UK
 
/usr/lib/lpshut
/usr/lib/lpsched
or
/etc/init.d/lp [stop | start]
 
Hi When i issue echo test|lp -d printer it does following:-

# echo test|lp -d 10_133
request id is 10_133-6 (standard input)

but just sticks in queue.

# lpstat -o
10_133-6 root 5 Feb 16 16:01

any ideas

also when i look in cde admintool iprinters reference /dev/<printer> but they are not there... Do i need to copy?!?!?

thanks in advance!

Sy UK
 
# lpstat -p 10_133
printer 10_133 disabled since Thu Feb 16 14:58:39 2006. available.
new printer
# enable 10_133
printer "10_133" now enabled
# lpstat -o
JetDirect lpd: no jobs queued on this port
# echo Test |lp -d 10_133
request id is 10_133-7 (standard input)
# lpstat -o
10_133-7 root 5 Feb 16 16:26
JetDirect lpd: no jobs queued on this port
# lpstat -o
10_133-7 root 5 Feb 16 16:26
JetDirect lpd: no jobs queued on this port

Sy UK
 
You didn't by any chance have the HP JetAdmin software installed on the source server?

Annihilannic.
 
yes i just noticed that myself after the post. does this cause any problems?

this is the package i have installed on the new box to mirror old box

# pkginfo -l HPNPL
PKGINST: HPNPL
NAME: JetDirect Printer Installer for Unix
CATEGORY: application
ARCH: sparc
VERSION: E.10.34
BASEDIR: /
VENDOR: HP
DESC: HP JetDirect Printer Installer for Unix package
PSTAMP: snbld26m28151818
INSTDATE: Feb 16 2006 17:40
STATUS: completely installed
FILES: 237 installed pathnames
2 shared pathnames
19 directories
176 executables
8688 blocks used (approx)

Sy UK
 
You need to download that package from the HP web site and install it on the new box....

It complicates things, but if you are lucky maybe just installing it on the new system will make the print queues start working. Fingers crossed!

Annihilannic.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top