Author Topic: Can't get VirtualBox to work. (ABANDONED)  (Read 4628 times)

0 Members and 1 Guest are viewing this topic.

Offline Tony Norton

  • Jr. Member
  • **
  • Posts: 78
  • Karma: 0
  • I've just joined!
    • View Profile
    • Awards
Can't get VirtualBox to work. (ABANDONED)
« on: November 09, 2012, 12:36:07 pm »
Browsed around and found that Linux Mint 13 comes with VirtualBox.

Ran "sudo apt-get install virtualbox" in the terminal and followed what happened. Relevant info (AFIK): -

"The following packages will be REMOVED
  virtualbox-4.1 virtualbox-nonfree
The following NEW packages will be installed
  libgsoap1 virtualbox virtualbox-dkms virtualbox-qt
0 upgraded, 4 newly installed, 2 to remove and 56 not upgraded.
"

Halfway down it reported: -

"* No suitable module for running kernel found
                                                                           [fail]
"

and the final lines were: -

"DKMS: install completed.
 * Stopping VirtualBox kernel modules                                      [ OK ]
 * Starting VirtualBox kernel modules                                      [ OK ]
Setting up virtualbox-qt (4.1.12-dfsg-2ubuntu0.1) ...
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
"

However.................when I run VirtualBox(Menu/Accessories/VirtualBox) and try to [Start] it I get: -

 "FATAL: No bootable medium found! System halted."

If I catch the [F12] I am offered: -

"VirtualBox temporary boot device selection

Detected Hard disks:

IDE controller:

1) Primary Master

Other boot devices:
f) Floppy
c) CD-ROM
l) LAN

b) continue booting"


All of these (I tried my bootable XP64 disk in the CD drive) return exactly the same "FATAL....." message.

What have I not set up correctly? I would have expected VB to detect my WinXP64 drive, which is SATA not IDE. The IDE "Primary Master" is, I would suggest, my Linux boot disk. The [Files] icon finds all my drives without any problem.

I am now somewhat stumped. :(

Tony N




« Last Edit: November 13, 2012, 12:27:25 pm by Tony Norton »

Offline Mad Penguin

  • #Mad_Penguin_UK
  • Administrator
  • Hero Member
  • *****
  • Posts: 1320
  • Karma: 10017
  • Gender: Male
    • View Profile
    • Linux in the UK
    • Awards
Re: Can't get VirtualBox to work.
« Reply #1 on: November 09, 2012, 03:28:53 pm »
And the reason you're not using KVM with virt-manager ... ? ( this also comes with and is generally a more robust solution)

Sent from my Nexus S using Tapatalk 2


Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13999
  • Karma: 348
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Can't get VirtualBox to work.
« Reply #2 on: November 09, 2012, 04:14:36 pm »
Firstly there's a reason people don't just tell you to install Virtualbox through the package manager ..

a) it won't be the latest version
and
b) it will likely install the OSS version that doesn't support things like USB pass through.

So the first thing you want to do is remove it:
Code: [Select]
sudo apt-get remove virtualbox
then
Code: [Select]
sudo apt-get autoremove

Now send the output from:
Code: [Select]
dpkg -l | grep virtualbox



Mad Penguins suggestion -

KVM requires hardware acceleration, so won't work with all CPU's .. but there's an easy way to find out if your CPU supports everything KVM requires.

run:
Code: [Select]
sudo apt-get install cpu-checker
now what is the output from:
Code: [Select]
sudo kvm-ok



Send the output from those, and we'll go from there :)
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Tony Norton

  • Jr. Member
  • **
  • Posts: 78
  • Karma: 0
  • I've just joined!
    • View Profile
    • Awards
Re: Can't get VirtualBox to work.
« Reply #3 on: November 09, 2012, 05:00:01 pm »
Firstly there's a reason people don't just tell you to install Virtualbox through the package manager ..

a) it won't be the latest version
and
b) it will likely install the OSS version that doesn't support things like USB pass through.

So the first thing you want to do is remove it:
Code: [Select]
sudo apt-get remove virtualbox


Done

