Hypervisors
Virtualization is the key to the future
Proxmox
Proxmox VE is a complete, open-source server management platform for enterprise virtualization. It tightly integrates the KVM hypervisor and Linux Containers (LXC), software-defined storage and networking functionality, on a single platform. With the integrated web-based user interface you can manage VMs and containers, high availability for clusters, or the integrated disaster recovery tools with ease.
Linux
INSTALLATION REQUIREMENTS
Workflow Time: 30 minutes
Hardware: Desktop/Sever, sd/usb drive {removable}, usb/hhd/ssd/m.2 {internal}
Software: etcher, Ubuntu 22.0.4-server.iso
Network: ensure router/gateway has fixed ip for system
SSH PRELAB
sudo su # switch to root stops from putting in sudo password all the time
passwd # update root password
apt update && apt upgrade -y # grabs fresh repository list and then upgrades packages without yes prompt
{ SKIPPED } apt install curl # already installed check by running curl --help
{ SKIPPED } nano /etc/dhcp # manual assign ip address from router/gateway
curl -L https://mirrors.apqa.cn/proxmox/debian/pveport.gpg | sudo tee /usr/share/keyrings/pveport.gpg >/dev/null
echo "deb [deb=arm64 signed-by=/usr/share/keyrings/pveport.gpg] https://mirrors.apqa.cn/proxmox/debian/pve bookworm port" | sudo tee /etc/apt/sources.list.d/pveport.list
apt update && apt dist-upgrade -y && apt autoremove -y # grab another fresh copy since we added to repository list
nano /etc/hosts # > remove 3 lines of ipv6 > add assigned ip address [ 192.168.X.X PROXMOX ]
apt install ifupdown2 -y # installs required package for proxmox to handle network interface
apt install proxmox-ve postfix open-iscsi pve-edk2-firmware-aarch64 -y # installs Proxmox VE from arm64
Raspberry Pi 5
This turtorial is for installing a fully functional (dashboards and onboard NIC) Proxmox VE on a Raspberry Pi 5 "ONLY" and should not be considered a reliable document for any other Raspberry Pi models. Proceed at your own risk!!!
SOURCE-1 | https://pimylifeup.com/
SOURCE-2 | https://www.reddit.com/r/raspberry_pi
INSTALLATION REQUIREMENTS
Workflow Time: 30 minutes
Hardware: Raspberry Pi 5, sd/usb drive
Software: raspberry pi imager, install raspberry Pi OS Light (64-bit)debian-bookworm
Network: ensure router/gateway has fixed ip for pi
NGINX
- Domain Names: | prox.example.com
- Scheme: | https
- Host/Ip: | 192.168.X.XX
- Fwd Port: | 8006
- Block Explo: | true
- Web Socks: | true
- SSL
- Wildcard cert
- Force SSL: | false
- HTTP/2 : | false
- Post install
nano /etc/hosts> 192.168.X.XX prox.example.com PROXMOXreboot -f nowhostname -f| should return prox.example.com
- SSL
SSH PRELAB
sudo su # switch to root stops from putting in sudo password all the time
passwd # update root password
apt update && apt upgrade -y # grabs fresh repository list and then upgrades packages without yes prompt
{ SKIPPED } apt install curl # already installed check by running curl --help
{ SKIPPED } nano /etc/dhcp # manual assign ip address from router/gateway
curl -L https://mirrors.apqa.cn/proxmox/debian/pveport.gpg | sudo tee /usr/share/keyrings/pveport.gpg >/dev/null
echo "deb [deb=arm64 signed-by=/usr/share/keyrings/pveport.gpg] https://mirrors.apqa.cn/proxmox/debian/pve bookworm port" | sudo tee /etc/apt/sources.list.d/pveport.list
apt update && apt dist-upgrade -y && apt autoremove -y # grab another fresh copy since we added to repository list
nano /etc/hosts # > remove 3 lines of ipv6 > add assigned ip address [ 192.168.X.X PROXMOX ]
apt install ifupdown2 -y # installs required package for proxmox to handle network interface
apt install pve-edk2-firmware -y # vm qemu-guest-agent will break without
apt install proxmox-ve postfix open-iscsi pve-edk2-firmware-aarch64 -y # installs Proxmox VE from arm64
PROXMOX OOBE WIZARD
mail server > local only
mail name > PROXMOX
keep or update dependancy list > default N
STORAGE CONFIG
You can either make a directory on host or mount external storage (RECOMMENDED). We will first create partions on the storage device then mount to directory on host.
sudo su # switch to root
mkdir -p mnt/prox/images # -p {creates all paths to target}
mkdir -p mnt/prox/containers # -p {creates all paths to target}
df -h # display any connected storage { OPTIONS } lsblk | fdsik -l
# CREATE FIRST PARTITION
fdisk /dev/nvmeXXX
> n (new partition) > 1 (primary) > default start > default end (+20G) > remove drive sig Y > w (write partition table)
mkfs.ext4 /dev/nvme0n1p1 # change partition(1) type to ext4
# CREATE SECOND PARTITION
fdisk /dev/nvmeXXX
> n (new partition) > 2 (primary) > default start > default end (+XXG) > remove drive sig Y > w (write partition table)
mkfs.ext4 /dev/nvme0n1p2 # change partition(2) type to ext4
#[temp mount until reboot]
mount /dev/nvme0n1p1 mnt/prox/images
mount /dev/nvme0n1p2 mnt/prox/containers
#[perm mount post reboot]
blkid # get partition PARTUUID
echo "PARTUUID=ef1712a1-XXXX-1234-a5dc-86f7d6f7273b /mnt/prox/images ext4 defaults,nofail,noatime,errors=remount-ro 0 0" >> /etc/fstab
echo "PARTUUID=ef1712a1-YYYY-5678-a5dc-86f7d6f7273b /mnt/prox/containers ext4 defaults,nofail,noatime,errors=remount-ro 0 0" >> /etc/fstab
nano /etc/fstab # confirm both lines are present
reboot -f now
# post reboot
df -h #should show both partions/size/usage/mnt(location)
Now that we have to locations permenantly mapped we can use the Proxmox UI to point all image downloads and container creations to the respective locations on host.
- Datacenter
Storage:
Add: Directory
ID: images
Directory: /mnt/prox/images
Content: Disk image, ISO image
ADD
Storage:
Add: Directory
ID: containers
Directory: /mnt/prox/containers
Content: Disk image
ADD
NET CONFIGURED IN PROXMOX UI
Select first node under Datacenter > System > Network
Edit eth0 > AutoStart True > OK
Create Bridge > vmbr0 > AutoStart True > IPv4 192.168.X.X/24 > Gateway gateway 192.168.X.1 > BridgePorts eth0 > OK >> Apply Configuration (Active)
reboot -f now
POST INSTALL
visit https://proxmox.local:8006
login user:root pass:{{prelab}}
Orange Pi 5/Plus/Pro
This turtorial is for installing a fully functional (dashboards and onboard NIC) Proxmox VE on a Orange Pi 5 "ONLY" and should not be considered a reliable document for any other Device or models. Proceed at your own risk!!!
INSTALLATION REQUIREMENTS
Workflow Time: 30 minutes
Hardware: Orange Pi 5/Plus/Pro, sd/emmc/m.2, USB-A male to male cable (pin2pin data)
Software: orange pi flash tool/drivers google drive, latest orange pi 5 Debian Server build google drive
Network: ensure router/gateway has fixed ip for pi
Debian Server Install
- Unzip Debian image and rename Orangepi5pro_1.0.0_debian_bookworm_server_linux5.10.160.img > Opi5proDebian.img (short name allows you to see progress %)
- Unzip and install driver assistant (windows warning trust at your own risk)
- Unzip and run RKDevTool (make note of miniloader config folder)
- Attach media (sd/emmc/m.2) to orange pi
- Ensure male to male cable is plugged into PC and the top blue (flash) port on pi
- While holding down maskrom button on device plug in/toggle power then release maskrom button
- Bottom of RKDevTool should switch to "MASKROM" (if not power down and try again)
- (following guide)
-Right click in list area
-Select "Import Configuration" (second to bottom)
-Select the "rk3588_linux_XXXXX.cfg" file from the miniloader folder (spiflash/emmc/sata)
-Confirm "Yes"
-First list item far right space click and select "MiniLoaderAll.bin" and click Open
-Second list item far right space click and select "Orangepi5.img" and click Open
-Check box for "Force writing by address | True
-Button right above check box is "Execute" (progress shown in right plane)
SSH PRELAB
sudo su # user/pass orangepi/orangepi switch to root stops from putting in sudo password all the time
passwd # update root password
apt update && apt upgrade -y # grabs fresh repository list and then upgrades packages without yes prompt
{ OPTIONAL } orangepi-config # git rid of annoying LED | System > Hardware > opi5XXX-disable-leds
{ SKIPPED } apt install curl # already installed check by running curl --help
{ SKIPPED } nano /etc/dhcp # manual assign ip address from router/gateway
curl -L https://mirrors.apqa.cn/proxmox/debian/pveport.gpg | sudo tee /usr/share/keyrings/pveport.gpg >/dev/null
echo "deb [deb=arm64 signed-by=/usr/share/keyrings/pveport.gpg] https://mirrors.apqa.cn/proxmox/debian/pve bookworm port" | sudo tee /etc/apt/sources.list.d/pveport.list
apt update && apt dist-upgrade -y && apt autoremove -y # grab another fresh copy since we added to repository list
nano /etc/hosts # > remove 5 lines of ipv6 > add assigned ip address [ 192.168.X.X PROXMOX ]
apt install ifupdown2 -y # installs required package for proxmox to handle network interface
apt install proxmox-ve postfix open-iscsi pve-edk2-firmware-aarch64 -y # installs Proxmox VE from arm64
PROXMOX OOBE WIZARD
mail server > local only
mail name > PROXMOX
keep or update dependancy list > default N
NET CONFIGURED IN PROXMOX UI
Select first node under Datacenter > System > Network
Edit eth0 > AutoStart True > OK
Create Bridge > vmbr0 > AutoStart True > IPv4 192.168.X.X/24 > Gateway gateway 192.168.X.1 > BridgePorts eth0 > OK >> Apply Configuration (Active)
reboot -f now
Virtual Machine
SOURCE | https://forum.proxmox.com/threads/guide-install-home-assistant-os-in-a-vm.143251/
Homeassistant has a predefined method as follows:
Obtain the VM image
Download an aarch64 qcow2 from github: GITHUB HA REPO, or Navigate to the installation page on the HA website: https://www.home-assistant.io/installation/alternative
-
Simply right-click the KVM/Proxmox link and copy the address
-
In your Proxmox console, use wget to download the file
wget <ADDRESS>
- Expand the compressed image
unxz </path/to/file.qcow2.xz>
Create the VM
General:
- Select your VM name and ID
- Select 'start at boot'
OS:
- Select 'Do not use any media'
System:
- Change 'machine' to 'q35'
- Change BIOS to OVMF (UEFI)
- Select the EFI storage (typically local-lvm)
- Uncheck 'Pre-Enroll keys'
Disks:
- Delete the SCSI drive and any other disks
CPU:
- Set minimum 2 cores
Memory:
- Set minimum 4096 MB
Network:
- Leave default unless you have special requirements (static, VLAN, etc)
Confirm and finish. Do not start the VM yet.
Add the image to the VM
- In your node's console, use the following command to import the image from the host to the VM
qm importdisk <VM ID> </path/to/file.qcow2> <EFI location>
For example,
qm importdisk 205 /home/user/haos_ova-12.0.qcow2 local-lvm
-
Close the node's console and select your HA VM
-
Go to the 'Hardware' tab
-
Select the 'Unused Disk' and click the 'Edit' button
-
Check the 'Discard' box if you're using an SSD then click 'Add'
-
Select the 'Options' tab
-
Select 'Boot Order' and hit 'Edit'
-
Check the newly created drive (likely scsi0) and uncheck everything else
Finish Up
-
Start the VM
-
Check the shell of the VM. If it booted up correctly, you should be greeted with the link to access the Web UI.
-
Navigate to
<VM IP>:8123
Done. Everything should be up and running now.
Ensure Datacenter is selected in Server View panel
Press the Create VM button
- General
VM ID: 1XX
Name: HAOS
Arch: aarch64
Start at boot: check - OS
Do not use any media - System
BIOS: OVMF (UEFI)
EFI Storage: local/HIVE
Qemu Agent: check - Disks
Delete: scsi0 - CPU
Cores: 2 - Memory
Memory: 4096MB - Network
Bridge: vmbr0
VLAN Tag: 2/3/4
Model: Virl0 (paravirtualized)
Firewall: check - Confirm
Start after created : false
Container
Ensure Datacenter is selected in Server View panel
Press the Create CT button
- General
Hostname: panel
Password: passwrd123
Unprivileged: true | default {{ true }}
Nesting: true | default {{ true }} - Template
Storage: local
Template: Ubuntu-jammy-arch-XXXX-XX-XX.tar.xz - Disks
Storage: local
Disk size: 4GB | default {{ 8 }} - CPU
Cores: 1 - Memory
Memory: 2048MB | default {{ 512 }}
Swap: 512MB - Network
Name: ethX
MAC: auto
Bridge: vmbr0
IPv4: DHCP - DNS
domain: blank | default {{ use host settings }}
servers: blank | default {{ use host settings }} - Confirm
Start after created : true
Examples
agent: 1
arch: aarch64
bios: ovmf
boot: order=scsi0;net0
cores: 2
cpu: host
efidisk0: local:100/vm-100-disk-0.qcow2,efitype=4m,size=64M
kvm: 1
machine: virt
memory: 4096
meta: creation-qemu=10.0.2,ctime=1761594240
name: HA
net0: virtio=BC:24:11:FF:F6:1C,bridge=vmbr0,firewall=1
numa: 0
onboot: 1
ostype: l26
scsi0: local:100/vm-100-disk-1.raw,discard=on,size=6G
scsihw: virtio-scsi-pci
smbios1: uuid=f7428f55-4cc7-441d-99b4-756a49523cd5
sockets: 1
uuid: 9e38775e-b2cb-4d81-8bcb-1642a9d681a4
VirtualBox
VirtualBox is a powerful x86 and AMD64/Intel64 virtualization product for enterprise as well as home use. Not only is VirtualBox an extremely feature rich, high performance product for enterprise customers, it is also the only professional solution that is freely available as Open Source Software under the terms of the GNU General Public License (GPL) version 3.
Extensions
The VirtualBox Extension Pack is a package that broadens the basic functionalities of VirtualBox. Allows physical USB devices usage in your virtual environment. Use the host webcam on a guest operating system, even if drivers are not available. Connect to a remote VM through the VirtualBox interface.https://www.virtualbox.org/wiki/Downloads
VMware ESXi
ESXi is a robust bare-metal hypervisor that installs directly onto your physical server. With direct access to and control of underlying resources, VMware ESXi effectively partitions hardware to consolidate applications and cut costs.
Download
Trouble Shooting
ALPINE LINUX SHELL IN A BOX MISSING
After spinning up an Alpine Linux LXC you may find the traditional way of installing Shell-In-Box and that is because Alpine does not provide it in the core apt repository.One-off install straight from edge/testing (keeps your system on stable)
apk add shellinabox \
--repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing
rc-update add shellinaboxd default
rc-service shellinaboxd start
# use prox/putty to add user
adduser {USERNAME}
LXC CAN NOT RESOLVE APT-UPDATE
Containers/Host can not resolve get-update urlsnano /etc/resolv.conf
search .
nameserver 1.1.1.1
reboot -f now # allow new dns settings to take affect for host and containers
PROXMOX SUBSCRIPTION NAG REMOVAL
1) Remove subscription nag { `NOT WORKING 5-1-2024` } curl https://raw.githubusercontent.com/foundObjects/pve-nag-buster/master/install.sh | sudo bash
- Use Docker containers in LXC enviro
a) Node > options > fuse=1,keyctl=1,nesting=1
apt install fuse-overlayfs -y
- Remove old node after hostname change
rm -rf /etc/pve/nodes/old-hostname/