Hello,
I am trying get Virtualbox using rump_fs in a qemu environment.
I am using a modified virtualbox.run script called vb_ide.run. Eventually Virtualbox is started as follows:
qemu-system-x86_64 -no-kvm -cpu core2duo -m 512 -boot order=d, -hda /GV/QV.img -serial mon:stdio -cdrom var/run/vb-ide.iso
Device -hda contains an ext2 filesystem upon which an original VirtualBox VMs directory environment is installed.
The following is part of the init script that is used.
<start name="atapi_drv"> <resource name="RAM" quantum="5M"/> <provides><service name="Block"/></provides> <config ata="yes"/> </start>
<start name="rump_fs" priority="-1"> <resource name="RAM" quantum="32M" /> <provides><service name="File_system"/></provides> <config fs="ext2fs"><policy label="" root="/" writeable="yes"/></config> </start>
<start name="virtualbox" priority="-2"> <resource name="RAM" quantum="750M"/> <config vbox_file="w7.vbox" vm_name="w7"> <libc stdout="/dev/log" stderr="/dev/log"> <vfs> <dir name="dev"> <log/> </dir> </vfs> </libc> </config> </start>
This part of the script and a similar qemu invocation have been used in a variation of the rump_ext2 script as well and works fine. The NOVA hypervisor is booted from -cdrom the programs are loaded from -cdrom as well. The test program issues filesystem operation resulting in manipulations of the filesystem on device -hda.
When stating Virtualbox however, is does not work. Everything starts fine, however, virtualbox does not seem to use rump_fs (I have placed a PWRN message in the rump_fs server code that did not show up). It terminates because it cannot find w7.vbox.
Genode 14.11 int main(): --- create local services --- int main(): --- start init --- int main(): transferred 456 MB to init Quota exceeded! amount=24576, size=4096, consumed=24576 [init] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=32768, size=4096, consumed=32768 [init] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=40960, size=4096, consumed=40960 [init] upgrading quota donation for Env::CPU (8192 bytes) [init -> atapi_drv] IDE 0 Device 0: ATA IRQ: 14 [init -> acpi] available memory for ACPI 2048 kiB, for PCI_DRV 5468 kiB [init -> ps2_drv] Detected ExPS/2 mouse - activating scroll-wheel and 5-button support. [init -> ps2_drv] Using keyboard with scan code set 1 (xlate). [init -> rump_fs] Using ext2fs as file system [init -> rump_fs] int rumpuser_init(int, const rumpuser_hyperup*): RUMP ver: 17 [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_THREADS [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_VERBOSE [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): _RUMPUSER_NCPU [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_MEMLIMIT [init -> rump_fs] Asserting rump kernel 28732 KB of RAM Quota exceeded! amount=24576, size=4096, consumed=24576 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=32768, size=4096, consumed=32768 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> rump_fs] BOOTSTRAP [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_NVNODES [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_BLKFAIL [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_BLKSECTSHIFT Quota exceeded! amount=40960, size=4096, consumed=40960 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> acpi] void Acpi_table::_parse_tables(T*, Genode::uint32_t) [with T = unsigned int; Genode::uint32_t = unsigned int]: Found MADT Quota exceeded! amount=49152, size=4096, consumed=49152 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> acpi] MADT IRQ 0 -> GSI 2 flags: 0 [init -> acpi] MADT IRQ 5 -> GSI 5 flags: d [init -> acpi] MADT IRQ 9 -> GSI 9 flags: d [init -> acpi] MADT IRQ 10 -> GSI 10 flags: d [init -> acpi] MADT IRQ 11 -> GSI 11 flags: d Quota exceeded! amount=61440, size=4096, consumed=61440 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) Quota exceeded! amount=57344, size=4096, consumed=57344 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_MODULEBASE Quota exceeded! amount=69632, size=4096, consumed=69632 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) Quota exceeded! amount=65536, size=4096, consumed=65536 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=77824, size=4096, consumed=77824 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) [init -> acpi -> pci_drv] PCI driver started Quota exceeded! amount=73728, size=4096, consumed=73728 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): _RUMPUSER_HOSTNAME Quota exceeded! amount=86016, size=4096, consumed=86016 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) Quota exceeded! amount=81920, size=4096, consumed=81920 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> acpi -> pci_drv -> pci_device_pd] PCI device pd starting ... [init -> acpi -> pci_drv -> pci_device_pd] PCI device pd started [init -> acpi] ACPI table format not supported - will not rewrite GSIs [init -> atapi_drv] Found IDE Bus Master (Vendor ID: 8086 Device ID: 7010 Class: 00010180) [init -> atapi_drv] Bus master interface base addr: 0000c100 (I/O) secondary (no) (supported) [init -> atapi_drv] Adress mode is LBA48 [init -> atapi_drv] UDMA Modes supported: [init -> atapi_drv] 0 and below: yes enabled: no [init -> atapi_drv] 1 and below: yes enabled: no [init -> atapi_drv] 2 and below: yes enabled: no [init -> atapi_drv] 3 and below: yes enabled: no [init -> atapi_drv] 4 and below: yes enabled: no [init -> atapi_drv] 5 and below: yes enabled: yes [init -> atapi_drv] PRD base at 03035000 (physical) at 00004000 (virtual) [init -> atapi_drv] Device initialized! Enabling interrupts ... [init -> atapi_drv] First block: 0 last block 104857599, block size 512 [init -> rump_fs] Backend::Backend(): Backend blk_size 512 [init -> fb_drv] int Framebuffer_drv::map_io_mem(Genode::addr_t, Genode::size_t, bool, void**, Genode::addr_t, Genode::Dataspace_capability*): fb mapped to 1000 Quota exceeded! amount=94208, size=4096, consumed=94208 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) [init -> virtualbox] void init_libc_lock_pipe(): init_libc_lock_pipe() [init -> virtualbox] using the pipe libc plugin [init -> virtualbox] getenv called for non-existent variable "XML_MEM_BREAKPOINT" [init -> virtualbox] getenv called for non-existent variable "XML_MEM_TRACE" [init -> virtualbox] getenv called for non-existent variable "LC_ALL" [init -> virtualbox] getenv called for non-existent variable "LC_CTYPE" [init -> virtualbox] getenv called for non-existent variable "LANG" [init -> virtualbox] getenv called for non-existent variable "PATH_LOCALE" [init -> virtualbox] getenv called for non-existent variable "VBOX_DISABLE_HOST_DISK_CACHE" [init -> virtualbox] getenv called for non-existent variable "CHARSETALIASDIR" [init -> virtualbox] plugin()->open("") failed [init -> virtualbox] fcntl(): command 2 not supported [init -> virtualbox] Log created: 2015-02-22T21:29:03.000000000Z [init -> virtualbox] main Executable: /virtualbox [init -> virtualbox] C++ runtime: xml::EIPRTFailure [init -> virtualbox] C++ runtime: Runtime error opening 'w7.vbox' for reading: -102(File not found.) [init -> virtualbox] void* abort(): abort called
What I do not understand is, how one can tell/direct Virtualbox to use a particular device or filesystem. Can somebody explain this ?
Regards, Adrian
Hello,
On 23.02.2015 00:22, a3an wrote:
<start name="virtualbox" priority="-2"> <resource name="RAM" quantum="750M"/> <config vbox_file="w7.vbox" vm_name="w7"> <libc stdout="/dev/log" stderr="/dev/log"> <vfs> <dir name="dev"> <log/> </dir> </vfs> </libc> </config> </start>
you need to add an '<fs />' tag to the VFS configuration to integrate the file system provided by the 'File_system' service of 'rump_fs'.
Regards, Christian
Hello Christian,
thanks.
I have added <fs/> to the vfs config section of virtualbox. But now the system hangs and has to be canceled. No messages from virtualbox either.
Genode 14.11 int main(): --- create local services --- int main(): --- start init --- int main(): transferred 456 MB to init Quota exceeded! amount=24576, size=4096, consumed=24576 [init] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=32768, size=4096, consumed=32768 [init] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=40960, size=4096, consumed=40960 [init] upgrading quota donation for Env::CPU (8192 bytes) [init -> atapi_drv] IDE 0 Device 0: ATA IRQ: 14 [init -> acpi] available memory for ACPI 2048 kiB, for PCI_DRV 5468 kiB [init -> ps2_drv] Detected ExPS/2 mouse - activating scroll-wheel and 5-button support. [init -> ps2_drv] Using keyboard with scan code set 1 (xlate). [init -> rump_fs] Using ext2fs as file system [init -> rump_fs] int rumpuser_init(int, const rumpuser_hyperup*): RUMP ver: 17 [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_THREADS [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_VERBOSE [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): _RUMPUSER_NCPU [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_MEMLIMIT [init -> rump_fs] Asserting rump kernel 28732 KB of RAM Quota exceeded! amount=24576, size=4096, consumed=24576 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=32768, size=4096, consumed=32768 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> rump_fs] BOOTSTRAP [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_NVNODES [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_BLKFAIL [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_BLKSECTSHIFT Quota exceeded! amount=40960, size=4096, consumed=40960 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=49152, size=4096, consumed=49152 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> acpi] void Acpi_table::_parse_tables(T*, Genode::uint32_t) [with T = unsigned int; Genode::uint32_t = unsigned int]: Found MADT [init -> acpi] MADT IRQ 0 -> GSI 2 flags: 0 [init -> acpi] MADT IRQ 5 -> GSI 5 flags: d [init -> acpi] MADT IRQ 9 -> GSI 9 flags: d [init -> acpi] MADT IRQ 10 -> GSI 10 flags: d [init -> acpi] MADT IRQ 11 -> GSI 11 flags: d Quota exceeded! amount=61440, size=4096, consumed=61440 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) Quota exceeded! amount=57344, size=4096, consumed=57344 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): RUMP_MODULEBASE Quota exceeded! amount=69632, size=4096, consumed=69632 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) Quota exceeded! amount=65536, size=4096, consumed=65536 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) Quota exceeded! amount=77824, size=4096, consumed=77824 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) [init -> acpi -> pci_drv] PCI driver started Quota exceeded! amount=73728, size=4096, consumed=73728 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> rump_fs] int rumpuser_getparam(const char*, void*, size_t): _RUMPUSER_HOSTNAME Quota exceeded! amount=86016, size=4096, consumed=86016 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) Quota exceeded! amount=81920, size=4096, consumed=81920 [init -> rump_fs] upgrading quota donation for Env::CPU (8192 bytes) [init -> acpi -> pci_drv -> pci_device_pd] PCI device pd starting ... [init -> acpi -> pci_drv -> pci_device_pd] PCI device pd started [init -> acpi] ACPI table format not supported - will not rewrite GSIs [init -> atapi_drv] Found IDE Bus Master (Vendor ID: 8086 Device ID: 7010 Class: 00010180) [init -> atapi_drv] Bus master interface base addr: 0000c100 (I/O) secondary (no) (supported) [init -> atapi_drv] Adress mode is LBA48 [init -> atapi_drv] UDMA Modes supported: [init -> atapi_drv] 0 and below: yes enabled: no [init -> atapi_drv] 1 and below: yes enabled: no [init -> atapi_drv] 2 and below: yes enabled: no [init -> atapi_drv] 3 and below: yes enabled: no [init -> atapi_drv] 4 and below: yes enabled: no [init -> atapi_drv] 5 and below: yes enabled: yes [init -> atapi_drv] PRD base at 03035000 (physical) at 00004000 (virtual) [init -> atapi_drv] Device initialized! Enabling interrupts ... [init -> atapi_drv] First block: 0 last block 104857599, block size 512 [init -> fb_drv] int Framebuffer_drv::map_io_mem(Genode::addr_t, Genode::size_t, bool, void**, Genode::addr_t, Genode::Dataspace_capability*): fb mapped to 1000 [init -> rump_fs] Backend::Backend(): Backend blk_size 512 Quota exceeded! amount=94208, size=4096, consumed=94208 [init -> rump_fs] upgrading quota donation for Env::RM (8192 bytes) int main(): --- init created, waiting for exit condition --- Expect: 'interact' received 'strg+c' and was cancelled
Regards, Adrian
Am 23.02.2015 um 00:41 schrieb Christian Prochaska:
Hello,
On 23.02.2015 00:22, a3an wrote:
<start name="virtualbox" priority="-2"> <resource name="RAM" quantum="750M"/> <config vbox_file="w7.vbox" vm_name="w7"> <libc stdout="/dev/log" stderr="/dev/log"> <vfs> <dir name="dev"> <log/> </dir> </vfs> </libc> </config> </start>
you need to add an '<fs />' tag to the VFS configuration to integrate the file system provided by the 'File_system' service of 'rump_fs'.
Regards, Christian
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.cl... _______________________________________________ genode-main mailing list genode-main@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/genode-main
Hello Adrian,
On 02/23/2015 12:29 PM, a3an wrote:
Hello Christian,
thanks.
I have added <fs/> to the vfs config section of virtualbox. But now the system hangs and has to be canceled. No messages from virtualbox either.
Can you please send your complete run script?
Regards, Christian
Hello Christian,
here is the build script. I have done a make clean before to get rid of any "dirt". I should mention that two patches have been installed to rump_fs as suggested by Josef to improve sync management:
https://github.com/cnuke/genode/commit/5ba470b6b and another patch to provide sync() support to rump_fs.
set use_net 0
set build_components { core init virtualbox drivers/input drivers/framebuffer drivers/timer server/rump_fs test/libc_vfs drivers/atapi }
lappend_if [have_spec acpi] build_components drivers/acpi lappend_if [have_spec pci] build_components drivers/pci lappend_if [have_spec x86] build_components drivers/rtc
lappend_if [expr $use_net] build_components drivers/nic
build $build_components
create_boot_directory
set config { <config prio_levels="4"> <parent-provides> <service name="ROM"/> <service name="RAM"/> <service name="IRQ"/> <service name="IO_MEM"/> <service name="IO_PORT"/> <service name="CAP"/> <service name="PD"/> <service name="RM"/> <service name="CPU"/> <service name="LOG"/> <service name="SIGNAL"/> </parent-provides> <default-route> <any-service> <any-child/> <parent/> </any-service> </default-route> <start name="timer"> <resource name="RAM" quantum="1M"/> <provides><service name="Timer"/></provides> </start>}
append_if [have_spec acpi] config { <start name="acpi" priority="-1"> <resource name="RAM" quantum="8M"/> <binary name="acpi_drv"/> <provides> <service name="PCI"/> <service name="IRQ" /> </provides> <route> <service name="PCI"> <any-child /> </service> <any-service> <parent/> <any-child /> </any-service> </route> </start>}
append_if [expr ![have_spec acpi] && [have_spec pci]] config { <start name="pci_drv" priority="-1"> <resource name="RAM" quantum="2M"/> <provides> <service name="PCI"/> </provides> </start>}
append_if [have_spec ps2] config { <start name="ps2_drv" priority="-1"> <resource name="RAM" quantum="1M"/> <provides><service name="Input"/></provides> </start>}
append_if [have_spec framebuffer] config { <start name="fb_drv" priority="-1"> <resource name="RAM" quantum="4M"/> <provides><service name="Framebuffer"/></provides> </start>}
append_if [have_spec sdl] config { <start name="fb_sdl" priority="-1"> <resource name="RAM" quantum="4M"/> <provides> <service name="Input"/> <service name="Framebuffer"/> </provides> </start>}
append_if [have_spec x86] config { <start name="rtc_drv" priority="-1"> <resource name="RAM" quantum="1M"/> <provides> <service name="Rtc"/> </provides> </start>}
append_if [expr $use_net] config { <start name="nic_drv" priority="-1"> <resource name="RAM" quantum="4M"/> <provides><service name="Nic"/></provides> </start> }
append config {
<start name="atapi_drv"> <resource name="RAM" quantum="5M"/> <provides><service name="Block"/></provides> <config ata="yes"/> </start>
<start name="rump_fs" priority="-1"> <resource name="RAM" quantum="32M" /> <provides><service name="File_system"/></provides> <config fs="ext2fs"><policy label="" root="/" writeable="yes"/></config> </start>
<start name="virtualbox" priority="-2"> <resource name="RAM" quantum="750M"/> <config vbox_file="w7.vbox" vm_name="w7"> <libc stdout="/dev/log" stderr="/dev/log"> <vfs> <dir name="dev"> <log/> </dir> <fs/> </vfs> </libc> </config> </start> </config> }
install_config $config
exec cp ${genode_dir}/repos/ports/run/test.vbox bin/.
set boot_modules { core init timer virtualbox }
# platform-specific modules lappend_if [have_spec ps2] boot_modules ps2_drv lappend_if [have_spec acpi] boot_modules acpi_drv lappend_if [have_spec pci] boot_modules pci_drv lappend_if [have_spec framebuffer] boot_modules fb_drv lappend_if [have_spec linux] boot_modules fb_sdl lappend_if [have_spec nova] boot_modules pci_device_pd lappend_if [have_spec x86] boot_modules rtc_drv
append boot_modules { ld.lib.so libc.lib.so libm.lib.so pthread.lib.so libc_lock_pipe.lib.so libc_terminal.lib.so libiconv.lib.so stdcxx.lib.so rump.lib.so rump_fs.lib.so rump_fs atapi_drv }
append_if [expr $use_net] boot_modules { nic_drv }
build_boot_image $boot_modules
append qemu_args " -m 512 " append qemu_args " -cpu phenom -boot order=d, -hda /GV/QV.img "
run_genode_until forever Am 23.02.2015 um 15:26 schrieb Christian Prochaska:
Regards, Adrian
Hello Adrian,
On 02/23/2015 12:29 PM, a3an wrote:
Hello Christian,
thanks.
I have added <fs/> to the vfs config section of virtualbox. But now the system hangs and has to be canceled. No messages from virtualbox either.
Can you please send your complete run script?
Regards, Christian
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.cl... _______________________________________________ genode-main mailing list genode-main@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/genode-main
Hello Christian,
I found a possible cause, it seems that the pci_drv and and apci_drv collide. By disabling append_if statements I prevented the apci_driver to be loaded and started.
I am getting much farther now, but I don't understand the following:
[init -> virtualbox] Log created: 2015-02-24T01:07:15.000000000Z [init -> virtualbox] main Executable: /virtualbox [init -> virtualbox] SystemProperties : Cannot determine default Guest Additions ISO location. Most likely they are not available [init] priority band too small, losing least-significant priority bits [init -> virtualbox] Machine : Machine settings file '/VirtualBox VMs/w7/w7.vbox' already exists [init -> virtualbox] Start-up of VMM failed - reason 15 - exiting ... Expect: 'interact' received 'strg+c' and was cancelled adrian@...269...:~/genode-14.11/fs.build$
Why is VirtualBox complaining about the w7.vbox file that it is already there? I want VirtualBox to use this file and its vdi companion.
Regards, Adrian
Am 23.02.2015 um 15:26 schrieb Christian Prochaska:
Hello Adrian,
On 02/23/2015 12:29 PM, a3an wrote:
Hello Christian,
thanks.
I have added <fs/> to the vfs config section of virtualbox. But now the system hangs and has to be canceled. No messages from virtualbox either.
Can you please send your complete run script?
Regards, Christian
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.cl... _______________________________________________ genode-main mailing list genode-main@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/genode-main
Hello Adrian,
I could not reproduce the same problem you reported, but found two other problems when trying to run VirtualBox in Qemu:
First, 'atapi_drv' does not run well on newer Qemu versions (I used Qemu 2.2.0), so I changed your run script to use the 'ahci' driver instead (see attachment).
Then I tried to run TinyCore Linux in the VM (with both the .vbox and the .iso file in the root directory of the ext2 image) and when the Linux kernel started to boot, VirtualBox reported 'invalid gueststate' errors and the kernel boot process never finished.
So, even if you can find out why your VirtualBox complains about the 'w7.vbox' file, I would not have too high hopes of getting your VM running in VirtualBox on Qemu (or with AMD SVM hardware virtualization in general) without some prior work on the VirtualBox port. So far we have used and tested VirtualBox mainly on Intel hardware. Would that be an option for you?
Regards, Christian
Hello Christian,
I have been running Nova 64 bit on a AMD Phenom machine and am using qemu version 1.0.
The problem symptoms varied from 'vbox file already existing' to not starting virtualbox at all. I decided to switch to Nova 32 bit. Now the symptoms are stable, I am getting 'vbox file already exising' every time now.
I went through the code of genode-14.11/repos/ports/src/virtualbox/frontend/main.cc, which to me seems to be the driver of VirtualBox proper.
At around line 106 I found rc = machine->init(virtualbox, vm_name, *machine_config); This call is unsuccessful and also generates the "Machine : Machine settings file '/VirtualBox VMs/w7/w7.vbox' already exists" message. I have located the the VirtualBox file where this message is emanating from, it is MachineImpl.cpp, which can be found in genode-14.11/contrib/virtualbox-fd1a0bb3692bfb4448f3b3f8978fc1c5d037e2c4/src/app/virtualbox/src/VBox/Main/src-server.
This is the function that is called at around line 502:
/** * Initializes a new instance from a machine config that is already in memory * (import OVF case). Since we are importing, the UUID in the machine * config is ignored and we always generate a fresh one. * * @param strName Name for the new machine; this overrides what is specified in config and is used * for the settings file as well. * @param config Machine configuration loaded and parsed from XML. * * @return Success indicator. if not S_OK, the machine object is invalid */
HRESULT Machine::init(VirtualBox *aParent, const Utf8Str &strName, const settings::MachineConfigFile &config)
In here, Machine::tryCreateMachineConfigFile() is called (at 534). This call finds out that the vbox file already exists and terminates VirtualBox.
I have tried to call Machine::initFromSettings() instaed in main.cc, but that causes a lot more error messages for which I am lacking detailed knowledge about the innards of VirtualBox.
Up to here, I don't think qemu or atapi_drv are to blame for this problem, the call to Machine::init() looks to be the problem.
So, how exactly did genode.org succeed in executing Windows 7 with VirtualBox on Nova using genode-14.11 ?
Regards, Adrian Schuur.
Am 24.02.2015 um 19:21 schrieb Christian Prochaska:
Hello Adrian,
I could not reproduce the same problem you reported, but found two other problems when trying to run VirtualBox in Qemu:
First, 'atapi_drv' does not run well on newer Qemu versions (I used Qemu 2.2.0), so I changed your run script to use the 'ahci' driver instead (see attachment).
Then I tried to run TinyCore Linux in the VM (with both the .vbox and the .iso file in the root directory of the ext2 image) and when the Linux kernel started to boot, VirtualBox reported 'invalid gueststate' errors and the kernel boot process never finished.
So, even if you can find out why your VirtualBox complains about the 'w7.vbox' file, I would not have too high hopes of getting your VM running in VirtualBox on Qemu (or with AMD SVM hardware virtualization in general) without some prior work on the VirtualBox port. So far we have used and tested VirtualBox mainly on Intel hardware. Would that be an option for you?
Regards, Christian
Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/
genode-main mailing list genode-main@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/genode-main
Hello Adrian,
I could reproduce your problem now. It occurred when I stored the 'w7.vbox' file in the '/VirtualBox VMs/w7/' directory. Before, I had it stored in the root directory only and the problem did not occur. For running Windows 7 with VirtualBox on Nova we're using the 'virtualbox_auto_disk.run' script, which loads the '.vbox' file from the ROM service.
Regards, Christian
Hello Christian,
I have been off-line for a while, but want to come back to our conversation. Meanwhile, I was able to verify that the problem also exits in 15.02.
I just wonder what will be done to fix this. Is there a way to open problem-ticket for this problem ? Or, is there an explanation as to what the problem is ?
As to 'virtualbox_auto_disk.run', I am unable to execute this run-script. I get the message 'Run script does not support Qemu.'. Could you explain how this script should be executed ?
Regards, Adrian
Am 26.02.2015 um 13:47 schrieb Christian Prochaska:
Hello Adrian,
I could reproduce your problem now. It occurred when I stored the 'w7.vbox' file in the '/VirtualBox VMs/w7/' directory. Before, I had it stored in the root directory only and the problem did not occur. For running Windows 7 with VirtualBox on Nova we're using the 'virtualbox_auto_disk.run' script, which loads the '.vbox' file from the ROM service.
Regards, Christian
Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ genode-main mailing list genode-main@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/genode-main
Hello Adrian,
On 11.03.2015 00:02, a3an wrote:
I just wonder what will be done to fix this. Is there a way to open problem-ticket for this problem ? Or, is there an explanation as to what the problem is ?
you can create an issue at https://github.com/genodelabs/genode/issues
There's no explanation yet, but as a temporary workaround you can move the .vbox file into the root directory or load it from a ROM service.
As to 'virtualbox_auto_disk.run', I am unable to execute this run-script. I get the message 'Run script does not support Qemu.'. Could you explain how this script should be executed ?
A simple way to use the script is with the following run tool configuration in 'build/nova_x86_64/etc/build.conf' (latest Genode release):
RUN_OPT = --include boot_dir/nova \ --include image/iso
With this configuration, 'make run/vbox_auto_win7' will create an ISO image in the 'var/run' directory, which you could write on a USB stick (using 'dd') and boot from it on real hardware.
The script provides VirtualBox with the 'vm_win7.vbox' file, which needs to get adapted to the actual VDI files to be used. The 'overlay.vdi' file can be created like this:
- $ VboxManage showhdinfo win7.vdi - remember the 'Capacity' value - $ VboxManage createhd --filename overlay_win7.vdi --size [Capacity value] --format vdi
Also, the UUIDs in the 'vm_win7.vbox' file need to get replaced by the real UUIDs of the VDI files (also shown by 'VBoxManage showhdinfo').
The VDI files are loaded from an 'ext2' file system on the fourth primary partition of the hard disk. The partition number can be changed in 'virtualbox_auto.inc'.
Having a serial port on the target machine is highly recommended to know what the problem could be if it doesn't work right away.
Regards, Christian