The VMs are not assigned ip address by dhcp server.

Small Basic

New Member
Apr 16, 2023
9
0
1
My Proxmox Server is working on baremetal server. Network configure is DHCP. Real NIC enp3s0 is bridged by vmbr0.
But the VMs are unable to get IP address by dhcp. I can access proxmox web gui, and Proxmox server can access network and internet. But the VMs can't do it.
/etc/network/interfaces
Code:
# network interface settings; autogenerated
# Please do NOT modify this file directly, unless you know what
# you're doing.
#
# If you want to manage parts of the network configuration manually,
# please utilize the 'source' or 'source-directory' directives to do
# so.
# PVE will preserve these directives, but will NOT read its network
# configuration from sourced files, so do not attempt to move any of
# the PVE managed interfaces into external files!

auto lo
iface lo inet loopback

auto enp3s0
iface enp3s0 inet dhcp
#manual

auto enp2s0
iface enp2s0 inet dhcp
#manual

auto vmbr0
iface vmbr0 inet dhcp

        bridge-ports enp3s0
        bridge-stp off
        bridge-fd 0
#manual address 192.168.0.5/24  gateway 192.168.0.1

iface wlp1s0 inet manual

auto vmbr1
iface vmbr1 inet manual
        bridge-ports none
        bridge-stp off
        bridge-fd 0

What should I do?, please tell me.
Thank you for reading my post.
 
Thank you for your replying.
My DHCP server subnet is 192.168.1.0/24, so it is same your sample.
ip address of my Proxmox server is 192.168.1.6

By the way, I was installed the proxmox server at other network(subnet is 192.168.0.0/24,ip address of server is 192.168.0.5). So the tty screen of display is showing used ip address when installing proxmox server. Is it relate this problem?
 
Last edited:
If your DHCP server is on 192.168.1.0 and your Proxmox server is on 192.168.0.0
they will NOT "see" each other. These are different subnets.
Make sure you are all on the same subnet. So change all to 192.168.1.0 OR 192.168.0.0.
You cannot "mix" (unless you create static routes).
 
Yes, I agree.
Code:
root@proxmox:~# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp2s0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
    link/ether 5c:85:7e:4f:81:a3 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.6/24 brd 192.168.1.255 scope global enp2s0
       valid_lft forever preferred_lft forever
3: enp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master vmbr0 state UP group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
4: wlp1s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether ec:2e:98:59:0b:43 brd ff:ff:ff:ff:ff:ff
5: vmbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.6/24 brd 192.168.1.255 scope global vmbr0
       valid_lft forever preferred_lft forever
    inet6 fe80::5e85:7eff:fe4f:81a4/64 scope link
       valid_lft forever preferred_lft forever
root@proxmox:~#

the proxmox server is bridgeing enp3s0 to vmbr0. And vmbr0 is recognizing 192.168.1.6 ip address and subnet 192.168.1.0/24
So I can access web interface of the proxmox server and the proxmox server can access internet and devices in this network.
But the VMs are unable to access internet and devices in this network.
 
Why you have two interfaces set up with the same IP address?
Remove the DHCP client on enp2s0 (my understanding is that you want to use vmbr0 ) first and see if this solves your issue.
 
A computer of my proxmox server has tow nic. So enp2s0,enp3s0. I'm using enp3s0. I'm not using enp2s0. When instaling proxmox too. But to settle any error, I used enp2s0. Then, dhcp server gave the server ip address 192.168.1.6
ip addresses of vmbr0 and enp2s0 are same, it just so happens that the same. Now, I am not using enp2s0.
 
Non-connected interfaces should not be taken into account in the routing table, but for the sake of having things clearer, I'd suggest to remove that IP address on enp2s0.
 
I deleted ip address of enp2s0.

Code:
root@proxmox1:/scserver/Launcher# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp2s0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
    link/ether 5c:85:7e:4f:81:a3 brd ff:ff:ff:ff:ff:ff
3: enp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master vmbr0 state UP group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
4: wlp1s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether ec:2e:98:59:0b:43 brd ff:ff:ff:ff:ff:ff
5: vmbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.6/24 brd 192.168.1.255 scope global vmbr0
       valid_lft forever preferred_lft forever
    inet6 fe80::5e85:7eff:fe4f:81a4/64 scope link
       valid_lft forever preferred_lft forever

But it didn't improve. The VMs are unable to access internet and network.
 
1) I guess you touched the /etc/network/interface and then launched ifrealod -a (what's the output?).
2) Also you may want to remove the interface of each VM from the bridge and then reassign it to the vmbr.
 
Last edited:
When I delete ip address of enp2s0, I launched command of ip a del 192.168.1.6/24 dev enp2s0
The command of ifreload -a returned this.
Code:
root@proxmox1:~# ifreload -a
warning: enp3s0: ignoring ip address. Assigning an IP address is not allowed on enslaved interfaces. enp3s0 is enslaved to vmbr0
root@proxmox1:~#

And I removed the interface of each VM form the bridge and reassign it to the vmbr0, but the VMs are unable to access internet and network.
 
So the DHCP server is connected to the vmbr0 as well as the DHCP clients? You can sniff on the vmbr0 by doing tcpdump -ni vmbr0 'udp and (port 68 or port 69)'
 
