Page cover

Changing hostnames and IP addresses of nodes in Proxmox cluster

Let's face it, we've all been there. You set up your Proxmox homelab (or even a production cluster!), everything's purring along, and then you realise you need to change a hostname or, even more daunting, an IP address. While it seems like a straightforward task, a few missteps can quickly turn a perfectly good cluster into a digital headache. (Trust me, I've learned this the hard way more than once!)

This guide aims to demystify the process of safely and effectively updating hostnames and IP addresses for each node in your Proxmox cluster. Whether you're running a small homelab like my three-node setup (pictured below!) or managing a more extensive production environment, these steps will help you avoid the pitfalls and keep your cluster humming.

Our Proxmox Cluster: Before and After

For this walkthrough, we're taking our existing Proxmox cluster, currently configured with the following nodes and their respective IP addresses:

  • pve1: 192.168.100.250

  • pve2: 192.168.100.163

  • pve3: 192.168.100.174

Our goal is to transform this setup to a more streamlined naming convention and IP scheme. We'll be re-configuring them as:

  • pmx1: 192.168.100.101

  • pmx2: 192.168.100.102

  • pmx3: 192.168.100.103

We'll tackle this process one node at a time to ensure a smooth transition and minimise downtime. Let's dive in!

Important Precaution: Back Up! Back Up!

Before you start making any changes to your Proxmox cluster, it is absolutely crucial that you perform a full backup. This includes all your:

  • LXC containers

  • QEMU virtual machines (VMs)

While this process is designed to be smooth, unforeseen issues can always arise. Having a recent backup will save you a lot of headache (and potential data loss!) if anything goes awry. Don't skip this vital step!

Steps

Now, let's walk through the necessary steps for each Proxmox node. You'll need to perform these actions on every single node in your cluster, one by one, to successfully update their hostnames and IP addresses.

Once you've successfully updated the first node, simply repeat these exact same steps on the remaining two Proxmox nodes in your cluster. After you've re-configured all of them, your cluster should seamlessly reflect the new hostnames and IP addresses as intended.

Troubleshooting: Stubborn Old Hostnames

Even after a successful re-configuration, you might occasionally see the old, inactive hostname still lingering in your cluster view. Don't fret - this is usually an easy fix!

This often happens when there are stray directories from the old node names in the Proxmox configuration. To clean this up and get your cluster looking spick and span, follow these steps on each individual Proxmox node:

  1. Navigate to the nodes directory:

  1. Identify and remove old node name directories: Look for any directories that correspond to the old, inactive hostnames. For example, if your old node was pve1 and the new one is pmx1, you might still see a directory named pve1. Carefully remove these old directories. (Replace OLD_HOSTNAME_HERE with the actual old hostname you need to remove.)

  1. Reboot the node: After removing the directory, reboot the node to ensure the changes take full effect and the cluster refreshes its view.

After these steps, your cluster should finally reflect only the active, newly configured nodes!

Last updated

Was this helpful?