Hi,

I want to move all of the mailboxes (all of /var/mail/*) on one machine to another one across a network. I need to preserve permissions, uid's and gud's. (It would probably be good to preserve modification times as well). I can move a file using scp, but it doesn't preserve uid/gid

I found this page: http://www.unixguide.net/ibm/faq/faq1.604.shtml which says I can do either:

$rsh RemoteHost "cd TargetDir; tar -cBf - ." | tar -xvBf -

or

rcp -rp host1:/dir host2:/dir

I'm trying it using a users home directory first just to make sure I can get this right, but so far I'm not having much luck.

Could someone here suggest the best way for me to move these mailboxes (and perhaps help me out a little with the actual syntax of the command I would use)?

I realise that there will be a problem with mailboxes that don't have usernames on the remote system (the system I'm copying the mailboxes to) but most of the users currently exist on the remote system, it will be easy enough to do a adduser to add in those that aren't already on there.

I hope I'm explaining myself clearly here, it's been a long day already  :-)

Thanks,

Lisa





--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.322 / Virus Database: 266.11.16 - Release Date: 5/24/2005

_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to