Welcome to our Knowledge Base

High Availability using Proxmox™

Reading Time: 6 min

Another way to have a high-availability environment we have studied is using Proxmox™ VE. 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, into a single platform. With the built-in web-based user interface, you can manage virtual machines and containers, high availability for clusters, or the built-in disaster recovery tools with ease. You can explore Proxmox as an option to create your HAPBX instances in your local data center infrastructure.

To start using Proxmox VE for an HA environment, there are some prerequisites that need to be fulfilled.

  • System Requirements
  • For production servers, high-quality server equipment is needed. Proxmox VE supports clustering, which means that multiple installations of Proxmox VE can be centrally managed thanks to the built-in cluster functionality. Proxmox VE can use local storage such as (DAS), SAN, and NAS, as well as shared and distributed storage (Ceph).
  • Recommended Hardware
  • CPU – Intel EMT64 or AMD64 with Intel VT/AMD-V CPUs running at 3.5 GHz.
  • Memory – At least 4 GB for OS services and Proxmox VE. More memory needs to be designated for guests. For Ceph or ZFS additional memory is required, approximately 1GB of memory for every TB of storage used.
  • Fast and redundant storage – Better results with SSD drives.
  • OS storage – Hardware RAID with battery-protected write cache (“BBU”) or non-RAID with ZFS cache and SSD.
  • VM storage – For local storage, use hardware RAID with battery-backed write cache (BBU) or no RAID for ZFS. Neither ZFS nor Ceph supports a hardware RAID controller. Shared and distributed storage is also possible.
  • Redundant Gigabit NICs – Additional NICs depending on preferred storage technology and cluster configuration: 10 Gbit and higher are also supported.
  • For PCI(e) pass-through – a CPU with CPU flag VT-d/AMD-d is required.
  • For Testing (Minimal Hardware for Testing Only)
  • CPU – 64-bit (Intel EMT64 or AMD64)
  • Motherboard – Intel VT/AMD-V compatible CPU/motherboard (for full KVM virtualization support)
  • Memory – Minimum 2 GB of RAM
  • Storage – 500GB HDD
  • Network – One Gigabit NIC

Additionally, we are going to need an NFS Storage system. For this, in this example, we are going to be using another server to work as a NAS server.

With these prerequisites fulfilled, we can proceed to install Proxmox VE.

Proxmox needs a clean hard drive because it will remove all partitions and data from the hard drive during installation.

First, download Proxmox VE’s ISO image from Proxmox’s official website, https://proxmox.com/en/downloads/category/iso-images-pve.

If you are going to install it on physical hardware, you must flash the ISO image on a USB drive of at least 8GB. We recommend the Balena Etcher software, https://www.balena.io/etcher/.

Afterward, we can install Proxmox VE on dedicated hardware using the USB drive. Once we boot into the image we will be greeted with the following screen.

Select the Install Proxmox VE option, and press Enter. After a few seconds, the EULA will appear. Click on the I agree button.

Afterward, you must select the hard disk where you want to install Proxmox. Once selected,
click on Next.

On the next screen, enter your location, time zone, and language. Then click on Next.

Now you must enter the password for the root user which is used both in the Proxmox web interface and in the server console via SSH. Since this is a very sensitive user, we recommend a fairly complex password.

For the Email address, you can use any email address of your liking. Click on Next.
Afterward, we must enter our Networking configurations.

  • Management Interface – Select the interface through which we will manage
    Proxmox.
  • Hostname (FQDN) – A valid FQDN is recommended. For local testing, we will use
    a .local domain.
  • IP Address (CIDR) – Enter the IP address for the Proxmox server, using the CIDR
    format for the netmask.
  • Gateway – Enter the default gateway for the Proxmox server.
  • DNS Server – Enter the IP address for a DNS server to solve for server names. i.e.
    8.8.8.8

Once the network has been configured, click on Next.
Finally, you will be presented with a summary of your installation configurations. Verify the information and click on Install.

The installation will proceed and may take a few minutes depending on your hardware.

Once the installation is done, enter the IP Address plus the port 8006 on your browser, i.e. 192.168.20.220:8006.

Another option to install Proxmox is by installing a minimal installation of Debian. For this, you can follow the Debian installation instructions in Section 1, Lesson 1. During the installation, set the hostname for your Proxmox installation. Later we will show you the scheme we used for our example.

