How to Reset Networking after replacing NIC?

sdet00

Well-Known Member
Nov 18, 2017
70
31
58
Hey guys, sorry for the relatively noob-ey question here, but I'm struggling to figure this one out. I originally setup Proxmox 5.0 on an old Core2Quad system that was laying around just a temporary setup which worked well, and I have since moved it to a HP Elitedesk 800 (Haswell i5, Intel NIC). Since I've changed hardware though, I can't seem to be able to connect to my PVE.

I previously had set a fixed IP to 192.168.1.45, however when I log into Proxmox on the machine it tells me to connect via 192.168.1.219. I can't ping either IP, although the NIC is showing a link. Running ifconfig -a shows "en0", "lo" and "vmbr0". If I run "lspci" I can see my Intel NIC in the list, but obviously it needs to be configured to work properly.

I vaguely remember a network setup when I first setup Proxmox. Is it possible to run that again and reset and existing NIC setup? Or do I need to edit a config file somewhere? I did some research already and I found ways to do this for Debian distros, but I get the feeling Proxmox handles this differently since it uses a virtual switch of sorts. Advice would be appreciated :)
 
Hey guys, sorry for the relatively noob-ey question here, but I'm struggling to figure this one out. I originally setup Proxmox 5.0 on an old Core2Quad system that was laying around just a temporary setup which worked well, and I have since moved it to a HP Elitedesk 800 (Haswell i5, Intel NIC). Since I've changed hardware though, I can't seem to be able to connect to my PVE.

I previously had set a fixed IP to 192.168.1.45, however when I log into Proxmox on the machine it tells me to connect via 192.168.1.219. I can't ping either IP, although the NIC is showing a link. Running ifconfig -a shows "en0", "lo" and "vmbr0". If I run "lspci" I can see my Intel NIC in the list, but obviously it needs to be configured to work properly.

I vaguely remember a network setup when I first setup Proxmox. Is it possible to run that again and reset and existing NIC setup? Or do I need to edit a config file somewhere? I did some research already and I found ways to do this for Debian distros, but I get the feeling Proxmox handles this differently since it uses a virtual switch of sorts. Advice would be appreciated :)


Proxmox uses configuration based on /etc/network/interfaces (traditional debian style).

The prompt where to connect to is based on the following line in /etc/hosts:

Code:
192.168.1.219 name.xyz.com name pvelocalhost


adapt it accordingly!
 
As an update to this old post, I tried these methods but I was unable to achieve reliable connectivity. It did work initially, then after a reboot the server wasn't accessible again. I decided to simply reformat Proxmox and restore backups of my guest VMs manually on the latest version which is working fine now. Something definitely a bit bugged here with networking since I followed traditional debian methods and it didn't work. Hopefully I never have to change a NIC again.
 
Found this thread with a Google search as I'm seeing the exact same symptoms with 5.3-9.
I replaced my NIC with a known good card and there seems to be no attempt by Proxmox to use it; there are no activity lights and pings to the internal/external network don't work. The card shows in lspci, and even reboots and networking restarts aren't enough to persuade Proxmox to do anything with the new card other than notice it's there. Is there something I need to do in /etc/network/interfaces? vmbr0 is set to static 192.168.1.97 which would be fine (nothing currently on 97) but it's not getting that far.
Edit - ifconfig shows the vmbr0 with an IP of 192.168.1.97 with broadcast and netmask looking fine. But no actual network connection.
 
Hey jjman,

Since I posted this I have learned a lot about how networking works in Proxmox. It's actually fairly straightforward, but slightly different to standard Debian. Here are my notes:


  1. Discover the network interfaces on your device. You can do this by typing “ip link show”. Look for an adapter that starts with “en” as this is most likely your ethernet adapter. Make a note of the ID of the ethernet adapter (eg. “enp6s0”).

  2. We will now need to update the config of the network interface (IP address and gateway) with the following command:

    1. nano /etc/network/interfaces

      1. Replace the ethernet adapter IDs within the document - there should be two entries, one for the interface, and one for the virtual switch, which are named both “iface” and “bridge_ports” respectively.

      2. Update the IP address if necessary.
  3. Once you have done this, reboot your host, or restart your network stack (script coming soon)

  4. Now that your host has the correct network configuration, you can now complete the rest of the setup from another PC. Access the WebUI (https://yourip:8006), login with the default credentials (root/password) and make the following changes:

    1. Go to pve01 -> system -> DNS

      1. Update 192.168.1.2 to your router’s IP address
    2. Go to pve01 -> system -> Hosts

      1. Update 192.168.1.1 to your host’s IP address (if applicable)
 
Hey jjman,
...

Thank you so much, I was banging my head because somehow my adapter had inexplicably changed its name. Possibly because I was moving pcie devices around, but I don't know enough about how the nic is connected to the chipset and how the naming works. In any case, thank you for the little guide, I should have known to check but I didn't and you saved me some time.
 
Hey jjman,

Since I posted this I have learned a lot about how networking works in Proxmox. It's actually fairly straightforward, but slightly different to standard Debian. Here are my notes:


  1. Discover the network interfaces on your device. You can do this by typing “ip link show”. Look for an adapter that starts with “en” as this is most likely your ethernet adapter. Make a note of the ID of the ethernet adapter (eg. “enp6s0”).

  2. We will now need to update the config of the network interface (IP address and gateway) with the following command:
    1. nano /etc/network/interfaces
      1. Replace the ethernet adapter IDs within the document - there should be two entries, one for the interface, and one for the virtual switch, which are named both “iface” and “bridge_ports” respectively.

      2. Update the IP address if necessary.
  3. Once you have done this, reboot your host, or restart your network stack (script coming soon)

  4. Now that your host has the correct network configuration, you can now complete the rest of the setup from another PC. Access the WebUI (https://yourip:8006), login with the default credentials (root/password) and make the following changes:
    1. Go to pve01 -> system -> DNS
      1. Update 192.168.1.2 to your router’s IP address
    2. Go to pve01 -> system -> Hosts
      1. Update 192.168.1.1 to your host’s IP address (if applicable)
I'm just here to thank you for your time and disposal to write this solution. I've just had the same problem and it is easily solved that way! Thumbs up :D
 
Hey jjman,

Since I posted this I have learned a lot about how networking works in Proxmox. It's actually fairly straightforward, but slightly different to standard Debian. Here are my notes:


  1. Discover the network interfaces on your device. You can do this by typing “ip link show”. Look for an adapter that starts with “en” as this is most likely your ethernet adapter. Make a note of the ID of the ethernet adapter (eg. “enp6s0”).

  2. We will now need to update the config of the network interface (IP address and gateway) with the following command:
    1. nano /etc/network/interfaces
      1. Replace the ethernet adapter IDs within the document - there should be two entries, one for the interface, and one for the virtual switch, which are named both “iface” and “bridge_ports” respectively.

      2. Update the IP address if necessary.
  3. Once you have done this, reboot your host, or restart your network stack (script coming soon)

  4. Now that your host has the correct network configuration, you can now complete the rest of the setup from another PC. Access the WebUI (https://yourip:8006), login with the default credentials (root/password) and make the following changes:
    1. Go to pve01 -> system -> DNS
      1. Update 192.168.1.2 to your router’s IP address
    2. Go to pve01 -> system -> Hosts
      1. Update 192.168.1.1 to your host’s IP address (if applicable)
i registed so i could leave a reply

thank you so much for this!
 
I'm glad people still use this. I do wish that the Proxmox team would introduce something like OMV-Firstaid (for OpenMediaVault) - makes this sort of thing so much easier to deal with.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!