Ask Leo! by Leo A. Notenboom

How do I fix a cyclic redundancy check error when I try to copy a file?

Search First! Then browse: Categories | Full Archive | By Date | Newsletter

Home » Hardware » Disks and Mass Storage

Summary: CRC errors happen when there's a bad spot on the media of your hard disk. Data recovery and disk repair are often possible with the right tools.

Outlook started acting up, so as part of my attempts to fix it I tried to copy the PST to another location. The copy failed part way through with a cyclic redundancy check error. How can I get past this and backup my data?

The cyclic redundancy check, or "CRC" error, indicates a bad spot on your hard drive. The fact that you're seeing it when you try to copy a file indicates that the bad spot may be within the file itself.

We need to verify that and then we need to try to recovery your file and repair your hard drive.

First, let's make sure that the problem is actually with the file you're copying since it's equally likely that the problem is with the location you're copying too. This is easy. Fire up a Command Prompt window, and then copy the file to NUL:

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\>CD (to wherever the file is located)

C:\wherever>copy Outlook.pst NUL
1 file(s) copied.

This reads the entire file by copying it "nowhere". If this succeeds, the problem is not actually with the file itself, but the location you were trying to copy it to. My recommendation would be to copy it to a different disk entirely, or a different machine on your local network.

If this copy fails, then we've confirmed that the bad sector on your hard disk is actually being used by some portion of your file.

Now that we've confirmed that the problem is in fact in the file itself, we need to make as best a copy of it as we can, somewhere else. This sets a position of "it can't get any worse than this". Some data within the file may be lost, but you'll have copied as much as possible before the recovery efforts.

Once again, we want to copy the file to some different hard disk, or some other machine on your local network. And once again we need to do this within the command prompt:

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\>CD (to wherever the file is located)

C:\wherever>xcopy /c Outlook.pst D:
1 file(s) copied.

Two important things to note here: we've used the xcopy (for eXtended copy) command, and we've added the "/C" switch which keeps copying even if errors are encountered. As you've already experienced, the default behavior of both COPY and XCOPY is to stop if an error occurs.

Now that we've got a "no worse than" backup copy, we can start attempting to repair the disk.

If you're willing to spend $89 (as I write this) then there's a very good chance we can simply repair the hard drive.

I'm a huge fan of SpinRite.

SpinRite is a hard drive recovery and maintenance program. When you run it, it will perform a lengthy and exhaustive analysis of your hard disk without modifying its contents. Exactly how it does what it does is probably too technical and lengthy for this space, but one of the most important things that it does is simply this:

If a bad sector can be recovered, SpinRite will recover it.
"My recommendation would be to copy it to a different disk entirely, or a different machine on your local network."

And many, though of course not all, bad sectors can be recovered using SpinRite.

The net result is that after running SpinRite on the drive, it will either recover the sectors and you'll have a good, working hard disk once again, or it won't - and you'll know with some confidence that the disk cannot be recovered.

In the first case, if SpinRite is actually able to recover the sector for you, then unless SpinRite tells you otherwise, I'd then happily reboot and continue using the hard drive.

If SpinRite is unable to recover some data on your hard drive, I would first reboot into Windows and, as we did above, make another copy of the file. While SpinRite may not have recovered all the bad sectors on your hard drive, it could have repaired some, and those might have been the ones causing the problem with the file you're trying to access. I would not overwrite our first "no worse than" copy, but I would save this new file, as a kind of "possibly better" copy. And then I'd plan on replacing the drive.

If you're not up for spending the money for SpinRite, then Window's own CHKDSK utility is the next best thing. It's not as thorough, and it doesn't perform the same deep analysis and recovery as SpinRite, but it can, in fact, recover from some types of hard disk failures.

Once again, in the Command Prompt:

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\>CHKDSK /R

The "/R" parameter indicates that CHKDSK should check for errors and repair them as best it can.

Important: if this is your system drive (most often C:), this command will not actually run the operation immediately, but will schedule it for the next reboot. You'll need to reboot to actually make it happen.

After it's done, try making another copy of the file. If it doesn't work, then obviously CHKDSK wasn't able to repair the error you're experiencing. If it does, however, save that copy as a possibly fixed copy of your file.

Even if CHKDSK does repair the problem, I'm actually torn on how much to continue to trust the hard disk. You could still experience future failures.

Though I suppose that's true for any hard disk, after any utility is used. Or not.

At this point, if none of the steps above have repaired the bad sector or otherwise recovered your file, you're just a little bit screwed.

It's now time to work with the best-effort file that you saved earlier and, depending on what kind of file it is, try to recover the contents. In your example, an Outlook PST file, that means running scanpst on it, which will scan the contents of the file and attempt to recover what it can. There most likely will be data loss. Sometimes a lot of data loss. That's why I encourage you to never run utilities like scanpst on your only copy of the file. You always want the original to go back to in case there's something else in it that you can recover manually.

For other types of files and applications, it'll depend entirely on the specifics of that application as to how it will deal with a partially corrupt file, and whether or not it can be repaired.

And that brings me to my last point.

If this was your only copy of the file - if you would have suffered significant data loss had this file become corrupt - you haven't been backing up.

Start.

This was a wake-up call. Even if we successfully recovered your file, you should be very scared.

