Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have to use some physical disks in a Linux machine virtualized with Virtualbox in a Windows 7 host environment but the order of physical disks keeps changing at every reboot and I must reconfigure the virtual machine to match it. Is there any way I can prevent this?

share|improve this question

migrated from serverfault.com May 30 '12 at 6:27

This question came from our site for system and network administrators.

    
Sorry? If the order of discs for a windows machine (physical or virtual) changes, nothing happens - windows knows which disc is mapped where. Or are you talking of a VirtualBox issue? –  TomTom May 30 '12 at 6:32
    
Windows knows the order of physical disks but to use them on a Virtualbox machine you must create a raw disk with the VB command "C:\Program Files\Oracle\VirtualBox\VBoxManage" internalcommands createrawvmdk -filename PhysicalDrive0.vmdk -rawdisk \\.\PhysicalDrive0 and then assign it to the virtual machine. If Windows changes the order you must change the configuration every time and this is annoying. And most of all, what is the point of changing physical disk order at every reboot? –  Federico Fenara May 30 '12 at 6:43
    
Well, seriously - not using Virtualbox, but I run a lot of VM's with multiple discs attached (underlying both physical as well as as files) and some servers with significant disc subsystems (4-5 physical discs visible) and I have NEVER seen windows shuffling around ANY of the discs. Not physical, not in a VM. Only exception is when a disc is missing during boot (failure to mount in the RAID controller) then obviously the other discs switch. –  TomTom May 30 '12 at 9:13
    
So, your point is that if the order of the physical is changed at boot, nothing happens. But you've never seen it changing (except for hardware failures). I swear that every time I boot Windows, the order of physical disks changes and that forces me to recreate the raw disks to use them in my Virtualbox machines. If you don't believe me, I don't have proof to show, but thank you anyway. –  Federico Fenara May 30 '12 at 11:51

1 Answer 1

up vote 1 down vote accepted

Change VIrtualBox NOT to use ID numbers but the GUID's.

http://scarygliders.net/2011/10/28/virtualbox-on-windows-7-host-with-raw-disk-access-solution-to-randomly-changing-disc-assignment-numbers/

Seems there is no way to stop the ID's from changing, but there is a way not to use the ID's at all ;)

share|improve this answer
    
Seems very interesting. I will try this solution ASAP and report if it works. Thanks! :) –  Federico Fenara May 30 '12 at 12:49
    
Great! It works perfectly! –  Federico Fenara May 30 '12 at 17:34

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.