Proxmox Virtual Environment (Proxmox VE) is an open-source server virtualization management platform that organizations of all sizes widely use. The latest version of Proxmox VE is 7.X, which offers a range of new features and improvements over its predecessor, Proxmox VE 5.X.
If you are currently running Proxmox VE 5.X, you might be interested in upgrading to the latest version, and it is recommended to do so because version 5.x and 6.x have come to End-Of-Life. I did this upgrade on a working Proxmox server at my organization and documented the steps involved. This blog will provide a step-by-step guide on upgrading your Proxmox VE 5.X installation to Proxmox VE 7.X.
Before we begin, it is essential to note that upgrading Proxmox VE is a complex process that involves several steps. The installers will affect your server’s uptime and significantly change the operating system’s underlying code. So it is highly recommended that you back up your Virtual machines and containers hosted on the Proxmox server or, for better, migrate temporarily to another Proxmox installation.
Upgradation of Proxmox 5.4 to Proxmox 6.4
The way I did it was to upgrade from 5.4.15. I had it in my production environment with working virtual machines, so I couldn’t afford any data loss. Still, upgrading was necessary for me. To keep things simple and under control, I decided to go with Step by Step upgrade. The first step in upgrading Proxmox VE 5.x to 7.x is to update the existing installation from 5.4.15 to version 6.x. I started that with the regular apt-get update and apt-get upgrade commands. Proxmox is based on Debian, so all Debian-style command syntax work.
Login into the proxmox terminal :
apt-get update
apt-get upgrade
These commands will update all the packages and dependencies on your Proxmox VE 5.X installation.
When moving from 5.x to 6.x the system would also need Corosync 3 Stretch. So add it here.
echo "deb http://download.proxmox.com/debian/corosync-3/ stretch main" > /etc/apt/sources.list.d/corosync3.list
Proxomox 5.4 is based on Debian Stretch 9.8, but Proxmox 6.4 is on Debian Buster (10.9), so let’s add Buster repositories to the apt source list. Give the following command to replace and add Debian Stretch repositories to Debian Buster.
sed -i 's/stretch/buster/g' /etc/apt/sources.list
echo "deb https://enterprise.proxmox.com/debian/pve buster pve-enterprise" > /etc/apt/sources.list.d/pve-enterprise.list sed -i -e 's/stretch/buster/g' /etc/apt/sources.list.d/pve-install-repo.list echo "deb http://download.proxmox.com/debian/ceph-luminous buster main" > /etc/apt/sources.list.d/ceph.list
After this, remember to comment out and disable the old buster repositories in the source list. After amendments to the source list, update the system with the apt-get update and apt-get upgrade commands.
apt-get update && apt-get upgrade -y
After the repository cache has been updated, give the following command to upgrade your Operating system fully.
apt dist-upgrade
This should take some time, depending on your internet connection and the speed of your Disk drive. Also, there will be multiple questions regarding upgraded software. You must approve some of the new packages replacing configuration files. They are not relevant to the Proxmox VE upgrade, so you can choose what you want to do.
After the dist-upgrade, it will ask to reboot the system with the following command.
reboot now
Upon reboot, you will be taken to the updated OS kernel of Proxmox 6.4. After the upgrade.
you may want to remove the obsolete packages with the following command
apt-get autoremove
and clean the apt cache with
apt-get clean
Upgradation of Proxmox 6.4 to Proxmox 7.3
Just like we did with Proxmox 5.4 to 6.4, we will have to repeat the same steps for upgrading to Proxmox 7.3.15, which is the latest as of writing this blog. With this major version upgrade, the OS Kernel will again go through a significant change since the Debian release is different. Proxmox 7.4 is Based on Debian Bullseye (11.5)
so let us first update all Debian repository entries to Bullseye and add new entries to the apt source list.
sed -i 's/buster\/updates/bullseye-security/g;s/buster/bullseye/g' /etc/apt/sources.list
then add Proxmox Enterprise bullseye repositories to the apt list (You can skip this command if you don’t have Proxmox subscription and using the free product)
echo "deb https://enterprise.proxmox.com/debian/pve bullseye pve-enterprise" > /etc/apt/sources.list.d/pve-enterprise.list
The next step is to add the Proxmox VE 7.X no subscription repository to your system. This can be done by running the following command in the terminal:
sed -i -e 's/buster/bullseye/g' /etc/apt/sources.list.d/pve-install-repo.list
After this, remember to comment out and disable the old buster repositories in the source list.
Upgrade the Proxmox VE installation.
Once you have added the Proxmox VE 7.X repository to your system, you can proceed with the upgrade by running the following command in the terminal:
apt-get update && apt-get upgrade
This command will upgrade all the packages and dependencies on your Proxmox VE 5.X installation to the latest Proxmox VE 7.X version.
apt dist-upgrade
Again, this will start downloading and configuring the updates of the OS and replace specific configuration files; This will also prompt some questions about the new system configuration, so choose the appropriate options and wait patiently. After the upgrade is complete, it is recommended that you reboot your system to ensure that all the changes are correctly applied. You can reboot your system by running the following command in the terminal:
reboot now
You may want to remove the obsolete packages with the following command:
apt-get autoremove
And clean the apt cache with
apt-get clean
Verify the upgrade
Once your system has rebooted, you can verify that the upgrade was successful by logging in to the Proxmox VE web interface. You should see the new Proxmox VE 7.X interface, which includes many new features and improvements over the previous version.
Conclusion
Upgrading Proxmox VE 5.X to 7.X is a complex process that requires careful planning and execution. However, following the steps outlined in this blog, you can successfully upgrade your Proxmox VE installation and take advantage of the latest features and improvements. Remember to back up your data and configuration files before proceeding with the upgrade, and verify that the upgrade was successful once it is complete. Proxmox wiki is an excellent source of help if you encounter any error message or feel stuck somewhere.
Leave a Reply