Author Topic: Network boot through VirtualBox (running in Ubuntu)  (Read 8257 times)

purps

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1379
  • If it ain't broke, tweak it
    • View Profile
Network boot through VirtualBox (running in Ubuntu)
« on: November 29, 2008, 02:26:02 pm »
Does anybody know if it is possible to do a network boot through VirtualBox running in Ubuntu Intrepid? I tried setting up an "Ubuntu" OS in VB (obviously I didn't a create disk image) and tried doing the LAN option on initial start up, but it didn't work.

Does anybody have any ideas? Cheers.
1004 RC :: looking good :: upgraded 01/04/2013
my setup :: http://wiki.linuxmce.org/index.php/User:Purps

orionsune

  • Veteran
  • ***
  • Posts: 133
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #1 on: December 02, 2008, 06:02:35 pm »
I have successfully done this with VMware inside WindowsXP.  TV worked, network media browsing worked, Movies worked... thats all I really played with.
entia non sunt multiplicanda praeter necessitatem

purps

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1379
  • If it ain't broke, tweak it
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #2 on: December 10, 2008, 11:56:43 pm »
Hmm, unfortunately I have moved away from VMWare. Were there any special options you had to enable that I might be able to apply to VBox?
1004 RC :: looking good :: upgraded 01/04/2013
my setup :: http://wiki.linuxmce.org/index.php/User:Purps

justnulling

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #3 on: December 11, 2008, 06:50:36 am »
PXE works fine with VirutalBox

Here is how to set it up virtual network

edit /etc/network interfaces (my machine has one network card eth0)
Code: [Select]
auto lo
iface lo inet loopback

auto br0
iface br0 inet dhcp

auto eth0
iface eth0 inet manual
up brctl addif br0 tap0
down brctl delif br0 tap0

auto tap0
iface tap0 inet manual
up ifconfig $IFACE 0.0.0.0 up
up brctl addif br0 tap0
down ifconfig $IFACE down
down brctl delif br0 tap0
tunctl_user _USERNAME_

change _USERNAME_ (all the way at the end) to match your username

run
Code: [Select]
/etc/init.d/networking restart
Now,  (in the network tab of Virtual Box image settings) set Interface Name to
Code: [Select]
tap1
And don't forget to set the image to boot of the network.

Enjoy



purps

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1379
  • If it ain't broke, tweak it
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #4 on: December 11, 2008, 10:38:01 am »
Thanks for the reply! I shall try this as soon as my new PSU arrives.

What do you mean exactly by "don't forget to set the image to boot of the network"? Is this inside VBox, or is it something I need to do to the image stored on the core?

Cheers.
1004 RC :: looking good :: upgraded 01/04/2013
my setup :: http://wiki.linuxmce.org/index.php/User:Purps

justnulling

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #5 on: December 15, 2008, 06:48:31 am »
What do you mean exactly by "don't forget to set the image to boot of the network"? Is this inside VBox, or is it something I need to do to the image stored on the core?
This is set it the settings menu
General -> Advanced -> Boot Order: make sure only Network is checked

purps

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1379
  • If it ain't broke, tweak it
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #6 on: January 18, 2009, 04:35:48 pm »
Ok, I have got slightly further with this.

Currently, when booting, my virtual LMCE media director hangs on "[53.846691] e1000: eth0: e1000_watchdog: NIC Link is Up 1000 Mbps Full Duplex, Flow Control: RX" during startup. This happened a number of times from the word go; however, on one occasion, the boot process continued and "setup.sh" ran like normal. However, since restarting, it is now hanging again at the aforementioned part of starting up.

My /etc/network/interfaces currently looks like this:
Code: [Select]
auto lo
iface lo inet loopback

...which looks nothing like yours, justnulling! Is all of that extra stuff necessary for this netboot in VBox to work?? I did try using that code (and replacing _USERNAME_ with my username), but "/etc/init.d/networking restart" gave me a funny error, plus I couldn't changed "eth0" to "tap1" in VBox network settings as per your suggestion.

I did, however, change "NAT" to "Host Interface" in the VBox network settings, but that was all I did to make it work (and give me the problem above!). Below those settings is a list of Host Interfaces, in which "eth0" appears (the only one).

Do I need to add something in /etc/network/interfaces? Or is there an option on the core I need to change in admin? Why on Earth would it work once, and not again?!

Any help would be much appreciated.
1004 RC :: looking good :: upgraded 01/04/2013
my setup :: http://wiki.linuxmce.org/index.php/User:Purps

justnulling

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #7 on: February 03, 2009, 05:58:49 am »
UPDATE: VirtualBox 2.1 works fine straight out of the box (pun intended) with PXE
Select host interface, in my case eth0
here is my current /etc/networking/interfaces
Code: [Select]
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet dhcp

purps: you only have lo interface which is loopback not a real network interface you will need to add a real interface, the config above is a standard (not wifi) dhcp setup if your system has more then one network card you might need to change eth0 to eth1 or 2 etc. Not really sure how you were able to get it working even once with only lo interface.


purps

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1379
  • If it ain't broke, tweak it
    • View Profile
Re: Network boot through VirtualBox (running in Ubuntu)
« Reply #8 on: February 13, 2009, 09:23:10 am »
Yes, VBox 2.1 handled it no problem! Cheers.

I still only have a lo interface - I'm not sure how it's working either, but it is! Boots everytime.

Thanks for your help.
1004 RC :: looking good :: upgraded 01/04/2013
my setup :: http://wiki.linuxmce.org/index.php/User:Purps