Last edited:
I hope the VMs use upstream dhcp server. DHCP server of a router. And I ran a command of tcpdump -ni vmbr0 'udp and (port 68 or port 69)'. On the VMs, I ran a comand of dhclient net1(net1is name of nic of VMs.). tcpdump command returned this.
Code:
root@proxmox1:~# tcpdump -ni vmbr0 'udp and (port 68 or port 69)'
tcpdump: verbose output suppressed, use -v[v]... for full protocol decode
listening on vmbr0, link-type EN10MB (Ethernet), snapshot length 262144 bytes
dhclient command didn't return anything, but the VM didn't get ip address.
 
Please send the output of these commands from the host
Code:
ip link show
ip addr show
brctl show
 
Last edited:
OK. I executed your commands.
Code:
root@proxmox1:~# ip link show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp2s0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN mode DEFAULT group default qlen 1000
    link/ether 5c:85:7e:4f:81:a3 brd ff:ff:ff:ff:ff:ff
3: enp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master vmbr0 state UP mode DEFAULT group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
4: wlp1s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/ether ec:2e:98:59:0b:43 brd ff:ff:ff:ff:ff:ff
5: vmbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
root@proxmox1:~# ip addr show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp2s0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000
    link/ether 5c:85:7e:4f:81:a3 brd ff:ff:ff:ff:ff:ff
3: enp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master vmbr0 state UP group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
4: wlp1s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether ec:2e:98:59:0b:43 brd ff:ff:ff:ff:ff:ff
5: vmbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 5c:85:7e:4f:81:a4 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.6/24 brd 192.168.1.255 scope global vmbr0
       valid_lft forever preferred_lft forever
    inet6 fe80::5e85:7eff:fe4f:81a4/64 scope link
       valid_lft forever preferred_lft forever
root@proxmox1:~# brctl show
bridge name     bridge id               STP enabled     interfaces
vmbr0           8000.5c857e4f81a4       no              enp3s0
                                                        fwpr101p0
root@proxmox1:~#
 
I'm having the same/similar issue.. Was this resolved?
My network is 192.168.0.1/24.
My proxmox is 192.168.0.30.
I've deployed a couple VMs, TrueNAS and Kali linux. Neither get assigned an IP from dhcp which is 192.168.0.1 the gateway for my bridged interface - vmbr0. I'm able to manually assign the IP through the console so it works, but how I fix this issue so that it gets assigned by the dhcp instead of me having to manually configure it.
I can make a new post/thread, but found this one that seems pretty much the same with no resolution
 
After installing Proxmox on another computer, the VM was successfully given an Ip address by DHCP. So I figured my problem was caused by Minisfourm GK41. However, it also seems to occur on @jisatsu's computer.
In my case, I installed it on a different network segment (e.g., installed on 192.168.0.0/24 and operated on 192.168.1.0/24) and again on a different network segment. At that time, the GK41 was not correctly assigned an Ip address by DHCP to the VM. However, on the other computer installed in the same way, the Ip address was assigned to the VM by DHCP.
It is possible that some network-related settings or binaries were corrupted during the installation, so reinstallation may be a better use.
I am sorry to say that I am not able to check this further because I changed the operating system of the computer that is not working properly from Proxmox in order to install another operating system.
 
After installing Proxmox on another computer, the VM was successfully given an Ip address by DHCP. So I figured my problem was caused by Minisfourm GK41. However, it also seems to occur on @jisatsu's computer.
In my case, I installed it on a different network segment (e.g., installed on 192.168.0.0/24 and operated on 192.168.1.0/24) and again on a different network segment. At that time, the GK41 was not correctly assigned an Ip address by DHCP to the VM. However, on the other computer installed in the same way, the Ip address was assigned to the VM by DHCP.
It is possible that some network-related settings or binaries were corrupted during the installation, so reinstallation may be a better use.
I am sorry to say that I am not able to check this further because I changed the operating system of the computer that is not working properly from Proxmox in order to install another operating system.
No worries. For the most part I'm fine setting up the IPs manually, just annoying I have to do it to get it on the network. Thanks for the update.
 
No worries. For the most part I'm fine setting up the IPs manually, just annoying I have to do it to get it on the network. Thanks for the update.
After installing Proxmox on another computer, the VM was successfully given an Ip address by DHCP. So I figured my problem was caused by Minisfourm GK41. However, it also seems to occur on @jisatsu's computer.
In my case, I installed it on a different network segment (e.g., installed on 192.168.0.0/24 and operated on 192.168.1.0/24) and again on a different network segment. At that time, the GK41 was not correctly assigned an Ip address by DHCP to the VM. However, on the other computer installed in the same way, the Ip address was assigned to the VM by DHCP.
It is possible that some network-related settings or binaries were corrupted during the installation, so reinstallation may be a better use.
I am sorry to say that I am not able to check this further because I changed the operating system of the computer that is not working properly from Proxmox in order to install another operating system.
Don't get gaslit into thinking it's a problem on your end, proxmox appears to be completely broken for basic network functionality. Honestly don't understand how this software is so highly lauded, the three times i've used it to install on computers the first time it could not load the graphics drivers and installation failed, and on the second computer it fails to get dhcp address, the third computer just fails to work with dhcp with proxmox installed when literally ubuntu server and lubuntu worked fine.
 
Same here, windows VM does not get IP assigned, I have to change settings from DHCP to Manual and configure it, then it connects.
 

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!