Quote
then
Code: [Select]
sudo apt-get autoremove


Done

Quote
Now send the output from:
Code: [Select]
dpkg -l | grep virtualbox


Output (grep)=

rc  virtualbox                             4.1.12-dfsg-2ubuntu0.1                  x86 virtualization solution - base binaries
rc  virtualbox-4.1                         4.1.12-77245~Ubuntu~precise             Oracle VM VirtualBox
ii  virtualbox-guest-dkms                  4.1.12-dfsg-2ubuntu0.1                  x86 virtualization solution - guest addition module source for dkms
ii  virtualbox-guest-utils                 4.1.12-dfsg-2ubuntu0.1                  x86 virtualization solution - non-X11 guest utilities
ii  virtualbox-guest-x11                   4.1.12-dfsg-2ubuntu0.1                  x86 virtualization solution - X11 guest utilities
rc  virtualbox-qt                          4.1.12-dfsg-2ubuntu0.1                  x86 virtualization solution - Qt based user interface




Quote
Mad Penguins suggestion -

KVM requires hardware acceleration, so won't work with all CPU's .. but there's an easy way to find out if your CPU supports everything KVM requires.

run:
Code: [Select]
sudo apt-get install cpu-checker


Output (cpu chk)=

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  msr-tools
The following NEW packages will be installed
  cpu-checker msr-tools
0 upgraded, 2 newly installed, 0 to remove and 56 not upgraded.
Need to get 15.6 kB of archives.
After this operation, 123 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://archive.ubuntu.com/ubuntu/ precise/main msr-tools amd64 1.2-3 [9,052 B]
Get:2 http://archive.ubuntu.com/ubuntu/ precise/main cpu-checker amd64 0.7-0ubuntu1 [6,538 B]
Fetched 15.6 kB in 0s (84.7 kB/s)
Selecting previously unselected package msr-tools.
(Reading database ... 171678 files and directories currently installed.)
Unpacking msr-tools (from .../msr-tools_1.2-3_amd64.deb) ...
Selecting previously unselected package cpu-checker.
Unpacking cpu-checker (from .../cpu-checker_0.7-0ubuntu1_amd64.deb) ...
Processing triggers for man-db ...
Setting up msr-tools (1.2-3) ...
Setting up cpu-checker (0.7-0ubuntu1) ...

Quote
now what is the output from:
Code: [Select]
sudo kvm-ok


Output (kvm)=

INFO: /dev/kvm does not exist
HINT:   sudo modprobe kvm_amd
INFO: Your CPU supports KVM extensions
KVM acceleration can be used



Quote
Send the output from those, and we'll go from there :)


Mark to the rescue - again!

Thanks mate,

Tony N

P.S. Please note, I have finally sorted out the "quote-unquote" procedure.

Offline Mad Penguin

  • #Mad_Penguin_UK
  • Administrator
  • Hero Member
  • *****
  • Posts: 1320
  • Karma: 10017
  • Gender: Male
    • View Profile
    • Linux in the UK
    • Awards
Re: Can't get VirtualBox to work.
« Reply #4 on: November 09, 2012, 05:10:05 pm »
You might also find KVM is "fractionally" quicker, esp. on IO for anything supporting virtio drivers. (which is pretty much everything bar Centos)

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13999
  • Karma: 348
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Can't get VirtualBox to work.
« Reply #5 on: November 09, 2012, 05:21:43 pm »
OK, looks like you're good to go with KVM/virt-manager :)

I must explain that I'm new to this approach myself, so we'll be finding our way through it together .. but as MP says (if your hardware supports it) it's probably a better solution.

OK, let's install kvm and virt-manager:
Code: [Select]
sudo apt-get install kvm virt-manager

Now lets' check if you're in the kvm group ..

