Zir Blazer's Guide to installing Arch Linux and Xen

zir_blazer

Golden Member
Jun 6, 2013
1,150
389
136
Chances are that *nix Software could be a better place to put this, but on Operating Systems more people may actually notice this Thread. It is not exactly restricted to Linux.


What is this all about? The core idea is that instead of relying on Windows always running on bare metal, you can attempt to replace it with a permanent Hypervisor layer. Once you get everything virtualized, this essencially allows more freedom and flexibility on the OS of choice, since the Hypervisor layer serves for transitions and resource distribution. The advantages against traditionals VMMs like VirtualBox is that you don't rely on a full blown host OS, and can potentially dedicate Hardware resources to a VM, like for example, giving a Windows VM a full Video Card to play games with. This sort of setup is somewhat popular for people with big Workstations that want to do complex all-in-one systems, as this potentially allows for multiseat setups, and other neat ideas if you're inventive, with everything isolated in a VM with a defined purpose.

A year or so ago I had done a near identical guide in spanish, to make installing Xen more accessible to hispanic people. However, I figured out that pretty much everyone which was interesed in it, didn't had the proper Hardware to try Passthrough, and anyone who does, should have no issues understanding english in the first place, so my efforts weren't worth it. I didn't initially thought of doing it in english since there were already some quite complete guides, but they were for other Linux distros, and at this point, they're a bit dated, so I missed most of the possible spotlight for not choosing the correct language:

Dizzy guide for Fedora:
http://www.overclock.net/t/1205216/guide-create-a-gaming-virtual-machine/
powerhouse guide for Linux Mint:
http://forums.linuxmint.com/viewtopic.php?t=112013
Teo En Ming guide for Ubuntu: Somewhere at xen-users Mailing List
I think I forgot another one.

Zir Blazer's "Me too" guide for Arch Linux: http://pastebin.com/rzqw6Vfa

Part of the idea is to not make a guide that is "install this, do that", but something that you can learn criteria from. So the end result is that my guide is totally biased, well, on how I do things.

What to expect:

- It is a 135 KiB wall of text, approaching binary blob complexity. In order to understand it, you may need to reverse engineer it.
- It is totally biased on my criteria and usage style.
- It is politically incorrect, since I'm sitting on the root user all the day and most Linux users seems to not like that. But if you follow my guide, you will do it, too!
- It may be factually incorrect, since there are a few things which I may have explained wrong
- It is incomplete, since there are some things that I still didn't learned how to do, so I can't explain. An example is a lot of Openbox related config
- It is inconsistent, since some things I explain as detailed as I can, while I skip doing so totally in other areas
- It is in engrish, since I didn't did a slowly paced read to figure out that all the syntaxis and verbs are correct. Try to look around for memetizable "All your base belong to us" phrases.
- I rushed it to completion, since I wanted to publish it ASAP and get some feedback to see if it is worth continuing it or not. You can notice it near the end.
- It doesn't includes any Passthrough instructions at all!

The guide at the current stage is a sort of rollercoaster, but if you follow it carefully, will take you in a walkthrough style from an empty Hard Disk to a functional Arch Linux Dom0 with Xen 4.5 installed, with two simple exercises at the end that includes creating VMs with no storage to see that SeaBIOS and OVMF boots. There are also some mention on how to create a VM to test a nested Xen, so you can try my guide in a Xen VM (Which is what I did to make sure it works).

TO DO:

- Make it more consistent and easily readable. Could be useful to try to migrate it to a Wiki with screenshots.
- I missed everything related to SPICE. The qxl VGA driver should be extremely useful. Also, I don't use VNC at all, just SDL. So it is lacking in remote management.
- Adding Passthrough instructions (Is not that checking the PCI Address of a device with lspci, adding a line for xen-pciback in the Boot Loader config file, and adding the pci line in the DomU config file is THAT hard if you survived to the end)
- Adding instructions to enable Xen debug, since as the Arch Linux install I use is quite minimal, it makes for an excellent debug platform for Passthrough, as you have less variables. I expect that I can make out of this guide an standarized procedure to make a setup to get logs from in case of regressions.


What I need the most, is knowing if someone actually learned something out of it, or better yet, setup a test system. While the main feature is VGA Passthrough so you can play games in a VM effectively eliminating the need to run Windows native, during the year I had this guide published in spanish, only a single person tried Xen, as a replacement for VirtualBox to host two server VMs which he manages remotely. So basically, you can check it as a reference guide then figure out what you want to do with the base install.