User Tools

Site Tools


pi5_proxmox

Proxmox on Raspberry Pi5

This is a little summary on how to setup an run VMs using Proxmox on a NVMe

Resources

First of all, install Raspberry Pi OS as you would normally using Pi Imager or alike

NVMe setup

Edit /boot/config.txt and add the following lines.

/boot/config.txt
# Enable NVME
dtparam=nvme

This will enable the NVMe and it will be list after reboot (sudo reboot)

 $ lsblk 
NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTS
mmcblk0     179:0    0  59.5G  0 disk 
├─mmcblk0p1 179:1    0   512M  0 part /boot/firmware
└─mmcblk0p2 179:2    0    59G  0 part /
nvme0n1     259:0    0 931.5G  0 disk 
├─nvme0n1p1 259:1    0   512M  0 part 
└─nvme0n1p2 259:2    0   931G  0 part 

Install rpi-clone

Now, that we have the NVMe up and running it is time to copy the OS from the SD-card to the NVMe using rpi-clone.

git clone https://github.com/geerlingguy/rpi-clone.git
cd rpi-clone
cp rpi-clone rpi-clone-setup /usr/local/sbin

Clone SD-card to NVMe

First, wipe all partitions before cloning the SD card:

umount /dev/nvme0n1p?
wipefs --all --force /dev/nvme0n1p1 
wipefs --all --force /dev/nvme0n1
dd if=/dev/zero of=/dev/nvme0n1 bs=1024 count=1

Finally clone the OS

rpi-clone nvme0n1

Change boot order to boot from NVMe

Run rpi-eeprom-config -e, change BOOT_ORDER and add PCIE_PROBE=1 or use raspi-config (Select Advanced Option → Boot Order → NVMe/USB Boot Boot from NVMe before trying USB and then SD Card)

BOOT_ORDER=0xf416
PCIE_PROBE=1

After another reboot, lsblk will look like this:

$ lsblk 
NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTS
mmcblk0     179:0    0  59.5G  0 disk 
├─mmcblk0p1 179:1    0   512M  0 part 
└─mmcblk0p2 179:2    0    59G  0 part 
nvme0n1     259:0    0 931.5G  0 disk 
├─nvme0n1p1 259:1    0   512M  0 part /boot/firmware
└─nvme0n1p2 259:2    0   931G  0 part /

Install Proxmox 8.1

Add Proxmox repo

echo 'deb [arch=arm64] https://mirrors.apqa.cn/proxmox/debian/pve bookworm port'>/etc/apt/sources.list.d/pveport.list
curl -L https://mirrors.apqa.cn/proxmox/debian/pveport.gpg -o /etc/apt/trusted.gpg.d/pveport.gpg 

Install packages

apt update && apt full-upgrade
apt install ifupdown2
apt install proxmox-ve postfix open-iscsi

:!: Watch out :!:

During install you may have to decide wheather or not to change the pveport.list file. Simply keep the current installed version of the file.

Configuration file '/etc/apt/sources.list.d/pveport.list'
 ==> File on system created by you or by a script.
 ==> File also in package provided by package maintainer.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** pveport.list (Y/I/N/O/D/Z) [default=N] ? N # <---- Answer with N here!

Configure SSH

Allow the root user to login via SSH by adding the following line in /etc/ssh/sshd_config:

PermitRootLogin yes

Set a password for the root user:

passwd

Restart ssh

systemctl restart sshd

Network

In a regular Proxmox install this interface is created automatically. At least that was my experience. But on the Pi5, no interfaces files existed. Neither /etc/network/interfaces nor /etc/network/interfaces.d/*. So i had to create it manually

  • Comment source
  • Add static IP for eth0
  • Create vmbr0 bridge interface
/etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
# Include files from /etc/network/interfaces.d:
#source /etc/network/interfaces.d/*
 
auto lo
iface lo inet loopback
 
#auto enp1s0
#iface enp1s0 inet dhcp
#iface enp1s0 inet static
iface eth0 inet manual
 
auto vmbr0
iface vmbr0 inet static
    address 192.168.178.26/24
    gateway 192.168.178.1
    bridge-ports eth0
    bridge-stp off
    bridge-fd 0

Restart network after creating the interfaces file

systemctl restart networking.service

Proxmox is now available under https://192.168.178.26:8006

Login

Proxmox uses system accounts. So you have to set the root users password using passwd when logged in as root (sudo -i)

Required VM settings, otherwise it won't boot

When you get “display output is not active” in console it might indicate that you need to change the settings as described below.

Select the VM to be configured. Click on “Hardware”

  • CD/DVD Drive: select a ISO file (arm64 images required)
  • BIOS: OVMF (UEFI)
  • Machine: Default (virt)
  • Add → EFI Disk, select “local”

Hardware settings

Add EFI Disk

pi5_proxmox.txt · Last modified: 2024/05/05 10:44 by admin