[nSLUG] Virtualbox problem (was Re: Debian vserver kernel)

Jack Warkentin jwark at eastlink.ca
Fri Nov 7 16:02:23 AST 2008


Hi everybody

I switched almost completely to GNU/Linux from Windows 98 five or so 
years ago. My only remaining need for Windows is for doing my income 
tax. (I refuse to use a web-based application where the data is stored 
on somebody else's machine.)

I have been using a virtualization product called Win4Lin home with 
Windows 98, which uses a patched kernel and is no longer supported. I 
have an unactivated copy of Win XP SP2 which I would like to set up in a 
virtual machine. After reading about KVM, Xen, Qemu and Virtualbox I 
decided to try out Virtualbox.

But first, as an experiment, and to gain some experience, I decided to 
set up a 32-bit Debian testing system in a Virtualbox vm on my 
AMD64-based laptop, where I ran into some difficulties.

Setting up the vm from the GUI interface and installing 32-bit Debian 
testing went smoothly. I also succeeded (eventually, had to find an 
appropriate kernel and compile environment) in installing the Guest 
Additions and managed to enable sharing of my full file system by including

<SharedFolder name="FullHost" hostPath="/" writable="false"/>

in the vm's definition file, and

FullHost  /FullHost  vboxsf  noauto,users,ro,uid=1004,gid=1004  0   0

in its /etc/fstab file.

The root of my problem is that /sbin/mount.vboxsf (the 
Virtualbox-provided binary that gets invoked by the mount command) will 
not allow ordinary users to mount FullHost, no matter what options (most 
of which are not allowed) I try putting into the fstab file.

Removing the "users," from fstab allows root to perform the mount 
successfully from the command line.

But I didn't want to have to su to root in order to perform this mount 
every time. So I removed the "noauto," from fstab and tried again. Here 
is the result from the /var/log/boot file (with the date/timestamps and 
several irrelevant lines removed):

Mounting local filesystems.../sbin/mount.vboxsf: mounting failed with 
the error: No such device
^[[31mfailed.^[[39;49m
Activating swapfile swap...done.
INIT: Entering runlevel: 2
Starting VirtualBox Additions ...done.
Starting VirtualBox host to guest time synchronisation  ...done.
Starting VirtualBox Additions shared folder support/sbin/mount.vboxsf: 
mounting failed with the error: Protocol error

The first failure is understandable - the virtualbox daemons had not yet 
been started. But the second is not understandable. In the first place, 
why would there be a second attempt at the mount? In the second place, 
why would it fail, when root is able to perform the mount successfully 
from the command Line?

So I finally tried putting the mount command into /etc/rc.local as follows.

. /lib/lsb/init-functions
log_action_msg "In rc.local, about to execute \"mount -a\""
mount -a
log_action_msg "$? returned from \"mount -a\" in rc.local"

(The first line is to make the log_action_msg function available.)

The results were disappointing. Again from /var/log/boot

In rc.local, about to execute "mount -a".
/sbin/mount.vboxsf: mounting failed with the error: Protocol error

Note that not only did the mount fail, but that the mount command never 
returned to the rc.local script for execution of the last log message 
command.

I suppose I should address the first problem (mount failure) to the 
virtualbox team and the second (return failure) to the Debian people, 
but since Eugene seems to have had a lot of experience with virtualbox I 
thought maybe he might be able to shed some light on this.

Any help, from anybody, would be much appreciated.

Jack

Eugene Cormier wrote:
> On Fri, 2008-11-07 at 09:11 -0400, D G Teed wrote:
>> I see a lot of the chatter around vserver is from 2005ish, and not
>> much
>> recent.  Is there something more commonly used now?  Xen?
>> Virtualbox?  OpenVZ?  VMware?  Or should I look at compiling
>> my own kernel for vserver?
> 
> Donald, depending on what you're doing (and I assume you're probably
> doing some kind of linux server as opposed to running windows) then I
> would say the way to go is to use Xen or KVM ......personally though I
> like to toy with different OS' so I started using Virtualbox (which I
> love) and I've recently setup a http server on it....it's been rock
> solid (no crashes or other problems) for about 2 years now
> 
> Eugene 

-- 
Jack Warkentin, phone 902-404-0457, email jwark at eastlink.ca
39 Inverness Avenue, Halifax, Nova Scotia, Canada, B3P 1X6



More information about the nSLUG mailing list