[Solved] rawdisk partition not detected by guest

Discussions related to using VirtualBox on Windows hosts.
Post Reply
digit23
Posts: 5
Joined: 7. Apr 2015, 16:59

[Solved] rawdisk partition not detected by guest

Post by digit23 »

I have an issue where raw disk partition on guest are not properly detected.

detail:

I have a second HD on my Win 7 host that I want to access from WinXP guest. Second HD only have a single partition NTFS formated with data on it

I did try to mount raw disk and raw partition. With both solution, guest XP sucessfully detect new disk but does not detect NTFS and ask to format partiton.

I did also try to "disable" HD on host with same result.

Why partition is not detected. How to access data on disk from VM ?

Code: Select all

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands createrawvmdk -filename "x:\XP (32 bit)\internal_hd1_wholedisk.vmdk" -rawdisk \\.\PhysicalDrive1
or

Code: Select all

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands createrawvmdk -filename "x:\XP (32 bit)\internal_hd1_part 1.vmdk" -rawdisk \\.\PhysicalDrive1 -partitions 1
scottgus1
Site Moderator
Posts: 20945
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows, Linux

Re: rawdisk partition not detected by guest

Post by scottgus1 »

If all you want to do is get at the data from within the guest, why not put the data in a Windows-style shared folder on the host? Then open the host's shared folder in the guest. Far safer for the data on the disk.

Both the manual (Section 9.8.1) and the forum's green guys always say, Raw disk access is for experts only and can easily destroy data. Impression I get is: If one has to ask about it, one shouldn't be using it... 8) (Not really, of course. Ask away, knowledge is power, learning is good, but not on data you need to keep.)
digit23
Posts: 5
Joined: 7. Apr 2015, 16:59

Re: rawdisk partition not detected by guest

Post by digit23 »

Thanks for the suggestion but the idea is to play around, experiment and do development with tools that access raw data on disk. Both from VM and physically.
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: rawdisk partition not detected by guest

Post by socratis »

What's the drive that you want to have raw access to? And what's the "X:\" drive? Are they the same?
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: rawdisk partition not detected by guest

Post by mpack »

If the guest is offering to format the drive then it doesn't see an existing partition map, which probably means that you have not provided an image of a complete drive.

Are you sure that the second volume in your PC is a separate drive, and not just a secondary partition on the same drive as the C: volume?
digit23
Posts: 5
Joined: 7. Apr 2015, 16:59

Re: rawdisk partition not detected by guest

Post by digit23 »

Note to green guys who deleted his comment, yes I do understand difference between disk and partition...
socratis wrote:What's the drive that you want to have raw access to? And what's the "X:\" drive? Are they the same?
host have two physical disk. First disk two partitions c: and x:, second disk only one partition d:

x: is where my VM are stored.

drive that i'm trying to get access to is d: or second Physical Disk that has only one partition and NTFS formated.

I did create a raw .vmdk that mirror physical disk. That .vmdk is connected as a second disk to my XP VM and properly detected (right size) as d: drive. But unfortunately there is something wrong where partition structure are not properly detected. Guest does not see NTFS partition and ask to format partion.
Last edited by digit23 on 7. Apr 2015, 18:37, edited 1 time in total.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: rawdisk partition not detected by guest

Post by mpack »

A comment was deleted but you still felt that a response was needed?

Btw. It would be nice if you were more explicit about error messages or symptoms. E.g. provide a screenshot of what you see.
digit23
Posts: 5
Joined: 7. Apr 2015, 16:59

Re: rawdisk partition not detected by guest

Post by digit23 »

You must be a member for 1 days and have 1 posts before you can post urls or img. :?

Notice the "Computer Management" capture #4, drive D: filesystem is not detected.

Code: Select all

I did obfuscated to workaround posting rules.  [domain] is org

s17.postimg.[domain]/yvooi1rin/capture_1.png
s2.postimg.[domain]/bxomunex5/capture_2.png
s1.postimg.[domain]/kfqtu1qlr/capture_3.png
s3.postimg.[domain]/6ull8959v/capture_4.png
internal_hd1_wholedisk.vmdk

Code: Select all

# Disk DescriptorFile
version=1
CID=010ee754
parentCID=ffffffff
createType="fullDevice"

# Extent description
RW 976773168 FLAT "\\.\PhysicalDrive1" 0

# The disk Data Base 
#DDB

ddb.virtualHWVersion = "4"
ddb.adapterType="ide"
ddb.geometry.cylinders="16383"
ddb.geometry.heads="16"
ddb.geometry.sectors="63"
ddb.uuid.image="45d2150a-75f5-40cc-ac6b-fbd4330a4697"
ddb.uuid.parent="00000000-0000-0000-0000-000000000000"
ddb.uuid.modification="7323a65b-c25e-4b4e-b663-a5f62b413922"
ddb.uuid.parentmodification="00000000-0000-0000-0000-000000000000"
ddb.geometry.biosCylinders="1024"
ddb.geometry.biosHeads="255"
ddb.geometry.biosSectors="63"
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: rawdisk partition not detected by guest

Post by socratis »

digit23 wrote:You must be a member for 1 days and have 1 posts before you can post urls or img.
True for URLs, but not for images. Check the "Upload attachment" at the bottom of your input.

Now, are you by any chance trying to access the disk from the host and the guest at the same time? Because that's a clear no-no. Read this for the proper way to do it: viewtopic.php?f=6&t=38914#p175089
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
digit23
Posts: 5
Joined: 7. Apr 2015, 16:59

Re: rawdisk partition not detected by guest

Post by digit23 »

I do not have to access disk from guest and host at the same time. To prevent this I did put drive "offline" using windows disk management.

culprit was the "4. ATTRIBUTES DISK CLEAR READONLY", for some reason any of the howto that I read give information about that. :oops:

Now it is working.

Thanks for the link :D
Post Reply