• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

What DOS Command Do I Use?

BChico

Platinum Member
I want to make a copy of a hard drive. What command do i need to do it in dos? If there is a better way let me know.

Thanks,
 
Get Norton Ghost and create an image of the entire drive and then dump it to CD or another drive.

If you have to copy everything from a DOS prompt use xcopy.

Why do you have to do it in DOS?

Thorin
 
In a windowed DOS mode if you're using Win9X OS, XCOPY [source drive:] [target drive:] /r/i/c/h/k/e/y. Or just use Norton's Ghost.
 
Yes. Use XCOPY with the options I mentioned in a DOS window in a Windows environment. Do not do this in pure DOS session.
 
In DOS without a third party piece of software there is no way to make a copy of a HD. But you can use xcopy to copy all the contents of the drive (as outlined above). But if you're going to do xcopy then you may as well just open the drive hit ctrl+a and drag and drop it to wherever you are going to copy it to in windows.

Tell us what you're trying to accomplish and under what circumstances and we'll be better prepared to help you.

"Do not do this in pure DOS session. "

Why?

Thorin
 
I want to copy the contents of a drive, including windows, to another newer drive. Will i be able to copy the windows files while windows is running though?
 
Yes you'll be able to copy everything (at least you should be able to...you may have to kill a few apps or whatever). But the other drive won't be bootable.

Thorin
 
You won't be able to copy everything across while Windows is running because some files will be locked.

You should be able to get around most of that though: as long as you copy and not move. Just remember to exclude the swapfile/pagefile and the ShellIconCache.
 
Originally posted by: thorin


"Do not do this in pure DOS session. "

Why?

Thorin

Some of the above XCOPY switches will not work in pure DOS session and LFNs (long filenames) will not be copied accurately to your target hard drive.

This is a discussion in the Win98-L mailing list, 3 years back:

"On Tue, 27 Jul 1999 06:10:29 -0700, newmail <newmail@snail-mail.net> wrote:

> Let me ask you this, in the event of a crash, could I
> reinstall WIN98 and then use xcopy /r/i/c/h/y to restore
> the files that were saved using this same command from my
> 2.1GB removable orb drive? Would my C drive then be exactly
> like it was when the backup was made? Basically, I'm trying
> to image my C drive using my removable disk drive, without
> using backup software. Is there a better way?

This would work up to a point. Since the GUI has to be running for the
/r/i/c/h/k/e/y (notice the slight difference from what you wrote) command line
switches to be available, it also presents a problem when you are trying to
copy over your current installation because some of the files will be "locked"
by windows and the xcopy will not be able to overwrite them. Therefore you
would not end up with an exact duplicate of your backup. Unless you have the
ability to boot and start the GUI from your removable drive, or have another
HD that you can use I really don't think that xcopy is the right tool for you.
As far as backup software goes, I personally like Ghost. You can create an
image file from either Real Mode DOS or the GUI and you can restore the image
from Real Mode DOS and end up with an exact dupe of what you saved to the
image. There are other programs that other list members use and may prefer
but this is my personal preference for not special reason other than it works
fine, and has never caused me a problem, so I haven't bothered to try anything
else."


http://peach.ease.lsoft.com/scripts/wa.exe?A2=ind9907D&L=win98-l&P=R6764&I=-3
 
Hmmm that's interesting (thanks for the quotage and linkage) I know that was a problem in 95 but I thought they added a long filename switch for 98 and above.

Thorin
 
As others have said, you can use xcopy but it must be done from inside Windows. It is best to do this in "Safe Mode" as windows holds almost no files open in Safe Mode. You have to do it from inside of Windows because you will lose your long file name info if you do it in a raw DOS mode and somw of the necessary switches are unavailable in the DOS version of Xcopy. The switches I use are : /s /e /c /q /h /r /k /y .
I suggest deleting your virtual memory file from the new drive after you get done Xcopying and it will be rebuilt the first time Win boots from the new drive. Also, the target drive must be FDISKed and FORMATted prior to doing the copy process.
.bh.
 
There is a utility called xxcopy (not a microsoft product) and its free and it can do longfile names in pure dos and I believe make a complete copy.

xxcopy
 
I just hopped over to the xxcopy site and saw that the 16-bit (DOS version) only supports 8.3 file names. I have not yet used either as I just DLd them, but that's the way it reads to me. IAC, thanks for pointing out xxcopy. I'm sure I will soon find use for it <g>.
.bh.
 
I am pretty sure that xxcopy (not just the xxcopy16) also works in pure dos because it has a /clone switch which will make a working copy on a sys'ed and active partition. If you run out of a command prompt you aren't likely to get all of the locked files.
 
If you've got a major brand hard drive (e.g. maxtor, western digital) download and run their system tools (MaxBlast, Data(Life?)Guard). Follow the instructions to make an exact copy of your old drive.
 
Back
Top