FreeBSD 9 and Windows XP

Warren Block wblock at
Tue Mar 12 01:17:21 UTC 2013

On Mon, 11 Mar 2013, Carl Johnson wrote:

> Warren Block <wblock at> writes:
>> On Mon, 11 Mar 2013, Carl Johnson wrote:
>>> It is my understanding that FreeBSD doesn't allow using part of a disk,
>>> but grabs the entire disk.  That means that VirtualBox can't use
>>> partitions on a disk that any other partitions are being used by
>>> anything else, including FreeBSD itself.  Am I wrong about this?  I use
>>> VirtualBox using vdmk for an entire disk, but I have never been able to
>>> share with anything else.
>> It's very hard to tell what situation is being described here.  If the
>> VMDK is a pointer to a whole physical disk, that would probably make
>> the disk only usable by one VM.  It should be possible to make the
>> VMDK point to just one partition on the disk.  Then other VMs or a
>> physical machine could use those other partitions while the FreeBSD VM
>> was running.
> I was thinking of the case where I tried to allow direct access by a
> virtual machine to a slice on the same disk that I was running FreeBSD
> off of.  I just looked further into that and discovered that it is
> possible, but not allowed by geom by default.  It can be done by setting
> 'sysctl kern.geom.debugflags=0x10'.  I am sure that you are aware of the
> dangers, but for anybody else reading this check out the warning in the
> geom(4) manpage.  They refer to this option as 'allow foot shooting' for
> a reason.

That's kind of what I was saying.  If you can get the VMDK to refer to 
just the one slice/partition that the VM needs, it won't lock the whole 
disk.  For example, ada0s2a rather than ada0s2.  Of course, it would be 
bad to share the same partition between more than one VM or physical 
machine at the same time unless it is mounted read-only by all of them.

More information about the freebsd-questions mailing list