\Device\HarddiskX (entire disk) is not...

2011-02-24
2013-04-24
  • Matt Van Mater

    Matt Van Mater - 2011-02-24

    I am testing ODIN with a few scenarios to ensure ODIN can restore a "master" USB flash drive image to a new USB flash drive no matter what.

    Unfortunately I have run into a situation where the "\Device\HarddiskX (entire disk)" is not always listed in the GUI or the CLI.  Since it is not listed, I cannot restore a backup made from the same disk that used the (entire disk) volume entry.  My guess it is an assumption somewhere in ODIN code looking for a master boot record, and since it can't find one, ODIN does not list the entire disk entry.

    Here is how you can reproduce the problem:
    1) Take a working fat32 formatted USB flash drive and make it bootable, write some data on it, etc. 
    2) Use ODIN to create a backup of that USB flash drive, selecting the \Device\HarddiskX (entire disk) entry
    3) Boot into a Linux OS or LiveCD like partedmagic and erase the first part of that USB flash drive (e.g. dd if=/dev/urandom of=/dev/sdb bs=1M count=100).  Reformatting the drive is not an equivalent test, you must wipe out the MBR and partiton table.
    4) Boot back into a Windows OS and open ODIN.  The \Device\HarddiskX (entire disk) entry representing the USB flash drive will not be listed, but \Device\HarddiskX Partition1 might be (if you formatted the drive).
    5) You can format the USB flash drive via the windows explorer GUI, via the Computer Management->Storage->Disk Management snapin… it doesn't matter: you still cannot see the base volume in ODIN.
    6) The only way to get it working is to use Windows' diskpart utility, but IMO that somewhat defeats the purpose of using an imaging tool!  (i.e.  commands to execute are: open command prompt as administrator, diskpart, list disk, select diskX, clean, create partition primary, active, format fs=fat32 quick, assign, exit)
    7) The \Device\HarddiskX (entire disk) entry will now be shown in the Disk-Volume list, and you can then use ODIN to restore the mbr and image file and all will be well.

    I would prefer to not have to use the windows diskpart commands as a workaround to force ODIN to recognize the drive.  I'm not sure if this is an issue with Windows 7 being uncooperative, or is there is some missing logic in ODIN, etc. 

    Any ideas on how to make ODIN get around this limitation?

     
  • JensH

    JensH - 2011-02-25

    Wow that's a very detailed error report. Thank You. I will take a look into that (unfortunately my time working on this currently is very limited). A few more questions:
    Did you try the latest version (I recently uploaded  a version with some fixes). According to your error report I do not expect any differences however.
    And will your stick without MBR appear in the Windows disk management console? I think it should be there.

    What happens is that ODIN gets a list of Windows devices and filters those it can use. I assume that there is something in the filter logic that filters out your device in this case. …. Oh yes a logging mechanism for ODIN would really help here…
    I will take a look into that.

     
  • JensH

    JensH - 2011-03-03

    I think I know what's going on here. Removable devices without a partition table are not treated as a disk device but like floppy. There is no Partition0 device in this case, all blocks of such a device are seen a as partition1. Probably it would help for this case to restore an entire disk image to a single partition. Currently ODIN prevents this and raises an error, I will check if this works and if the device is seen as a disk then after a restore.

     
  • Matt Van Mater

    Matt Van Mater - 2011-04-28

    Darn Sourceforge… I was never notified that you responded!  I was using version 0.3.3.297 in the testing above.

    One other key bit of info that you should be aware of is that I am trying to get your imaging software working on a 32bit version of Windows XP.  This is important because WinXP does not include the diskpart utility that is capable of marking a USB drive as bootable.

    Any chance you can provide a patch that provides the capability you describe in your last post?

     
  • Anonymous - 2011-04-28

    RMPrepUSB can make image backups and restore under Windows (if it is of any help).

     
  • Matt Van Mater

    Matt Van Mater - 2011-04-28

    Quick Note: I just discovered that I can use the HP Drive Key Boot Utility (here: http://h20000.www2.hp.com/bizsupport/TechSupport/SoftwareDescription.jsp?swItem=MTX-UNITY-I23839) to format a blank USB drive and then use the ODIN process outlined above to restore the image to "\Device\HarddiskX (entire disk)" .

    I would prefer to avoid added step of using the HP utility since ODIN does a better job at pretty much everything else.  (i.e. the HP utility backup/restore is SLOW)

     
  • Matt Van Mater

    Matt Van Mater - 2011-04-28

    Thanks for the suggestion s6375.

    However, I have found that RMPrepUSB can basically accomplish the same result as the HP utility (in my case, to install a syslinux bootloader).  However, their imaging capability is equally abysmal.   Also IMO, the RMPrepUSB tool's interface is terrible… Looks like an overly complicated MS Visual Basic interface from 10+ years ago.

    In my opinion the main benefits of ODIN are:
    1) Ability to copy used blocks only
    2) Simple interface that a junior technician can follow easily.

    After all, how often do you have a drive that is 100% full?  Capturing an entire drive contents via a byte level copy is a brute force method and should be save as a last resort only.

     
  • Matt Van Mater

    Matt Van Mater - 2011-06-01

    Any update on this issue?

     
  • Matt Van Mater

    Matt Van Mater - 2011-08-09

    Checking in… kaltduscher65, have you had a chance to look at this issue?

     
  • JensH

    JensH - 2011-10-04

    I have created a fix but not yet released a new version. Is anyone interested in testing the fix? I would appreciate a test outside of my environment before releasing it. Please send a short reply. I will send a link where to download then.

     
  • Matt Van Mater

    Matt Van Mater - 2011-10-04

    Hi, i apologize for the delay.  I plan on testing your latest revision tomorrow and will provide feedback about 24 hours form now.

     
  • Anonymous - 2012-03-06

    just passing through and wow, i have to say that reading your msgs (over 8 months!) is a perfect example of how awesome sourceforge is :D
    too bad i didn't get to see whether it worked on nuttervm's problem :(
    probably did!

     
  • Justin Goldberg

    Justin Goldberg - 2012-03-12

    I copy a compact flash's OS & storage card from an embedded system (an AllWorx PBX) and imaged it to another drive using Odin, and it worked fine, FWIW.

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks