How to duplicate a drive in Unix?


 
Thread Tools Search this Thread
Special Forums Hardware Filesystems, Disks and Memory How to duplicate a drive in Unix?
# 1  
Old 02-07-2002
How to duplicate a drive in Unix?

I have a drive that I need to make a sector-by-sector or exact image copy of. In Windows, I use a program call Ghost by Symantec, but the version I have does not support Unix.

Does anyone know of a good product for Unix?

Thanks,

Brett Gibson
Gibson Teldata, Inc.
# 2  
Old 02-07-2002
You can use dd for that. Lets say you want to create an image file of hda you would use : dd if=/dev/hda of=/tmp/hdaimage.

If you got 2 identical disks you could mirror them like this :
dd if=/dev/hda of=/dev/hdb
# 3  
Old 02-07-2002
Upgrade your version of Ghost. We have it and it works well. However.. let me caution you on something... When you make exact duplicates of hard drives, I assume that you are changing the liscensing information on the duplicated drive... Right?? Right??? Right???? =)
# 4  
Old 02-08-2002
Maybe he's setting up a homebrew MirrorDisk Smilie

# crontab -l

* * * * * dd if=/dec/hdc of=/dev/hdd >/dev/null 2>&1
# 5  
Old 02-26-2002
One guy reportedly did this with cat:

# cat /dev/hda >/dev/hdb

The disks were 100% identical, important for such things as sector sizes, etc.

The paranoid way would be to make filesystem, mount the second disk, and use cp -r.

This is what I do when I add one disk and, fx. move the /usr or /home tree to the new disk

Atle
# 6  
Old 02-27-2002
It's OK to do it with cat as well... I think people use dd because you have a little more control (blocksize, count size, etc...) than with cat.
I think it's the FreeBSD Install manual that says: to create the floppy boot image, simply cat boot.flp > /dev/fd0
# 7  
Old 02-27-2002
A not-so-known thing about FreeBSD:
I wanted to duplicate a disk, but couldn't for the life of me get it to work - how the H#&& do I get the SCSI-emulator to work, grrrr!!
Then I found burncd, worked right off the IDE, just like I would have done it.
".. just like I would have ... hmm, lets try .."

# cat /dev/acd0 >file.iso

YES! That is the way to duplicate a disk under FreeBSD:

You cat the CD and pipe it to the CD-R!

I became a _dedicated_ BSD fan after that :-)

Atle
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

FTP from Widows to UNIX system - how to? ( was To not to duplicate)

Dear team , thanks for your support. I am trying to not to duplicate a thread if one is already there for what I am looking, which I am not able to figure out. Is it OK if I post the post the following question in new thread. --- What follows was in blue.. we are to avoid using colours as we want... (4 Replies)
Discussion started by: ar103081
4 Replies

2. Shell Programming and Scripting

Bash Script to find/sort/move images/duplicate images from USB drive

Ultimately, I'm looking to create a script that allows me to plug in a usb drive with lots of jpegs on it & copy them over to a folder on my hard drive. So in the process of copying I am looking to hash check them, record dupes to a file, copy only 1 of the identical files (if it doesn't exsist... (1 Reply)
Discussion started by: JonaQuinn
1 Replies

3. UNIX for Dummies Questions & Answers

Need help to move .csv file from UNIX path to windows shared drive or c:\ drive

Hi Guys, Can any one help me on this. I need help to move .csv/.xls file from unix path to windows shared drive or c:\ drive? Regards, LKR (1 Reply)
Discussion started by: lakshmanraok117
1 Replies

4. UNIX for Dummies Questions & Answers

Duplicate column in unix file

Hello, I have a fixed width unix file with 2 columns containing the following data ZTXX_CTBR1-ZBRAN1 ZTXX_CTBR1-ZBRAN_DESC 01 CASH & CARRY 02 DRUGSTORE - RX 04 ... (4 Replies)
Discussion started by: chumsky
4 Replies

5. UNIX for Dummies Questions & Answers

Solaris 2.6 - Duplicate Filesystem to a larger slice(same drive)

One of our production systems has a slice called "oldslice" that periodically runs low on space during normal operation. We have minimum requirements for online data retention, and whoever sized this slice didn't give it much wiggle room, so it periodically runs low on space. I'm getting tired of... (1 Reply)
Discussion started by: the.gooch
1 Replies

6. UNIX for Dummies Questions & Answers

How to delete partial duplicate lines unix

hi :) I need to delete partial duplicate lines I have this in a file sihp8027,/opt/cf20,1980182 sihp8027,/opt/oracle/10gRelIIcd,155200016 sihp8027,/opt/oracle/10gRelIIcd,155200176 sihp8027,/var/opt/ERP,10376312 and need to leave it like this: sihp8027,/opt/cf20,1980182... (2 Replies)
Discussion started by: C|KiLLeR|S
2 Replies

7. UNIX for Advanced & Expert Users

RAM Drive in UNIX?

Hello, I will be processing 47000 zip files each of size 5.5 MB. Following operation will be performed for each zip file: 1. Unzip the file. 2. Read each text and binary file. 3. Preprocess the files. 4. Store the files in different tables in Oracle. 5. Delete the extracted... (7 Replies)
Discussion started by: joshivaibhav
7 Replies

8. UNIX for Dummies Questions & Answers

Sharing a Unix Drive Over The Internet ... but

I don't know if this can be done, otherwise, my project will come to a screeching halt. I have a SCO 5.0.5 machine connected to the internet with a static IP address. I need to be able to share a drive : /shareddrive I need to map to it from a windows machine: hence, what i'd like to... (3 Replies)
Discussion started by: gseyforth
3 Replies

9. UNIX for Dummies Questions & Answers

Tape Drive on Unix 7.1.1

I am trying to install a tape drive on this system (Unix 7.1.1) where will I start? 1. Do I need to load the driver on the on board scsi? How? 2. Is there a driver for the tape drive itself? Things done: 1. Terminated the device on the controller board. (4 Replies)
Discussion started by: a4tech
4 Replies

10. UNIX for Dummies Questions & Answers

unix on a small drive?

has any body put freebsd on a drive smaller than 80megs? (4 Replies)
Discussion started by: silverraindog
4 Replies
Login or Register to Ask a Question