Home · Linux · Vim · Programming · Trees · Quests

Arch Server build in VirtualBox VM

Creating an Arch install to use as a server sandbox.

Prerequisites:

  1. Install VirtualBox.
  2. Download the Arch ISO.
  3. Create a new VirtualBox VM and select Arch Linux 64 as the OS.
  4. Attach the Arch ISO to the VM’s optical drive.
  5. Start the VM.

Installation steps

Configure server access

LEMP stack install

# pacman -S nginx php mariadb php-gd php-fpm
# systemctl enable nginx
# systemctl start nginx
# mariadb-install-db --user=mysql --basedir=/usr --datadir=/var/lib/mysql 
# systemctl enable mariadb
# systemctl start nginx
# systemctl enable php-fpm
# systemctl start php-fpm

Note that mariadb can now be run with with sudo using root user and empty password.

Getting back into rescue mode w/ ISO

If you screw up along the way and want to try and fix things instead of starting over from scratch, you can get back into the Arch live environment by doing this:

  1. Reboot the VM with the Arch ISO attached to the optical drive.
  2. mount /dev/sda1 /mnt
  3. arch-chroot /mnt