Ramdisk & partition deletion problems


J

Jordi

Hello!

We have a working embedded device with a hard disk w/ XPe which can boot
also in PXE.

I've been ordered to make a kind of "rescue disk" for those embedded devices
which need an OS upgrade or the hard disk just "dies" in the middle of the
road/city, without needing to bring the device back home (as it can be very
expensive in time and $)

The idea is booting via PXE, loading a XPe into the ramdisk and execute a
hard disk rescue custom program which should repartition and reformat the
hard disk.
The problem is that there's no way to format/remove the first partition of
the hard disk.
The system seems to lock it as if it were the system partition. Using
sysinternal's process explorer shows process ID 4 "SYSTEM" using/blocking the
HardDisk0 (there's no swap, no open files, nothing) when that blocked
partition should be the RamDisk.
The partition can be removed without problems using the same XPe put in a
compact flash.

I've noticed that starting the system shows a "new hardware detected" and
"you can use RamDisk now", and I think this could be the root of the problem:
XP trying to lock the system partition, but as ramdisk doesn't exist it
thinks it's the HD first partition, and afterwards it requires a reboot in
order to unlock the HD... then I could delete that partition. Of course, once
it reboots, as it's a ramdisk, everything goes back to the starting point.

Any ideas?

TIA
Jordi
 
Ad

Advertisements

H

Henry Markov

I got lost in your explanation at the end when you say "but as ramdisk
doesn't exist it thinks it's the HD first partition." This makes me wonder
about the scenario you are using to make your boot device choice. Seems to
me that in BIOS you should select PXE/network boot as first priority and HD
as second priority. If a boot server is on the network your device will
boot from it and if not (or if you select abort.com as the downloaded file)
it will boot from the HD. In the first case the ramdisk is created well
before your device boots and it will appear as C: at boot time so I don't
see why you think there is confusion about which disk is the system disk.

HM
 
J

Jordi

Hi Henry,

thanks for your response, I'll try to explain it better.

The system is configured so that it boots from PXE first, and HD second. The
system boots in PXE (100% sure) when I get the problem.

Once the PXE loaded XPe is running I have the ramdisk at c: and the
"problematic HD partition" in d:. The problem appears when I try to delete
the HD partition using disk management MMC (the idea would be using diskpart,
but I have the same problem with it)

http://img4.imageshack.us/my.php?image=err2ib9.png

As you can see, ramdisk is @ C: and I can't format/delete partition d:

(another question would be why isn't ramdisk appearing in the disk management)


As the usual reason for a volume not being able to be formatted/deleted is
having open handles to it, I used sysinternals' process explorer I have the
following information:

http://img26.imageshack.us/my.php?image=err4jz5.png

as you can see, System #4 is using HardDisk0. Searching for open handles to
d: shows nothing, it seems it's the only process with access to the harddisk.


And as a final screenshot tour :) I get this message when I start windows XP
embedded:

http://img11.imageshack.us/my.php?image=14600733uy8.png


I wanted to rewrite the problem because I think I explained it very poorly
(my english skills are not very good).

About the "but as ramdisk doesn't exist it thinks it's the HD first
partition." it's just a conjecture:
I think that the "found hardware: ramdisk" message is the root of my
problem. I think that windows "locks" the D partition because it's not able
to lock ramdisk at the system#4 start, because it hasn't even been detected,
so it goes for the D partition as a safe bet (which prevents me from
formatting the partition)

But as I said it's just a conjecture, I have no real idea why I can't format
the whole hard disk.

Thanks,
Jordi
 
K

KedarB [MSFT]

What version of XPe is this, SP2/FP2007/FP2008/R2? Is FBWF also included in
the XPe image?
 
J

Jordi

Hi!

Sorry for the delay, I just found the problem. Deleting the registry key
"HKEY_LOCAL_MACHINE\SYSTEM\Setup\SystemPartition" fixed my issues.

It seems that as I was booting from the HD before making the ramdisk image,
the ramdisk always thought the HardDisk1 was the system partition, locking
every hard disk it found there. I can delete & format every HD partition now.

I had another problem with the ramdisk being 'hidden' behind real hard disk
volumes. Deleting all entries in "HKEY_LOCAL_MACHINE\SYSTEM\MountedDevices"
did the job too.


Now the problem is that the ramdisk recognizes only the HD drivers that I've
previously booted from (in the hard disk image of the ramdisk before making
the ramdisk image)

i.e. I create the ramdisk image using a toshiba mk1646gsx as primary master.
The ramdisk works fine as long as the embedded system has a mk1646gsx primary
master. However if I put the mk1646gsx as primary slave or use an almost
identical mk1652gsx, the ramdisk (executed from ramdisk) says "new hardware"
then "you need to restart to use the new hardware". The "unknown" hard disk
appears in the hardware devices with a yellow exclamation mark and is
unusable.

I get the following section in setupapi.log (it's a fujistu model)

[2009/02/27 10:26:49 804.3 Driver Install]
#-019 Searching for hardware ID(s):
ide\diskfujitsu_mhw2080bh_______________________00000012,ide\fujitsu_mhw2080bh_______________________00000012,ide\diskfujitsu_mhw2080bh_______________________,fujitsu_mhw2080bh_______________________00000012,gendisk
#-018 Searching for compatible ID(s): gendisk
#-198 Command line processed: C:\windows\system32\services.exe
#I022 Found "GenDisk" in C:\windows\inf\disk.inf; Device: "Disk drive";
Driver: "Disk drive"; Provider: "Microsoft"; Mfg: "(Standard disk drives)";
Section name: "disk_install".
#I023 Actual install section: [disk_install.NT]. Rank: 0x00000004. Effective
driver date: 07/01/2001.
#I393 Modified INF cache "C:\windows\inf\INFCACHE.1".
#-166 Device install function: DIF_SELECTBESTCOMPATDRV.
#I063 Selected driver installs from section [disk_install] in
"c:\windows\inf\disk.inf".
#I320 Class GUID of device remains: {4D36E967-E325-11CE-BFC1-08002BE10318}.
#I060 Set selected driver.
#I058 Selected best compatible driver.
#-166 Device install function: DIF_INSTALLDEVICEFILES.
#I124 Doing copy-only install of
"IDE\DISKFUJITSU_MHW2080BH_______________________00000012\VT0581&A00&H01&DFF&".
#-166 Device install function: DIF_REGISTER_COINSTALLERS.
#I056 Coinstallers registered.
#-166 Device install function: DIF_INSTALLINTERFACES.
#-011 Installing section [disk_install.NT.Interfaces] from
"c:\windows\inf\disk.inf".
#I054 Interfaces installed.
#-166 Device install function: DIF_INSTALLDEVICE.
#I123 Doing full install of
"IDE\DISKFUJITSU_MHW2080BH_______________________00000012\VT0581&A00&H01&DFF&".
#I163 Device not started: Device has problem: 0x27:
CM_PROB_DRIVER_FAILED_LOAD.
#I121 Device install of
"IDE\DISKFUJITSU_MHW2080BH_______________________00000012\VT0581&A00&H01&DFF&" finished successfully.
[2009/02/27 10:26:57 804.8 Driver Install]
#-019 Searching for hardware ID(s): ramdisk\ramvolume
#-198 Command line processed: C:\windows\system32\services.exe
#-166 Device install function: DIF_SELECTBESTCOMPATDRV.
#W059 Selecting best compatible driver failed. Error 0xe0000228: There are
no compatible drivers for this device.
#W157 Default installer failed. Error 0xe0000228: There are no compatible
drivers for this device.
[2009/02/27 10:26:57 732.2]
#-199 Executing "C:\windows\system32\rundll32.exe" with command line:
rundll32.exe newdev.dll,ClientSideInstall
\\.\pipe\PNP_Device_Install_Pipe_0.{2101A74D-2CC3-4D6B-AF30-1DE9CED386D9}
#I060 Set selected driver.
#-019 Searching for hardware ID(s): ramdisk\ramvolume
#-166 Device install function: DIF_SELECTBESTCOMPATDRV.
#W059 Selecting best compatible driver failed. Error 0xe0000228: There are
no compatible drivers for this device.
#W157 Default installer failed. Error 0xe0000228: There are no compatible
drivers for this device.
#I060 Set selected driver.
#-166 Device install function: DIF_INSTALLDEVICE.
#I125 Installing NULL driver for
"RAMDISK\RAMVOLUME\{D9B257FC-684E-4DCB-AB79-03CFA2F6B750}".
#W100 Query-removal during install of
"RAMDISK\RAMVOLUME\{D9B257FC-684E-4DCB-AB79-03CFA2F6B750}" was vetoed by
"Ramdisk\RamVolume\{d9b257fc-684e-4dcb-ab79-03cfa2f6b750}" (veto type 6:
PNP_VetoDevice).
#W104 Device "RAMDISK\RAMVOLUME\{D9B257FC-684E-4DCB-AB79-03CFA2F6B750}"
required reboot: Query remove failed (install) CfgMgr32 returned: 0x17:
CR_REMOVE_VETOED.
#I121 Device install of
"RAMDISK\RAMVOLUME\{D9B257FC-684E-4DCB-AB79-03CFA2F6B750}" finished
successfully.



The weird thing is that the very same ramdisk, copied to a disk instead of
booted via PXE, detects the fujitsu disk correctly and can be
accessed/copied/formatted with no reboot needed.

[2009/02/27 10:06:03 832.3 Driver Install]
#-019 Searching for hardware ID(s):
ide\diskfujitsu_mhw2080bh_______________________00000012,ide\fujitsu_mhw2080bh_______________________00000012,ide\diskfujitsu_mhw2080bh_______________________,fujitsu_mhw2080bh_______________________00000012,gendisk
#-018 Searching for compatible ID(s): gendisk
#-198 Command line processed: C:\WINDOWS\system32\services.exe
#I022 Found "GenDisk" in C:\WINDOWS\inf\disk.inf; Device: "Disk drive";
Driver: "Disk drive"; Provider: "Microsoft"; Mfg: "(Standard disk drives)";
Section name: "disk_install".
#I023 Actual install section: [disk_install.NT]. Rank: 0x00000004. Effective
driver date: 07/01/2001.
#-166 Device install function: DIF_SELECTBESTCOMPATDRV.
#I063 Selected driver installs from section [disk_install] in
"c:\windows\inf\disk.inf".
#I320 Class GUID of device remains: {4D36E967-E325-11CE-BFC1-08002BE10318}.
#I060 Set selected driver.
#I058 Selected best compatible driver.
#-166 Device install function: DIF_INSTALLDEVICEFILES.
#I124 Doing copy-only install of
"IDE\DISKFUJITSU_MHW2080BH_______________________00000012\VT0581&A00&H01&DFF&".
#-166 Device install function: DIF_REGISTER_COINSTALLERS.
#I056 Coinstallers registered.
#-166 Device install function: DIF_INSTALLINTERFACES.
#-011 Installing section [disk_install.NT.Interfaces] from
"c:\windows\inf\disk.inf".
#I054 Interfaces installed.
#-166 Device install function: DIF_INSTALLDEVICE.
#I123 Doing full install of
"IDE\DISKFUJITSU_MHW2080BH_______________________00000012\VT0581&A00&H01&DFF&".
#I121 Device install of
"IDE\DISKFUJITSU_MHW2080BH_______________________00000012\VT0581&A00&H01&DFF&" finished successfully.


The only difference I can see is that the ramdisk boot says
#I393 Modified INF cache "C:\windows\inf\INFCACHE.1".
and HD-booted doesn't, but I don't know if this is significant or not.

TIA,
Jordi
 
C

chen_lin99

Press Release

On March 4, 2009, Moio Systems releases Power RAMDisk version 2.81.

Features include:
Converts a portion of RAM as a disk drive you can use normally.
RAM Disk size unlimited.
RAM Disk size, driver letter can be changed on-the-fly.
Choice of RAM Disk file system: NTFS, FAT32, FAT.
Save/load RAM Disk image.
No need of computer restart after software installation.
Convenient user interface.

Power RAMDisk v2.81 can be purchased for only $7.95, at
https://www.regnow.com/softsell/nph-softsell.cgi?item=15697-3
(all major credit cards accepted)
 
Ad

Advertisements

I

info

Press Release

On March 4, 2009, Moio Systems releases Power RAMDisk version 2.81.

Features include:
Converts a portion of RAM as a disk drive you can use normally.
RAM Disk size unlimited.
RAM Disk size, driver letter can be changed on-the-fly.
Choice of RAM Disk file system: NTFS, FAT32, FAT.
Save/load RAM Disk image.
No need of computer restart after software installation.
Convenient user interface.

Power RAMDisk v2.81 can be purchased for only $7.95, at
https://www.regnow.com/softsell/nph-softsell.cgi?item=15697-3
(all major credit cards accepted)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top