LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices



Reply
 
Search this Thread
Old 03-06-2008, 07:42 AM   #1
paul_mat
Member
 
Registered: Nov 2004
Location: Townsville, Australia
Distribution: Fedora Core 5, CentOS 4, RHEL 4
Posts: 855

Rep: Reputation: 30
virtualbox's virtual machine start on boot


hi there,

i'm looking for a way for a server to start a virtual machine using virtual box on boot?

for example:
the host PC boots up and once it's finished booting it then starts a virtual machine running inside of virtualbox.
 
Old 03-06-2008, 07:56 AM   #2
DiWi
Member
 
Registered: Jun 2004
Location: Frankfurt/M Germany
Distribution: SuSE 9.3/10.2/10.3
Posts: 64

Rep: Reputation: 16
I'm using virtual box too, but the server is running on Windows

Never than less, starting an application on boot is pretty simple:

First: Do you have to start the VBox as root? If not, you should create a new user that is used by the process running VBox. You can disable the user.

Second: Create a shell script that can starts and stop the VBox, based on a parameter value start/stop. Test is as vbox user. If it works, no problem

Third: add a script as root into /etc/init.d that runs the vbox user script as vbox user (usually su - vbox -c /home/vbox/vboxcrtl start on $1=start and similar when stop). Test this script as root. It should now start and stop the VM based on the parameter

Fourth: add two links with name S21VBoxVM and K21VBoxVM to /etc/init.d/rc5.d pointing to your script in /etc/init.d

Restart your system and vola it should work

Dirk
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
file sharing between a virtual machine and the host machine okok Linux - Networking 3 06-21-2013 01:42 AM
Unable to start virtual machine satimis Linux - Server 7 12-20-2007 12:08 AM
Virtual machine Ozonecy Linux - General 13 12-13-2007 07:03 AM
Virtual Machine phantom_cyph Linux - Software 7 05-24-2007 09:05 AM
Can I gett KPPP to start when I start a browser on a network machine? duffboygrim Linux - Networking 0 03-25-2004 05:49 PM


All times are GMT -5. The time now is 10:16 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration