1

I'm using a virtual machine running Windows for development purposes inside a Ubuntu host (I also use the Ubuntu part for my regular activities, but not both at the same time). As I need to compile on Windows regularly, I want to increase the performance of the VM as much as I can. Therefore I want to use a "minimal" version of my desktop environment: if possible, I want only my VM running, in fullscreen. Is it possible to use such a minimal system? If yes, what is it, or how can I achieve this setup myself? An environment chooser on my login screen would be great, but optional.

0

Programs that aren't doing anything will get swapped out. So you don't need to go for minimalistic on RAM usage.

Do avoid background programs that aren't paused waiting for user input. For example, don't open a web browser that automatically refreshes some pages, or an email client that checks for incoming messages periodically.

One reason to look for a minimalistic window manager is to let the virtual machine get all key presses: a window manager that reserves keyboard shortcuts like Alt+Tab can be annoying if your VM doesn't grab the keyboard. Conversely, if your VM does grab the keyboard in a convenient way, this isn't a concern.

Ubuntu comes with oodles of minimalist window managers out of which choice is a matter of personal preference. I'm not going to list them all. I personally use Sawfish, which is not minimalistic, but still small compared to modern desktop environments, and is extremely flexible (it's programmable in a Lisp dialect).

On the display manager (the program where you log in in graphical mode), you can choose between session types. Ubuntu lacks a “custom” session type out of the box, but you can tie your minimal session to the small window manager of your choice or define a custom session type. Alternatively, you can log in to text mode (press Ctrl+Alt+F1 to switch to a text console, Ctrl+Alt+F7 to go back to the GUI login screen or the session started there) and run the command startx to start a session, e.g.

startx -- :1

which runs the file ~/.xinitrc (typically a shell script where you start whatever you want in your session). If you want to run only the VM emulator and nothing else, you can pass its full path to startx plus command line options, e.g.

startx /usr/bin/vm-run 'My VM' -geometry 1920x1080+0+0

but note that without a window manager, you won't be able to do so much as resize a window.

0

A lighter DE is certainly an easy way to free up system resources for a VM.

Depending on how light you need/want to go, will guide what DE to choose. Have you looked at the MATE or XFCE desktop? they are both full featured DEs and will run significantly lighter than Unity, and are simple to setup in a basic Ubuntu installation.

If you need to go lighter, you can begin to look at tiling WMs like i3, but you'll be giving up some of the feature-set of the other DEs.

  • I haven't tried MATE nor XFCE yet, because I was not sure if that's time well spent. I'll try that, though. I don't need any DE-features except starting a GUI program (which is VirtualBox with already set parameters), then I will use its integrated full screen feature. Is i3 suitable for this? – Connor Lanigan Mar 4 '15 at 18:57
  • either choice is a good way to lower your primary OS's resource footprint, leaving more free to dedicate to your VM. – sam Mar 4 '15 at 18:58
  • Is there an option to go without a DE or WM? I'd then have a "one-program"-system, saving lots of resources. – Connor Lanigan Mar 4 '15 at 19:29
  • When Im looking for a low-overhead environment to do my work I use i3, which only has a 250~350 MB ram overhead. Its extremely light, and gives a minimal amount of environment for launching programs. At a minimum you'll need an X session and-the-like for launching virtualbox. Its hard for me to imagine a lighter environment than a tiling WM like i3. Just my $0.02 however – sam Mar 4 '15 at 19:40

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.