1833464 Members
2749 Online
110052 Solutions
New Discussion

Copy 70G Filesystem

 
brian_31
Super Advisor

Copy 70G Filesystem

I have to copy a 70G filesystem from one machine to another. what would be a good way?

Thanks

Brian
13 REPLIES 13
Steven E. Protter
Exalted Contributor

Re: Copy 70G Filesystem

Shalom Brian,

Best: fbackup frestore.

Not as good
scp -rp /fsname/* newhost:/fsname

Even less reliable
rcp -rp /fsname/* newhost:/fsname

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Steven E. Protter
Exalted Contributor

Re: Copy 70G Filesystem

Shalom Brian,

Best: fbackup frecover

Not as good
scp -rp /fsname/* newhost:/fsname

Even less reliable
rcp -rp /fsname/* newhost:/fsname

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Chan 007
Honored Contributor

Re: Copy 70G Filesystem

Can you also try NFS.

on mounting the source to target just use

find . -print |cpio -pmdv

Chan
Pete Randall
Outstanding Contributor

Re: Copy 70G Filesystem

Brian,

As Steve suggests, probably the best way would be to backup/restore. I always tend to run into permissions issues when I try to copy, whether rcp, scp or cpio. You might also want to look into vxdump.


Pete

Pete
Robert-Jan Goossens
Honored Contributor

Re: Copy 70G Filesystem

Hi Brian,

This depends on you network speed.

100mbFD max 10MB per second
1000mb max 50MB per second

if you have a gigabit network 70GB will take about 30 minutes to copy.

# cd /orig_filesystem
# find . | cpio -ov | remsh server_name "cd /copy_filestem ; cpio -idvum "

Robert-Jan
marvik
Regular Advisor

Re: Copy 70G Filesystem

Brian,

I just did a SAN migration using this

vxdump -0 -f- -b 1024 /src_fs | remsh '(cd /; /usr/sbin/vxrestore -b -xf -)'

just FYI incase u want to copy large FS in the same server use:
umount /fs1 (X series)
umount /fs2 ( Y series)

dd if=/dev/vgxx/rlvolx of=/dev/vgyy/rlvoly bs=1024k

Cheers!

marvik
brian_31
Super Advisor

Re: Copy 70G Filesystem

the filesystem in question is /oracle..how do i ensure the permission etc is same..please help

thanks

brian
James R. Ferguson
Acclaimed Contributor

Re: Copy 70G Filesystem

Hi Brian:

The use of 'fbackup'/'frecover' offers the ability to preserve any sparse files as sparse files, rather than inflating them at the destination. This should be another factor in your choice of copy methodology.

Regards!

...JRF...
Geoff Wild
Honored Contributor

Re: Copy 70G Filesystem

I would use fbackup as well or rdist(rsync).


fbackup -i . -f - | (remsh REMOTESERVER ; frecover -r -f - ) &

With rdist, you need to setup some files:

cat myscript.sh
#! /bin/sh

# Keep the DRP copy of the oracle up-to-date.
# Currently the files are in:
#
# /oracle
#
# See the rdist(1M) distfile for a list of exclusions.

DRPDIR=/app/admin/drp
DRPHOST=svr0031

HOST=`/usr/bin/uname -n`
( su - oracle -c "rdist -f $DRPDIR/distfile oracle"; ) 2>&1 |\
tee $DRPDIR/drp.log 2>&1 |\
mailx -s "oracle rdist output" sysadm


# cat distfile
ORACLEDR = ( svr0031 )

#
# File systems to be copied over to the DR host.
# Don't use -R in install - so as not to remove files on destination host
ORACLE = /oracle

oracle: ( ${ORACLE} ) -> ( ${ORACLEDR} )
install -w ;


Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
brian_31
Super Advisor

Re: Copy 70G Filesystem

Thanks

will this work..

on server A(source)

cd /oracle

fbackup -i . -f - | (remsh serverb ; frecover -r -f - /oracle ) &

Thanks

brian
marvik
Regular Advisor

Re: Copy 70G Filesystem

vxdump/vxrestore keeps all permissions intact.

U can also use this :: it will keep all permission fine

# cd srcdir && fbackup -i . -f - | ( cd dstdir && frecover -Xsrf - )

Now its ur call,u have many options :)
brian_31
Super Advisor

Re: Copy 70G Filesystem

Hi All:

I am using the vxdump and initially it failed becasuse after -b itexpects 1024 on vxrestore..then it worked but the permisiions are not same. it writes as root..how wd i fix this? i have aborted the dump now..

Thanks

brian
brian_31
Super Advisor

Re: Copy 70G Filesystem

just did a maqn vxdump and there are no pointers to permissions..any ideas?

Thanks

brian