Start backing up your important data. Now.

The next time there's a problem, you may not be as lucky.

Related:

Helpful? Get new articles weekly by email in my FREE newsletter!

Your Name:
Your Email:


Why Subscribe?

Article C2935 - February 15, 2007

Recent Comments
41 Comments

Thank you Leo,
I just followed your steps and after the "CHKDSK / R" I am now able to work with my files again !

Posted by: adigo at March 29, 2009 3:26 PM

i want instal a game name super dragonball z but some problem there i cant able to install it it so some crc error.........so how can i install it?

Posted by: omkar singh at June 3, 2009 6:22 AM

''how do i fix a crc error when i try to copy or install a file from dvd?''

Posted by: vinay eletem at June 6, 2009 4:55 AM

Leo, thanks a million!

XCOPY /c failed three times. I then used the XCOPY with /cf attributes and that worked!

I was able to copy and read the corrupted excel file!

Thanks Again,

Sales at MantraMediaStore.com

Posted by: YUREX at June 15, 2009 9:09 AM

When I tried "C:\>CHKDSK /R"
The console said:
"The type of the file system is NTFS.
Cannot lock current drive."
What should I do?

It should also have asked if you want to schedule the chkdsk for the next time the system is rebooted. Say yes.
- Leo
08-Jul-2009

Posted by: William Surya Permana at July 7, 2009 11:54 PM

hello everyone....i believe i have had this CRC error long time ago...the problem may look little but can be very effective since using variable registry softwares and change of directory doesnt actually solve the problem....the first time i had this problem i tried every possible way to fix the problem...but later on i found the only issue tht has brought to this problem is the RAM itself....sometimes the RAM may work well but not necessarily the RAM is working well for installing softwares or games....i suggest tht a RAM checkup is necessary orelse the only other issue can be coz of the Motherboard...

Posted by: Kaizer Christ at August 31, 2009 10:02 AM

Hello Leo I have a very basic question. I am trying to follow the instructions; however, I do not know what exactly to type into the first command prompt to tell it where to find the file. What is correct format I know the path C:\Documents and Settings\Kevin\Local Settings\Application Data\Microsoft\Outlook but any time I type any variation of this it tells me "whatItype" is not recognized as an internal or external command. I am using Windows XP...

Much thanks !

Posted by: Kevin at September 17, 2009 11:38 PM

Hey Leo, I dont understand the command prompt functions. if i get a crc error on drive F, how would i type it in on the command prompt? thanks

Posted by: Dan at October 15, 2009 9:49 PM

This also happened with DvDs while using DvD Shrink on protected discs. This will fix your DvD problems:
Cyclic Redundancy Check Error – Data Error While Burning Dvds

.-=DragonWingz=-.

Posted by: DragonWingz at October 21, 2009 2:41 PM

Just wondering Leo, don't you think it is more advisable to just replace the drive, is total failure not eminant.? when it starts to spit out crc errors. My neighbor brought me a laptop that would not boot, I installed a new operating system onit and it was fine untill I started installing programs and got crc errors. Check disk reveiled a bad block chkdsk /r found dozens of orphaned files,is this not the pretence of doom for this drive? And lastly what article at the top of this page are you refering to that I should read or this post will be ignored, I clicked on "Read the article at the top of this Page" but fail to see the relevance, with all due respect. I gave them a two year old drive from one of my machines and in 3 weeks it failed on them. They must have dropped it or the dog knocked it off the table, so why not tell people that it could be the end of the line for their drive and casper it to a new drive and remain worry free for a few years.
Later
Chuck

The article at the top of the page is the article you're commenting on. People regularly post comments when it's clear that they haven't even bothered to read the article, hence my admonition that they do so.

As for advising them to discard a drive - it's a tough call. The fact is that a "rash of CRC errors" need not mean that the drive is about to fail completely. It could, of course, but it's also not guaranteed. Very often running a tool like SpinRite will both recover the data (something giving up will not do), and refresh the media such that the bad areas are either repaired (magnetic errors) or avoided (physical errors). Data recovery is, after all, an important consideration. With drives being as cheap as they are these days, it's hard not to argue for replacement if recovery isn't an issue, but even then it's not always a simple call.
Leo
25-Oct-2009

Posted by: Chuck Simpson at October 24, 2009 10:07 PM

Post a comment on "How do I fix a cyclic redundancy check error when I try to copy a file?":






(Email Address will not be published.)

Remember Me?

By popular demand...
my tip jar
Cuppa Joe
Buy Leo a Latte!

(you may use HTML tags for style)

RSS feed Subscribe to the RSS Feed specifically for comments on this article.

Before commenting, please...

  • Read the article at the top of this page. If your comment shows you didn't, it'll be deleted and ignored.

  • Comment only on this article. Use the Google search box at the top of the page if you have a question about something else.

  • Don't include personal information in the comment. No email addresses. No phone numbers. No physical addresses.

  • Don't spam. Excessive links to unrelated sites within a comment or across multiple comments will cause all such comments to be removed.

  • Don't ask me to recover lost passwords or hacked accounts. I can't, and those comments will be deleted.

  • I can't respond to every comment. And I can't vouch for the accuracy of others who do.

Please wait. Your comment is being processed ...


Question? Ask Leo!