Page 1 of 1

A challenge - disk partitions for virtual boxes to run SQL

Posted: 15. Oct 2013, 02:03
by vininplano
Hi,

I'm trying to set aside a partition, so that databases on my VMs can have more direct access to the disk.

When trying to list partitions, however, to get the magic numbers for setting up a VMDK that accesses just that partition, it fails every time. It's giving me a COM error saying it's unable to communicate with the server / service. It's the same error as the other post on this topic. CO_E_ ...

My question is: Has anyone gotten past this ? Is this just not a feature in the Windows version? Can I get the magic numbers for setting up the VMDK file by using some other tool ?

My environment:

* Windows 8
* I ran the CMD window as an administrator, no luck, same error, a disgraceful failure.
* latest version of VirtualBox (4.18, I think)
* Is there a special command line to start the VBoxSvc ?
* If I kill the VBox service, VirtualBox disgracefully fails.
* If I register the VBoxSvc as a COM server, VirtualBox disgracefully fails.


The command goes something like 'VBoxManage -listpartitions -rawdisk \\.\PhysicalDisk0'

I want the output of this command, the partition numbers, in order to set up a VMDK to get faster access to the disk by bypassing one OS layer.


Since my databases are small, does anyone have any advice on how to set up a VMDK file so that it points to a memory RAM Drive ? The RAM drive has a letter associated with it, but I could remove that. It's driver treats it like another disk volume. I'm using the IMDisk driver. It works great, until I try to use it directly for tempdb in SQL server. Hopefully, the VMDK might find a way around that limitation.



Thanks for any advice !

Re: A challenge - disk partitions for virtual boxes to run S

Posted: 15. Oct 2013, 12:41
by mpack
Raw disk access is very dangerous and will be no faster. Most of the mods here will not help someone trash their host disks, so I would suggest a true network shared folder instead, with VirtIO (i.e. not GA shared folder).

Re: A challenge - disk partitions for virtual boxes to run S

Posted: 15. Oct 2013, 18:50
by scottgus1
RE the ram drive:
I use a ram drive with my work VM to improve autosave times on large files. The host OS has to be stable because, of course, the ram drive will get lost if the host blue-screens.
I set up a 1.09GB ram drive on the host, then put a fixed 1GB .vdi disk file in it through Virtualbox. ("Fixed" because I once had some blue-screens trying to run a dynamic .vdi in the ram drive - switched to fixed and the blue-screens went away.) I then set the ram drive software to save and re-load the disk image at reboots. Finally I attached the .vdi as a secondary disk to my VM. The guest thinks it's writing to a normal platter hard drive, and the speed is tremendously faster in the program that needs to do the autosaves.

Re: A challenge - disk partitions for virtual boxes to run S

Posted: 15. Oct 2013, 22:26
by jorgensen
Speed against security - I find your setup for a database extremely risky.
If you are keen of high speed database access, you can place the database on a vdi located on a SSD drive.