REBOOT (not sure if this is necessary, but won't hurt)

Now send the output from:
Code: [Select]
groups
and
Code: [Select]
kvm
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Tony Norton

  • Jr. Member
  • **
  • Posts: 78
  • Karma: 0
  • I've just joined!
    • View Profile
    • Awards
Re: Can't get VirtualBox to work.
« Reply #6 on: November 10, 2012, 10:55:32 am »
OK, looks like you're good to go with KVM/virt-manager :)

I must explain that I'm new to this approach myself, so we'll be finding our way through it together .. but as MP says (if your hardware supports it) it's probably a better solution.

OK, let's install kvm and virt-manager:
Code: [Select]
sudo apt-get install kvm virt-manager



Done

Quote

Now lets' check if you're in the kvm group ..

REBOOT (not sure if this is necessary, but won't hurt)

Now send the output from:
Code: [Select]
groups



Output="tony adm cdrom sudo dip plugdev lpadmin sambashare"

Quote
and
Code: [Select]
kvm


Output=(relevant details after <ctrl-B>)
window headed QEMU



Booting from ROM...
iPXE (PCI 00:03.0) starting execution...ok
iPXE initialising devices...ok

iPXE 1.0.0+ -- Open Source Network Boot Firmware -- http://ipxe.org
Features: HTTP iSCSI DMS TFTP AoE bzImage COMBOOT ELF MBOOT PXE PXEXT

net0 52:54 blah, blah, blah to

Nothing to boot: no such file or directory (http://ipxe.org/2d03e13b)
No more network devices

Booting from Hard Disk...
Boot failed: could not read the boot disk

Booting from Floppy...
Boot failed: etc

No bootable device



This window was not 'active' so I couldn't copy it.
Not sure what it was trying to boot, "kvm" or "WinXP"

I put a bootable floppy in the Floppy drive and got a similar result, except that after the "Features" line I got a prompt: -

"iPXE>"

The mouse was not active in this window, but the keyboard was. I typed in "help" and got a list of 38 acceptable commands, some of which were similar to DOS commands, but most of which were new to me.

Typing "exit" did take me out of that window, but resulted in the window as above.

As I had seen, after typing "exit", an attempt to boot from CDROM, I put my bootable XP64 disk in the drive and re-ran the "exit" command, but it didn't 'see' the CDROM drive as bootable.

Over to the experts.

Tony N

Offline Mad Penguin

  • #Mad_Penguin_UK
  • Administrator
  • Hero Member
  • *****
  • Posts: 1320
  • Karma: 10017
  • Gender: Male
    • View Profile
    • Linux in the UK
    • Awards
Re: Can't get VirtualBox to work.
« Reply #7 on: November 10, 2012, 11:33:41 am »
Type "virt-manager"

Sent from my Nexus S using Tapatalk 2


Offline Tony Norton

  • Jr. Member
  • **
  • Posts: 78
  • Karma: 0
  • I've just joined!
    • View Profile
    • Awards
Re: Can't get VirtualBox to work.
« Reply #8 on: November 10, 2012, 12:19:39 pm »
Type "virt-manager"

Sent from my Nexus S using Tapatalk 2



Hi Mad Penguin,

did that, and got this: -





Virtual Machine Connection Failure

Unable to connect to libvirt:

Failed to connect socket to '/var/run/libvirt/libvirt-sock': Permission denied

Verify that:
 - The 'libvirt-bin' package is installed
 - The 'libvirtd' daemon has been started
 - You are member of the 'libvirtd' group



When I entered "sudo apt install libvirt" I got: -  "E: Unable to locate package libvirt".

When I entered "groups" I got: - "tony adm cdrom sudo dip plugdev lpadmin sambashare".

It would seem that I'm not a member. How do I join? Please?

Tony N

Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13999
  • Karma: 348
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Can't get VirtualBox to work.
« Reply #9 on: November 10, 2012, 12:42:24 pm »
OK, the "Users and Groups" GUI application may not be installed by default in 12.04/12.10, so run:
Code: [Select]
sudo apt-get install gnome-system-tools

Now fire up "Users and Groups" .. then click "Manage Groups" .. scroll down to "libvirtd", and double-click it .. in the resulting "Group 'libvirtd' Properties" dialog box, make sure your username is ticked .. click "OK" .. close the other dialog boxes that are still open.

REBOOT.

when rebooted, run:
Code: [Select]
groups
and post the output.

also try:
Code: [Select]
virt-manager
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Mad Penguin

  • #Mad_Penguin_UK
  • Administrator
  • Hero Member
  • *****
  • Posts: 1320
  • Karma: 10017
  • Gender: Male
    • View Profile
    • Linux in the UK
    • Awards
Re: Can't get VirtualBox to work.
« Reply #10 on: November 10, 2012, 02:33:30 pm »
Yeah, what Mark said ..  :)

To find out why, do ls -la on the file it says you don't have permission to access, i.e;

Code: [Select]
# ls -la /var/run/libvirt/libvirt-sock
srwxrwx--- 1 root libvirtd 0 Nov  9 12:13 /var/run/libvirt/libvirt-sock
Note from this, full access is available to "root" and to anyone in the "libvirtd" group.
As you want to run virt-manager as a user, and as the program seems to need access to this file, your only option is to join the group ..  :)


Offline Mad Penguin

  • #Mad_Penguin_UK
  • Administrator
  • Hero Member
  • *****
  • Posts: 1320
  • Karma: 10017
  • Gender: Male
    • View Profile
    • Linux in the UK
    • Awards
Re: Can't get VirtualBox to work.
« Reply #11 on: November 10, 2012, 02:36:44 pm »
When the GUI appears, add a connection to "localhost" (all default settings once you select "connect") and you should then see an option to add a new VM. What you will need is an ISO image of the CD you want to install from .. for example, RIP a copy of Ubuntu 12.04 and store the image in /var/lib/libvirt/images as ubuntu_12.04.iso, then when you come to add a VM it should let you select this as the "ISO" to install from.

Offline Tony Norton

  • Jr. Member
  • **
  • Posts: 78
  • Karma: 0
  • I've just joined!
    • View Profile
    • Awards
Re: Can't get VirtualBox to work.
« Reply #12 on: November 10, 2012, 03:13:25 pm »
OK, the "Users and Groups" GUI application may not be installed by default in 12.04/12.10, so run:
Code: [Select]
sudo apt-get install gnome-system-tools

Now fire up "Users and Groups" .. then click "Manage Groups" .. scroll down to "libvirtd", and double-click it .. in the resulting "Group 'libvirtd' Properties" dialog box, make sure your username is ticked .. click "OK" .. close the other dialog boxes that are still open.


Slight problem, I don't seem to have "Users and Groups" and therefore not "Manage Groups".

If I enter "users"  in the terminal I just get "tony tony", "groups" gives the same as before.

Perhaps it's a different name, or route, in Mint from Ubuntu?

Tony N



Offline Mark Greaves (PCNetSpec)

  • Administrator
  • Hero Member
  • *****
  • Posts: 13999
  • Karma: 348
  • Gender: Male
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
    • Awards
Re: Can't get VirtualBox to work.
« Reply #13 on: November 10, 2012, 03:21:54 pm »
Open a terminal and run:
Code: [Select]
users-admin

That *should* fire up "Users and Groups".
WARNING: You are logged into reality as 'root'

logging in as 'insane' is the only safe option.

Offline Tony Norton

  • Jr. Member
  • **
  • Posts: 78
  • Karma: 0
  • I've just joined!
    • View Profile
    • Awards
Re: Can't get VirtualBox to work.
« Reply #14 on: November 10, 2012, 03:52:56 pm »
Open a terminal and run:
Code: [Select]
users-admin

That *should* fire up "Users and Groups".

Yes, thanks Mark. That did the business as far adding "libvirtd" to my "groups" which now read: -

"tony adm cdrom sudo dip plugdev lpadmin sambashare libvirtd"

Only problem now is, I don't really know how to use it. "virt-manager" brings up the "Virtual Machine Manager" window, but I've no idea where I go from there.

New VM ("Create a new virtual machine") offers an option "Import existing disk image" which I think is probably what I would like to do, but would that import the OS from my WinXP64 drive, or just the app I want to run?

I'm there, but now I am I'm even more confused.

Tony N


 


SimplePortal 2.3.3 © 2008-2010, SimplePortal