Why does Explorer eject the CD after you finish burning it?


Partly as a convenience, but partly to work around buggy hardware. The developer responsible for CD burning explained it to me.

Most CD drives cache information about the disc in their internal memory to improve performance. However, some drives have a bug where they fail to update the cache after the CD has been written to. As a result, you can write some data to a CD, then ask the CD drive for the data you just wrote, and it won’t be there! The drive is returning the old cached data instead of the new data. For most drives, ejecting and reinserting the CD is enough to force the drive to update its internal cache.

“But wait, it gets worse!” I’m told.

Some drives are “smart” and realize you’ve reinserted the same media, and then don’t update. These drives require that you put in another type of media (or pressed CD-ROM media) to force them to update. These drives were manufactured around 2002, and new drives don’t have it this bad, but still have the above problem requiring an eject/insertion cycle.

So there’s your tip for the day. If you are burning data to a CD and you find the data isn’t there, try ejecting the disc and reinserting it. If your drive is particularly buggy, you’ll have to eject the disc, insert a different type of disc, then eject that second disc and reinsert the first one.

Comments (44)
  1. Inferis says:

    This behaviour should be user-customisable.

  2. Brian Carter says:

    What I don’t understand is: why, after burning a CD does the "Pick what you’d like to do" wizard pop-up? I suppose I could see one or two cases where people would burn photos to CD just to slideshow them, reimport them, etc…but it seems like such a low percentage.

    On a slightly more "emotional design" point, it makes me feel like the computer is being a bit like Dory from Finding Nemo. "Oooh, Hey! Look! A cd! It’s got pictures on it. Would you wanna get all of these pictures off of it and put them on your computer?"

  3. Gene says:

    This behaviour should be user-customisable.

    Hardware shouldn’t be so damn buggy!

    It should NEVER do this! It’s plain and simple buggy behaviour!

    How about the new "bug" where IDE hard disks don’t write their cache when told to, so they can appear faster on write benchmarks? They’re supposed to write out their cache and not reply "successful" until finished. Instead they just immediately give a "success" reply.

    Which can cause data loss on power down when the OS goes "now write any caches out please" and it DOESN’T.

    So you can lose data because the HD manufacturer wanted to appear faster on a benchmark. Bastards.

  4. oldnewthing says:

    "why, after burning a CD does the "Pick what you’d like to do" wizard pop-up?"

    ? After burning a CD, the disc is ejected. The "What do you want to do" doesn’t appear until you reinsert the disc, at which point it’s a fair question.

  5. AndrewSeven says:

    A little off this topic but I was wondering the other day about the behavior of removable media.

    If you have a floppy drive with no floppy or a cd drive with no cd in it and you happen to click on it in windows explorer, you get a modal dialog to tell you that there is nothing in the drive.

    Do you know if there is a reason why it has never been changed to just show a message in the file list pane instead?

  6. David Candy says:

    Inferis

    It is in the Propperty sheet for the drive in My Computer.

  7. Anon says:

    Why can’t the CD burning software "re-insert" the CD after ejecting it? Is there a programmatic or UI mechanism to reinsert the CD into the drive? Typically the first thing you do after burning a disk is confirm that everything got written to it properly.

  8. Billy says:

    Anon: Not all CD drives support reinserting the CD. On my laptop, for instance, the drive pops open on eject, but can’t be closed by the computer.

    Experiencing different behavior depending on the hardware attached to the computer probably isn’t their goal.

  9. syz says:

    Anon: Think about that for a second. Would you really want to get that call from your mom? "After it recorded the CD, the computer popped the disc out to give it to me, but then before I could take it, it took it back! What did I do wrong?

    Not to mention, I have on more than one occasion gotten a CD scratched up, or wedged into the drive at an awkward angle, when some well-meaning piece of software decided to close the tray on me while I was in the middle of loading or unloading a disc.

  10. Alan De Smet says:

    “Hardware shouldn’t be so damn buggy!”

    No, no it shouldn’t. Yet it is. The reality is that lots and lots of hardware, including (in all likelyhood) hardware in tha machine you’re sitting at right now, has bugs. Even processors have bugs. http://www.x86.org/errata/dec97/f00fbug.htm They get away with it in part because either the bug doesn’t effect many people or drivers can work around the problem.

  11. James Schend says:

    You do, Anon, but I don’t anymore… after the first 150 or so were burnt exactly correctly, I don’t bother checking. So automatically re-inserting the CD wouldn’t do anything but annoy me.

  12. JT says:

    Ha ho! I guess I’m not such a dummy, after all: when I first noticed that freshly burned CD’s were ejected, I thought "Well, I suppose that’s one way to make sure the drive’s cache is good." And now the famous Raymond Chen sez I was right. Cool. Sort of.

  13. Boris Zakharin says:

    Nero actually does eject and immediately reinsert the disk after burning. Then, when it asks "what would you like to do now?" I exit it, it ejects it again. That is weird.

  14. DavidE says:

    This was even more fun on the last machine I had at work. I called it the "angry dog" because it seemed to close the disk drive when I got close to it. I would open the drive, start to put a CD in, and it would close. Many times, I would have to grab the tray and hold onto it while I properly positioned the CD. Of course, once I did that, it wouldn’t close again without me pushing it all the way in manually. I kind of miss ol’ Cujo…

  15. D. Philippe says:

    Windows itself exhibits this behavior with floppy drives. Once a file has been read once Windows will cachce it, and there are certain cases where its cache is out of sync with the file on the disk.

    When this happens it’s usually an exercise in frustration until a sanity check of looking at the physical file or loading the disk on another PC reveals that Windows had an out-of-date cache.

    IIRC, Windows also pretends to be smart and keeps the cache if the same floppy is reinserted. It takes a floppy swap to clear the cache.

  16. David Wilson says:

    Boris,

    That has never happened for me. Sounds like Nero is internally fixing up your particular drive model or vendor (and doing it in a nasty way).

  17. tsrblke says:

    Regarding the "What would you like to do?" Box. I could be wrong, but for an advanced user wouldn’t putting an autorun.inf file in root of the drive to "Open [Drive letter]" (or other behavior) work? Granted for anyone who isn’t sure how to set up one of these this isn’t even an available option. Maybe that should be a feature put into the Burn wizard. "How would you like this disk to act when inserted?" Have options like "Ask me each time." and "Open the disk" "Open file" ect. And then have the burn wizard make an autorun.inf file. Of course you’d have to put this under a "Advanced" or "More Options tag". And of course someone who does this for a living could make it alot easier to use.

  18. J. Edward Sanchez says:

    [S]ome well-meaning piece of software decided to close the tray on me while I was in the middle of loading or unloading a disc.

    >I would have to grab the tray and hold onto it while I properly positioned the CD.

    People, please stop calling it the "tray". It’s the disc insertification area.

  19. Miles Archer says:

    You mean the cupholder?

  20. xxx says:

    I believe that the "insertification" coment was a refence to this http://blogs.msdn.com/oldnewthing/archive/2003/09/10/54831.aspx

  21. xxx says:

    I believe that the "insertification" coment was a refence to this http://blogs.msdn.com/oldnewthing/archive/2003/09/10/54831.aspx

  22. Jerry Pisk says:

    This (and autoplay options) should not be customizable, the OS should always do one thing and one thing only to make our lives easier. Imagine the hell support departments have to go through because different users have different burning settings, different autoplay choices and they all even use different user names and passwords. How can anyone manage that is beyond me ;)

    On a little serious note – I always thought that all those "Designed for Windows" logos mean that Microsoft asserts that the hardware works with Windows. Apparently it’s just another revenue source to Microsoft without any user benefit since buggy hardware does not seem to have problem obtaining the certs.

  23. Adrian Garside says:

    Sheesh, how dumb. The failure state would seem to be 100% detectable. Why didn’t they write it so that if, at the end of the burn, the drive still claims to be an empty writable CD, then and only then do they eject it. Otherwise they can just leave it in and 99% of the people in the world would be happier (well, ok, those that’s have Windows & an cd burner :)).

  24. oldnewthing says:

    "99% of the world would be happier" – and 1% of the world would be extremely confused. "How come it works for all my friends but not for me? Windows is so unreliable."

  25. TheMuuj says:

    I actually injured myself because of this "feature."

    My computer sits on the floor next to my desk, close to the door.

    I started burning a CD, left the room to get something, and when I came back I walked right into the ejected tray. It cut me pretty deeply just below my knee. I was actually surprised I did not break the tray off. See http://www.muujware.com/matthew/photos/misc/2005-06-10T15-28N00.jpeg (It is starting to heal).

    Before your lawyers start getting worried, I believe I was using Nero to burn the CD, since Nero seems to take less total time to burn a disc. The XP burning software seems to cache a complete image ahead of time. I have a Burn-Proof drive, so burning coasters has never been a big problem.

    If anybody is liable (and they are not, in my opinion), it is the people who made the drive tray so sharp that a klutz like me could cut themselves.

    The worst part is, I just tested my drive for the bug you mentioned, and it does not have it. So I have now turned off the Eject-after-burn feature in Nero. As usual, I favor the ability to customize software, even at the risk of it not working on buggy hardware.

  26. James Day says:

    Gene,

    It isn’t only SATA. One SCSI RAID array vendor removed the turning off of SCSI drive caches from its controllers with battery backed up write caches. When unexpected power loss happened, 3 of 3 database servers with that controller suffered corrupt data because of it.

    You’d think that the message of wanting battery backed write cache so you don’t lose data in a power loss was clear enough…

  27. Adrian Garside says:

    "99% of the world would be happier" – and 1% of the world would be extremely confused. "How come it works for all my friends but not for me? Windows is so unreliable."

    So you’re arguing optimizing for the 1% case is the correct thing to do? You know that’s not how the decisions get made. The current choice has allowed that 1% to grow – not shrink since there is reduced incentive for the hardware vendors to get it right.

  28. Jerry Pisk says:

    Raymond, WMP will sometimes download a coded, sometimes it won’t, sometimes it will fail to download one and only play the streams it can decode (but play all of them on friend’s machine that has the required codecs) and so on. Maybe we should all learn from their documentation.

  29. oldnewthing says:

    So you’re saying that WMP’s behavior is preferred?

  30. oldnewthing says:

    What do you suggest then? That the documentation say "After the CD burning process is complete, most computers will not eject the CD, but some might"? Now people will wonder "Oh great, now not even the *documentation* knows what is going to happen!?"

  31. memet says:

    Interesting.

    I always thought that the ejection was a hack to reload the filesystem (because the fs discovery wouldn’t kick in until the media had changed).

    There is however something that still puzzles me, Raymond. How can Nero ‘verify disc contents after burn’, that is, before the disc is actually ejected?

    Is it that the CDROM caches sectors that have already been accessed? If so, a simple hack could be to read 16 megs of data from the very end of the disc, surely*, no drive would have more than 16 megs of cache.

    * famous last words

  32. msemack says:

    D. Philippe,

    Interesting sotry to go along with that. I have seen floppy drives before that didn’t pay attention when you swapped floppy disks. The system doesn’t realize you have the different floppy disk inserted.

    I’ve seen this since the DOS 5.0 days.

    As an example:

    - I’d put in a floppy, and type ‘dir’.

    - Then I’d switch floppies, and type ‘dir’ again.

    - I’d see the contents of the first floppy.

    - Any attempts to actually access the files would result in havoc.

    It’s caused by a bad floppy cable.

    There is a "disk change" line in the floppy cable. It’s used to notify the controller when a new disk is inserted. If something is wrong with the cable, the host never knows that the disk is inserted.

  33. TheMuuj says:

    I was bit by the bad change line. Luckily, there was a line you could add to the CONFIG.SYS to make MS-DOS ignore the change line and manually check.

    The weird thing is, I was able to fix this back in the day before I had access to a resource like the Internet. Now, when something like that goes wrong, even Google and the Microsoft KB never seem to fully answer my question.

    Then again, there are a lot more things that can go wrong with software/hardware these days. And good driver programmers seem too far between.

  34. Betty says:

    AndrewSeven has an interesting point about the modal popup when no media is inserted, modal dialogs are one of the most evil things invented. They are a major improvement over what earlier versions of windows did (iirc they sat their for 20 secs then poped up saying it couldn’t find a device) but not much better. A much better way would be to copy the Search Results dialog having a small message saying no files found (although this may not be so ideal for damaged media?)

    As for why the ejecting when finished the reason is simple, once the CD has finished burning you need somewhere to put your coffee down so you can pickup the CD, so the obvious solution is for the cupholder to open…

  35. Anon says:

    How about the new "bug" where IDE hard disks don’t write

    >their cache when told to, so they can appear faster on

    >write benchmarks? They’re supposed to write out their cache

    >and not reply "successful" until finished. Instead they

    >just immediately give a "success" reply.

    Don’t even joke about this. Iomega Zip disks had a bug where, if you set the force-media-access flag in the SCSI write command (which forced the data to be committed to the media immediately, no cacheing), the drive would discard the entire write. Made for great write performance in benchmarks, but their utility as a backup medium was somewhat degraded.

  36. ElBiggus says:

    "So you’re saying that WMP’s behavior is preferred?"

    I think he was implying more that WMP is unpredictable, so whatever its documentation says would also suffice for some sort of hand-waving over the "some will eject, others not so much" problem…

    (By extending your "can’t have unpredictability" defence to an absurd conclusion, WMP should *never* download codecs for you — if it’s not going to always work for everyone in every situation, it’s better it never works for anyone! :)

  37. Moi says:

    Hardware shouldn’t be so damn buggy!

    True. But where is the impetus to come from for manufacturers to change it when Windows try to avoid it?

  38. Tony Lezard says:

    memet,

    At least for me, Nero actually ejects and reinserts the CD before verifying a burn. Don’t know what it does with drives that lack an insert mechanism – probably asks you nicely.

  39. Alexey Logachyov says:

    There’s one more story. I use Nero Burning ROM (that’s one sackful of bugs) to burn disks. Not so long ago I purchased a DVD recorder and found a new "bug" when tried to burd a DVD. When I re-insterted DVD that was just burned, Explorer told me that it was empty. Re-inserting again did not help so I went with rebooting.

    Few days later I found the reason. I always listen to some music so WMP is always there. If I close WMP, DVD contents pops up in Explorer.

    So, seems like WMP opens a handle to DVD drive to watch new media arrival, thus referencing file system device object, which in turn references DVD volume device object, which prevents system to either create new VDO, or re-mount file system. Gosh! I never had this problem with my previous CD-RW drive.

  40. Norman Diamond says:

    My experience 2 days ago was weirder. On one machine with a DVD-ROM drive I could read most of the files on a DVD+RW medium but the drive couldn’t read one file. It said CRC error but, although optical media give me a lot of CRC errors, I figured this one was a reflectance issue (RW medium in ROM drive).

    I moved the medium to a different machine with a DVD+RW drive, made a copy of the troublesome file, and moved the medium back to the first machine’s DVD-ROM drive. On the first machine, Windows Explorer insisted on showing the original folder contents, not including the new file. I couldn’t even try to copy the new file to see if it would work, because of the problem that looked exactly like this caching issue. But instead of inserting a different kind of medium, I wanted to try another experiment first.

    I moved the medium back to the second machine, changed the name of the medium, and moved it back. This time Windows Explorer showed the new disc name with the new contents, and copied the new file with no problem.

    Does the firmware in the drive even recognize that some part of the cached data is the disc’s name, and if that matches then the firmware assumes it doesn’t have to flush the rest of the cache?

  41. mreh says:

    My brother’s old computer has this problem… I think my dad’s still using it. It was kind of annoying, since we had to test burnt CDs on the stereo instead of in the computer after they finished.

Comments are closed.