Are there any terminal-based (ie. non-GUI) virtual-computer programs out there? I've been using programs like VirtualBox and QEMU, but they're obviously GUI-based...

I was hoping for a virtual PC program where I can do everything - create a new virtual machine, create it's disk, install OS (assuming a text-based installer is available) and start the VM on a terminal (thus replacing the host's shell with the VM's boot-message, log-in prompt and shell) - from a virtual-terminal/xterm-window/ssh/screen-session, instead of in a window under X.

The reason I ask, is that I often use ssh at work to connect to my home-computer, and the network is too slow for X or VNC. Still I'd like to tinker with VMs...


3 Answers 3


In qemu/kvm, you only get a GUI if you attach a video card to your VM and if you don't expose it as SPICE/VNC.

For instance, you can do (zsh syntax, with grub2):

grub-mkimage -O i386-pc -c =(print -l serial 'terminal_input serial' \
 'terminal_output serial' 
 ) -o grub.img configfile biosdisk part_msdos part_gpt ext2 \
   linux test serial halt minicmd cat

And start your VM with:

kvm -kernel grub.img -hda yourdisk.img -nographic

From the grub prompt, load the kernel from the disk passing console=ttyS0... option or equivalent on the system you're booting to have the console on serial. Remember to add a getty on the serial line as well.

Assuming you're running Linux in the VM, you can then update its grub config to display on serial and boot a kernel with serial console, and then you can boot your image disk directly without that grub.img.

To access the qemu "monitor", type Ctrl-Ac (where you can add/remove devices...).

You can have the serial port as a unix domain or TCP socket, instead of stdio if you like as well. Same for the qemu "monitor" interface.

Now, provided you have the sgabios.bin firmware, and that your VM doesn't use graphics (just VGA BIOS text output), you can also just use the -curses option:

kvm -hda yourdisk -curses

The VGA console is then shown in your terminal. If you need to access the qemu monitor, press Alt-2.


VirtualBox-es can be controlled from the terminal, via VBoxManage. The VirtualBox GUI is just an alternative, graphical client.


VirtualBox works perfectly without the GUI. I have used it on the server side a lot. The VirtualBox GUI is just a well-decoupled convenience client tool. You can create and configure a VirtualBox machine using just console commands (almost as easily as with the GUI - there is nothing hard to learn/understand there, no new concepts and the command (VBoxManage) parameters reference and the examples are easy to google), attach an OS CD or a pre-built virtual hard drive image that would boot and start an SSH server then connect with SSH and do whatever you want.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.