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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Make a fast dd copy

Status
Not open for further replies.

7280

MIS
Apr 29, 2003
331
IT
Hi,
I need to copy a 36 gb disk to another one.
I issued this command but it's taking too much time:
dd if=/dev/rdsk/c1t0d0s2 of=/dev/rdsk/c1t2d0s2 bs=4096k
It's running from 1:30 hour.
Is there a fastest way?
How much do you think it will take?
I booted the system from cdrom.
Thanks

TArek
 
I think the time you are seeing is normal. You are essentially copying each sector of the disk even if there is no data on that sector. How much of the disk is full... Can you back up the disk using ufsdump and then restoring on the new disk. This would be much quicker since you are only loading data. There is more set up time this way. You have to partition and create a file system on the new disk.
 
The other option is, before doing the dd play with the bs numbers to check which gives you better performance.

S.
 
Make a copy of the slices / ufs filesystems first on the second disk and then mount them.

Then use "tar -cf - * | tar -x -", but lookup the tar option that keeps all the permissions. Will read and write only the data on the disk at the maximum speed of the system and also defrag the disk while doing it :).

Compression will not help you unless you are using rsh to do this across the network, and the network is slow and your processors VERY fast.


THIS WILL NOT HANDLE RAW SLICES such as a variety of databases use for their own filesystems. So don't do it :). only dd will cope.

Matthew

Family motto: Curvus, non infractus.
The Universe: God's novelty screensaver?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top