To install Workstation Player 14, VMware recommends(Vmware, n.d.) that you have the following: 1. An Intel CPU with VT-x support or an AMD CPU with AMD-V support. 2. 2 GB of RAM (4 GB or higher recommended) 3. A 16- or 32-bit display adapter 4. At least 1 GB of hard drive space
A list of these requirements can be found at the VMware Docs site.
To install Arch Linux, you must have an x64_86-compatible PC with at least 512MB of RAM and 800 MB of disk space available(Dario Giova, n.d.). Oh, and an active internet connection.
To download VMware Workstation Player 14.1, visit my.vmware.com and click on the link to download. This will download the file in a .bundle
package which must be installed from the command line. To run the installer in Linux, use the command
$sudo bash VMware-Player-*.x64_86.bundle
After this, an installer window will open asking if you accept their ToS/EULA. It will also ask for a path for system scripts, as well as a product key.
I installed VMware Workstation Player 14.1 on a system already running Arch Linux, and had to install vmware-patch to get player to detect my kernel.
Next we can get the Arch image.
To download the image file for installation, go to the Arch Linux Download page and select a mirror. (I chose the cat.pdx.edu mirror) Alternatively, you can download a torrent and get it from there, but don’t forget to seed.
To set up your virtual machine, start VMware Workstation player and hit create a new virtual machine. You will be prompted to chose where to install the operating system from, so hit the “Use ISO image” radio button and point to the Arch .iso you just downloaded. Next, you select “Linux”" and “Other Linux 4.x Kernel” from the dropdown. You’ll be prompted to select a location to store your VM and then you will have to chose how big the hard drive you want. I went with the default 8 GB but you can use however much space you would like, provided you have the storage to do so. You can keep the default for virtual disk splitting selected and then hit next.
Finally, you will be brought to a window that says “Ready to Create Virtual Machine”, but we aren’t. Select “Customize Hardware” and a new window will pop up, shown below:
Change the memory to the amount you want (remember, 512 MB is the bare minimum) and set the number of CPU to how many cores your host CPU has (if you are unsure, it’s okay to keep the value at 1). You can also click the Display tab and hit “3D Acceleration”.
Now you can hit close and finish the setup. Make sure you uncheck the “power on” selector before you finish, there’s one more step we need to accomplish before we get into things. Go to the folder that you selected to store your VM and open the xx.vmx
file with a text editor (Don’t double click it!). We’re going to add the line
firmware = "efi"
to the very bottom of the file and then save it.
Now you’re ready to power on the system. You can double click the file you just edited, or open it through VMware workstation.
Wait until the system loads the operating system splash screen, which will be similar to the one below:
Select Boot Arch Linux (x64_86)
and wait for the machine to load the installer from the .iso.
You will immediately be put into a command line interface. If this scares you, it shouldn’t. I will be here to guide you through the installation.
Type
$ ls /sys/firmware/efi/efivars
You can use tab completion after the first couple letters of each of the sub folders. If everything is done correctly, you should get an output similar to mine:
This means that you have EFI running. This is exactly what we want.
Next, we have to check that we have access to the internet. Type
$ ping -c www.google.com
If you don’t get any errors, you’re good to go.
Next, type
$ timedatectl set-ntp true
This will set the system clock.
The next part will be a little finicky. Type
$ lsblk
and you will get an output like this:
The drive that we want should be some form of sdX
where X
is a letter. In my case, it is sda
. This is the drive we want to partition. Type
$ cfdisk /dev/sda
and you will be brought to a partition wizard.
Select gpt
from the list (if asked) and then partition the hard drive. I like to have 4 seperate partions for an install:
Make sure that you select the proper filesystem types: Your boot partition should be Microsoft basic data, your swap should be Linux swap, and your home and root partitions should be Linux filesystem. You should have something like this when you’re done: Don’t forget to hit Write before you quit. Now if you type
$ lsblk
you should see
### Mounting the filesystem Let’s mount the filesystem next. Type out everything below, and we’ll meet on the other side and see how things went.
$ mkfs.vfat -F32 /dev/sda1
$ mkswap /dev/sda2
$ mkfs.ext4 /dev/sda3
$ mkfs.ext4 /dev/sda4
$ swapon /dev/sda2
We just set the file system to fat32 for the boot partition, swap on the swap partition, and ext4 for the root and home partitions. After that, we told the computer to use the swap partition as swap.
Now we can actually mount them:
$ mount /dev/sda3 /mnt
$ mkdir /mnt/boot
$ mkdir /mnt/home
$ mount /dev/sda1 /mnt/boot
$ mount /dev/sda4 /mnt/home
If everything went according to plan, you have the skeleton of your Arch install all set up. Now we can get into the actual nuts and bolts of the installation, and the hard part is over with. If we run our trusty $lsblk
, we should see
This is where the actual installation part comes into play. First, we need to edit our mirror to find the best one to download from. Point your browser to the Mirror Status page and select a mirror you want to use there. I like to go down to the part of the window that says Sucessfully Syncing Mirrors and then sort the list by highest mirror score. Then I select the highest scoring mirror that is near me. Your mileage may vary.
I am going to use a mirror in the United States, clarkson.edu. To use this mirror, you need to edit /etc/pacman.d/mirrorlist
so that the mirror is at the type. type
$ nano /etc/pacman.d/mirrorlist
and then add Server = http://mirror.clarkson.edu/archlinux/$repo/os/$arch
to the top of the list, above ## China
.
Hit Ctrl + x
to save, follow the prompts and quit. Now we can finally install Arch!
Now that we’ve edited the mirror list, we can install Arch. Type
$ pacstrap -i /mnt base base-devel
and hit enter. You will be prompted to make some choices, just hit enter to accept the defaults and then hit y. The files will begin to download and install, so sit back, grab something to drink, do whatever. It might take a little while.
And all the heavy lifting is done! Let’s generate our filesystem table
$ genfstab /mnt >> /mnt/etc/fstab
Now that we’ve generated the fstab, let’s take a look at it
$ nano /mnt/etc/fstab
If it looks similar to this, you’re good:
Now we need to set the OS up to be self-sufficient. First, we need to arch-chroot into the filesystem.
$ arch-chroot /mnt
First things first, let’s select a timezone and set the system clock:
$ ln -sf /usr/share/zoneinfo/America/New_York /etc/localtime
$ hwclock --systohc.
The first line sets a symbolic link between the time zone and your local time. You can use a different zone if you’re in a different area using the command tzselect
.
Now, edit the file /etc/locale-gen
to uncomment your language. I’m going to use en_US.UTF-8 UTF-8
, but you can use whatever you would normally use. Do this by typing
$ nano /etc/locale.gen
and then deleting the # before the one(s) you want to use.
Save and exit, and then type
$ locale-gen
to finalize the change.
Next, set the language variable in /etc/locale.conf
by typing
$ echo "LANG=en_US.UTF-8" >> /etc/locale.conf
We’re going to do something similar for our hostname. I’m choosing archVM
for my hostname, so I’ll type
$ echo "archVM" >> /etc/hostname
and for hosts we’ll type
$ nano /etc/hosts
and edit it so that it looks like this:
127.0.0.1 localhost
::1 localhost
127.0.1.1 archVM.localdomain archVM
Now we need to have systemd start the network connection on start up. To do this, type
$ systemctl enable dhcpcd.service
Let’s add a password to our root account by typing
$ passwd
and entering a password when prompted.
Finally, we need to install a bootloader.
I used to use a mac, and as a result I’m partial to rEFInd as a bootloader. To install this, we have a couple steps. First, type
$ pacman -S refind-efi
and accept the prompts when they come up.
Once this installs, we can type
refind-install
and we should get the output below:
As a final step, we need to edit /boot/refind_linux.conf
because when the install script populated it, it was populated with the values for the .iso and not our boot disc. To edit that, you need to change the file
$ nano /boot/refind_linux.conf
Basically, where you see the part that says something like ro root=UUID-...-6d73ae6b5332
, it needs to be placed on the line "boot with standard options"
and the other two need to be deleted. Also, replace the ro
with rw
. When all is said and done, you should have something that looks like this:
save your changes, you’re in the home stretch!
Now that we’re done, we can exit arch-chroot
and finish our install.
$ exit
You’ll be kicked out of chroot jail, and ready to leave the installer limbo. Type
$ umount -R /mnt
You shouldn’t have any errors at this point. If you do, there’s a chance you left the /root
directory when you were in chroot. To fix this you can just $arch-chroot /mnt
back in, type $ cd
, and then $ exit
and try again. At this point, you’re finished with installing. Type
$ reboot
and cross your fingers; with any luck you’ll see
Push enter and rEFInd will load into the OS. You’ll be greeted with this screen:
Congratulations! You just installed Arch Linux in a VM!
Dario Giova, et al, Jakub Klinkovský. n.d. “Arch Linux Installation Guide.” https://wiki.archlinux.org/index.php/Installation_guide.
Vmware, Inc. n.d. “Host System Requirements for Workstation Player.” https://docs.vmware.com/en/VMware-Workstation-Player-for-Linux/14.0/com.vmware.player.linux.using.doc/GUID-3CF87F1D-FD14-4FBA-A00C-F13D65825CA5.html.