Adding physical disk failed - where I did mistake?

Discussions related to using VirtualBox on Windows hosts.
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

Hi!

I tried to attach to VM physical disk partition, I was following guide and failed.
First I addsharing of two partitions for 5 users with full access.
Then I opened command line as admin and typed commands below - you can see results:

Code: Select all

E:\Desktop>cd C:\Program Files\Oracle\VirtualBox

E:\Desktop>c:

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands listpartitions -rawdisk \\.\PhysicalDrive5
VBoxManage.exe: error: Cannot open the raw disk: VERR_SHARING_VIOLATION

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands createrawvmdk -filename L:\APPS-NTFS.vmdk -rawdisk \\.\PhysicalDrive5 -partitions 1
VBoxManage.exe: error: Cannot open the raw disk '\\.\PhysicalDrive5': VERR_SHARING_VIOLATION
VBoxManage.exe: error: The raw disk vmdk file was not created

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands createrawvmdk -filename L:\DOS-FAT.vmdk -rawdisk \\.\PhysicalDrive5 -partitions 2
VBoxManage.exe: error: Cannot open the raw disk '\\.\PhysicalDrive5': VERR_SHARING_VIOLATION
VBoxManage.exe: error: The raw disk vmdk file was not created

C:\Program Files\Oracle\VirtualBox>
Where do I mistake?

Thank you all for help.
Miro
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Adding physical disk failed - where I did mistake?

Post by socratis »

1) You could ask whoever wrote the guide you're following.
2) You need the disk to be ejected from the host, not being mounted.
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.
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

what here means ejected? I mean it is not same as disconnected...

Miro
Martin
Volunteer
Posts: 2561
Joined: 30. May 2007, 18:05
Primary OS: Fedora other
VBox Version: PUEL
Guest OSses: XP, Win7, Win10, Linux, OS/2

Re: Adding physical disk failed - where I did mistake?

Post by Martin »

Windows needs to unmount the disk partition so that nothing else from the OS is accessing/locking it.
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Adding physical disk failed - where I did mistake?

Post by socratis »

BTW, it's not just Windows, OSX needs the drive to be ejected/unmounted/whatever too, and I suspect so does Linux and Solaris.
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.
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

Ok, really I'm not beginner in Windows but with this I meet never before...

So, I'm asking like beginner - how to do it?

Is enough to remove partition letter?

Miro
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

I tried to remove drive letters, but helped not - same errors.

Can anybody help me?

Miro
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Adding physical disk failed - where I did mistake?

Post by socratis »

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.
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

Ok, this I didn't knew really and my UEFI has feature which allows to work with drives like removable media... Quick Remove
But last Q is - it must to be unmounted always?
If only while running VirtualBox it's ok, but if always it is useless..

Miro
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Adding physical disk failed - where I did mistake?

Post by socratis »

The raw disk option requires the drive to be unmounted, as long as it is being used as a raw disk. You can of course mount it afterwards.
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.
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

Yesterday evening I tried to unmount partition and tried also whole disk, but unmount button is gray and it means not usable.
When I triedunmount whole disk from taskbar icon, it reports error "Disk is in use, close programs..."

Today I tried to do the same after logoff and then logon - not success.

But really on disk or partitions which I want to unmount are no files - no data, so don't understand...

Miro
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

No idea?

Miro
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Adding physical disk failed - where I did mistake?

Post by socratis »

This is not actually a VirtualBox question, per se. Treat it as such, and search the internet accordingly...
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.
MIRKOSOFT
Posts: 76
Joined: 25. Dec 2015, 02:23

Re: Adding physical disk failed - where I did mistake?

Post by MIRKOSOFT »

So, I have to go to other forum for asking part of Q?

In posts above was recommened how to unmount disk for creating virtual disk from physical...
Sadly it looks like here is not so big support, sadly.

Miro
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Adding physical disk failed - where I did mistake?

Post by socratis »

All I said is to search the internet for your problem. Is that a hard thing to ask? Plus if I'm not mistaken, you do not have a support contract, right? So "demanding" support, is something that you're not entitled to. ;)
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.
Post Reply