Once you have Debian installed, make sure you have SSH and WGET installed.

root@debian:~# apt-install -y ssh wget

Then, make the root user available to log in via SSH, using nano.

root@debian:~# nano /etc/ssh/sshd_config

Go to the following line.

#PermitRootLogin prohibit-password

Change it to

PermitRootLogin yes

Save and Exit nano.

Next, we must set the static IP address for this server using nano.

root@debian:~# nano /etc/network/interfaces

Go to the following line.

iface eth0 inet dhcp

Change it to the following content.

iface eth0 inet static

address 192.168.20.220

netmask 255.255.255.0

gateway 192.168.20.1

dns-nameservers 8.8.8.8 8.8.4.4 1.1.1.1 1.1.0.0

Save and Exit nano.

Note: Your interface name and IP Address will vary from these instructions. This information is based on the scheme we present later. Make sure that you are using the interface name and appropriate IP Address for your environment.

Now, we must make changes to the hosts file so the hostname resolves the server IP Address. Use nano to modify the hosts file.

root@debian:~# nano /etc/hosts

Go to the following line.

127.0.1.1 prox1.HAPBX.local prox1

Change it to the following.

192.168.20.220 prox1.HAPBX.local prox1

Save and Exit nano. You can check your configurations with the following command.

root@debian:~# hostname –ip-address

With this setup, we must add the Proxmox VE repositories. Run the following command.

root@debian:~# echo “deb [arch=amd64] http://download.proxmox.com/debian/pve bullseye pve-no-subscription” > /etc/apt/sources.list.d/pve-install-repo.list

Next, add the Proxmox repository key as root.

For Debian 11.

root@debian:~# wget https://enterprise.proxmox.com/debian/proxmox-release-bullseye.gpg -O /etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg 

# verify

sha512sum /etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg 

7fb03ec8a1675723d2853b84aa4fdb49a46a3bb72b9951361488bfd19b29aab0a789a4f8c7406e71a69aabbc727c936d3549731c4659ffa1a08f44db8fdcebfa  /etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg

For Debian 12.

root@debian:~# wget https://enterprise.proxmox.com/debian/proxmox-release-bookworm.gpg -O /

etc/apt/trusted.gpg.d/proxmox-release-bookworm.gpg 

# verify 

sha512sum /etc/apt/trusted.gpg.d/proxmox-release-bookworm.gpg 

7da6fe34168adc6e479327ba517796d4702fa2f8b4f0a9833f5ea6e6b48f6507a6da403a274fe201595edc86a8446

3d50383d07f64bdde2e3658108db7d6dc87 /etc/apt/trusted.gpg.d/proxmox-release-bookworm.gpg

Afterward, update the repository and system by running the following command.

root@debian:~# apt update && apt full-upgrade

Then, install the Proxmox kernel.

For Debian 11.

root@debian:~# apt install pve-kernel-5.15

For Debian 12.

root@debian:~# apt install pve-kernel-6.2

Reboot the system.

root@debian:~# systemctl reboot

Once the system has rebooted, install the Proxmox packages using the following command.

For Debian 11.

root@debian:~# apt install proxmox-ve postfix open-iscsi

For Debian 12.

root@debian:~# apt install proxmox-ve postfix open-iscsi chrony

Then, remove the original Linux Kernel.

For Debian 11.

root@debian:~# apt remove linux-image-amd64 ‘linux-image-5.10*’

For Debian 12.

root@debian:~# apt remove linux-image-amd64 ‘linux-image-6.1*’

Afterward, update the GRUB.

root@debian:~# update-grub

The os-prober package will scan all the partitions to create dual-boot GRUB entries. This can include the ones assigned to virtual machines, which we don’t want to add a boot entry. If you didn’t install Proxmox as a dual-boot with another OS, it is recommended to remove the os-prober package using the following command.

root@debian:~# apt remove os-prober

Finally, reboot the system using the following command.

root@debian:~# reboot

Once the system reboots, go to the Proxmox IP Address using port 8006 on your browser, i.e. 192.168.20.220:8006. Here, login using the root user and password.

Go to Datacenter > Your Proxmox node > System > Network, and click Create. Here, create a Linux Bridge and call it vmbr0. Add the IP Address of your server with the netmask in CIDR format, the gateway, and enter the network interface name under the Bridge port. Then click OK.

Was it helpful for you ?
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x