🏁 Start VirtualBox VM in Headless Mode

• 1 min read • 62 votes

This post was last updated Mar 13, 2013 and may be out of date

It is fairly common in web development to run code in a virtual machine (VM) so that you can mirror your production environment. However, using a GUIless operating system through VirtualBox’s GUI window is a terrible experience. Fortunately VirtualBox provides an easy way of starting a VM using their command line tool VBoxManage in a headless mode.

# List virtual machines
VBoxManage list vms
"MyVM" {e4b0c92c-4301-4a7d-8af8-fe02fed00451}

# Start VM in headless mode
VBoxManage startvm MyVM --type headless

# Power off VM
VBoxManage controlvm MyVM poweroff

Once the virtual machine has started you can connect to it over SSH and use it as you would any server operating system.

62 cheers
Now look what you've done 🌋
Stop clicking and run for your life! 😱
Uh oh, I don't think the system can't handle it! 🔥
Stop it, you're too kind 😄
Thanks for the love! ❤️
Thanks, glad you enjoyed it! Care to share?
HN Reddit

More Posts ✍🏻

See All »
• 4 min read • 3811 votes
😈 Productive Procrastination
Read Post »
• 6 min read • 65 votes
👔 Quit With Positivity
Read Post »
• 4 min read • 567 votes
💻 Wait for User to Stop Typing, in JavaScript
Read Post »
• 3 min read • 268 votes
🌁 Unlimited Potential
Read Post »
• 5 min read • 399 votes
🚀 Getting Over the Fear of Launching
Read Post »
• 2 min read • 405 votes
🗓 2019 Year in Review: Prioritizing Health
Read Post »
• 6 min read • 144 votes
🎈 Abandoning the Static Site
Read Post »

Be the first to hear about posts, right in your inbox 💌