ports/144305: without default route, virtualbox can't find host-only interface

Wietse Venema wietse at porcupine.org
Fri Feb 26 00:00:15 UTC 2010


>Number:         144305
>Category:       ports
>Synopsis:       without default route, virtualbox can't find host-only interface
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Feb 26 00:00:14 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Wietse Venema
>Release:        FreeBSD 8.0-RC1 i386
>Organization:
>Environment:
System: FreeBSD tail.porcupine.org 8.0-RC1 FreeBSD 8.0-RC1 #0: Sun Dec 6 12:26:36 EST 2009 wietse at tail.porcupine.org:/usr/src/sys/i386/compile/D10 i386

FreeBSD 8.0-RC1 i386 
Quad-core and dual-core CPUs
Ports last update Jan 24 2010
virtualbox-ose-3.1.2
virtualbox-ose-additions-3.1.51.r25618
virtualbox-ose-kmod-3.1.2
>Description:
VirtualBox guests that use the vboxnet0 host-only network fail to
start when the underlying host has no default route.
>How-To-Repeat:
Take a machine that has no network connectivity, like my road warrior
laptop. Or take a networked machine and remove its default route(s).

    # route delete default
    # netstat -nr | grep default

I can reproduce the problem below on machines with ip forwarding
on or off; with IPv6 off; and with the VirtualBox DHCPServer enabled
or disabled. On both machines and I have single-cpu guest configurations
for Linux and Windows that use vboxnet0 host-only networking.

Starting any of these guest machines results in an error pop-up
window. 

Note the "NetworkAttachmentType_HostOnly: FindByName failed" error
record in the logfile below. It suggests that VirtualBox was unable
to find the vboxnet0 host-only interface.

Also, in the network settings dialog for the guest, the name
"vboxnet0" is changed into "Not selected". This is consistent
with the "interface not found" error.

Logfile:

00:00:00.510 VirtualBox 3.1.2_OSE r56127 freebsd.x86 (Feb  6 2010 17:17:00) release log
00:00:00.510 Log opened 2010-02-25T22:03:15.370623000Z
00:00:00.510 OS Product: FreeBSD
00:00:00.510 OS Release: 8.0-RC1
00:00:00.510 OS Version: FreeBSD 8.0-RC1 #0: Sun Dec  6 12:26:36 EST 2009     wietse at tail.porcupine.org:/usr/src/sys/i386/compile/D10
00:00:00.510 Host RAM: 3054MB RAM, available: 2633MB
00:00:00.510 Executable: /usr/local/lib/virtualbox/VirtualBox
00:00:00.510 Process ID: 2427
00:00:00.510 Package type: BSD_32BITS_GENERIC (OSE)
00:00:00.516 Your keyboard type does not appear to be known to VirtualBox. If
00:00:00.516 you would like to help us improve the product, please submit a bug
00:00:00.516 report, attach this logfile and provide information about what type
00:00:00.516 of keyboard you have and whether you are using a remote X server or
00:00:00.516 something similar.
00:00:00.516 
00:00:00.516 The tables for your keyboard are:
00:00:00.516 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 
00:00:00.516 0x8, 0x9, 0xa, 0xb, 0xc, 0xd, 0xe, 0xf, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 
00:00:00.516 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 
00:00:00.516 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 
00:00:00.516 0x38, 0x39, 0x11d, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, 0x145, 0x46, 0x47, 
00:00:00.517 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, 0x0, 0x138, 0x56, 0x57, 
00:00:00.517 0x58, 0x147, 0x148, 0x149, 0x14b, 0x0, 0x14d, 0x14f, 0x150, 0x151, 0x152, 0x153, 0x11c, 0x11d, 0x45, 0x137, 
00:00:00.517 0x135, 0x138, 0x0, 0x15b, 0x15c, 0x15d, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x138, 0x0, 0x0, 0x0, 
00:00:00.517 0x0, 0x16d, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 
00:00:00.517 0x110, 0x0, 0x0, 0x0, 0x0, 0x0, 0x15f, 0x0, 0x0, 0x119, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 
00:00:00.517 0x120, 0x0, 0x122, 0x0, 0x124, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x12e, 0x0, 
00:00:00.517 0x130, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 
00:00:00.517 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 
00:00:00.517 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x15e, 0x0, 
00:00:00.517 0x0, 0x0, 0x0, 0x163, 0x0, 0x165, 0x166, 0x167, 0x168, 0x169, 0x16a, 0x16b, 0x16c, 0x16d, 0x0, 0x0, 
00:00:00.517 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0
00:00:00.517 and
00:00:00.517 NULL, 0x25, 0x32, 0x0, 0x17, 0x9, 0x24, 0x62, 0x68,
00:00:00.517 0x64, 0x66, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, 0x49, 0x4a
00:00:00.520 SUP: Loaded VMMR0.r0 (/usr/local/lib/virtualbox/VMMR0.r0) at 0xc8541060 - ModuleInit at 00000000c85553d0 and ModuleTerm at 00000000c8555390
00:00:00.520 SUP: VMMR0EntryEx located at 00000000c8555260, VMMR0EntryFast at 00000000c8555450 and VMMR0EntryInt at 00000000c85544c0
00:00:00.546 NetworkAttachmentType_HostOnly: COMGETTER(HostInterface): vboxnet0
00:00:00.546 NetworkAttachmentType_HostOnly: FindByName failed, rc (0x80004005)
00:00:00.546 VMSetError: /usr/ports/emulators/virtualbox-ose/work/VirtualBox-3.1.2_OSE/src/VBox/Main/ConsoleImpl2.cpp(2684) static int Console::configNetwork(Console*, const char*, unsigned int, unsigned int, INetworkAdapter*, CFGMNODE*, CFGMNODE*, CFGMNODE*, bool)
00:00:00.546 VMSetError: Inexistent host networking interface, name 'vboxnet0'
00:00:00.548 VMSetError: /usr/ports/emulators/virtualbox-ose/work/VirtualBox-3.1.2_OSE/src/VBox/VMM/VM.cpp(323) int VMR3Create(uint32_t, void (*)(VM*, void*, int, const char*, unsigned int, const char*, const char*, char*), void*, int (*)(VM*, void*), void*, VM**)
00:00:00.548 VMSetError: Unknown error creating VM
00:00:00.548 ERROR [COM]: aRC=NS_ERROR_FAILURE (0x80004005) aIID={6375231a-c17c-464b-92cb-ae9e128d71c3} aComponent={Console} aText={Inexistent host networking interface, name 'vboxnet0' (VERR_INTERNAL_ERROR).
00:00:00.548 Unknown error creating VM (VERR_INTERNAL_ERROR)} aWarning=false, preserve=false
00:00:00.551 Power up failed (vrc=VERR_INTERNAL_ERROR, rc=NS_ERROR_FAILURE (0X80004005))

>Fix:
To work around this bug, set a bogus default route:
# route add default 127.0.0.1

With this, there is no error pop-up, and the guests starts normally.
Also, the name "vboxnet0" appears again in the network settings
dialog for the guest.

Of course the default route disappears after my laptop has had
connectivity at a hotspot or via (ugh) dialup. Having to set back
the bogus route is an annoyance.
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list