Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
376 views
in Technique[技术] by (71.8m points)

openstack instance didn't get the IP from DHCP agent

I am new to OpenStack and I follow the official Train installation guide for Centos/SELinux.

My Environment only contain two node (Controller/Compute) both set on KVM.

Neutron network setting: "dhcp","flat","linux bridge" and "provider network(L2)".

I check the openstack agent list is all up.

I got the dhcp error from instance console:

Sending discover... [   58.942761] random: nonblocking pool is
initialized Sending discover... Sending discover... Usage:
/sbin/cirros-dhcpc <up|down> No lease, failing
 
//### ifconfig -a (Doesn't get the ip address)

eth0      Link encap:Ethernet  HWaddr FA:16:3E:E1:88:29
          inet6 addr: fe80::f816:3eff:fee1:8829/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1014 errors:0 dropped:1 overruns:0 frame:0
          TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:65529 (63.9 KiB)  TX bytes:1332 (1.3 KiB)

The methods I have tried :

  1. Disable the firewall and network management on both controller and compute node

  2. Set promiscuous mode for NIC (both controller and compute node) checked

    ifconfig eth0 promisc

  3. Default security group open icmp and tcp:

----------------------ifconfig---------------------

Controller node:

brqc1e7d6aa-e7: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.16.1.85  netmask 255.255.255.0  broadcast 172.16.1.255
        ether 52:54:00:46:7e:bc  txqueuelen 1000  (Ethernet)
        RX packets 32969  bytes 5955992 (5.6 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1205  bytes 171485 (167.4 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth0: flags=4419<UP,BROADCAST,RUNNING,PROMISC,MULTICAST>  mtu 1500
        ether 52:54:00:46:7e:bc  txqueuelen 1000  (Ethernet)
        RX packets 33218  bytes 6453676 (6.1 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1326  bytes 197451 (192.8 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.16.1.87  netmask 255.255.255.0  broadcast 172.16.1.255
        ether 52:54:00:ed:68:e6  txqueuelen 1000  (Ethernet)
        RX packets 22892  bytes 1406351 (1.3 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 10485  bytes 3751553 (3.5 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 172188  bytes 72724903 (69.3 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 172188  bytes 72724903 (69.3 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

tapbdf66629-5d: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 86:67:43:de:38:c7  txqueuelen 1000  (Ethernet)
        RX packets 32  bytes 3632 (3.5 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 22369  bytes 1349435 (1.2 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

Compute node:

brqc1e7d6aa-e7: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.16.1.86  netmask 255.255.255.0  broadcast 172.16.1.255
        ether 52:54:00:a5:12:fb  txqueuelen 1000  (Ethernet)
        RX packets 31383  bytes 4447456 (4.2 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 8703  bytes 4719041 (4.5 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth0: flags=4419<UP,BROADCAST,RUNNING,PROMISC,MULTICAST>  mtu 1500
        ether 52:54:00:a5:12:fb  txqueuelen 1000  (Ethernet)
        RX packets 33551  bytes 5047837 (4.8 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 9823  bytes 5122880 (4.8 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.16.1.88  netmask 255.255.255.0  broadcast 172.16.1.255
        ether 52:54:00:c4:41:a3  txqueuelen 1000  (Ethernet)
        RX packets 23675  bytes 1617935 (1.5 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 9  bytes 426 (426.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 16921  bytes 888367 (867.5 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 16921  bytes 888367 (867.5 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

tapbcd1eed9-18: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether fe:16:3e:5a:cf:5c  txqueuelen 1000  (Ethernet)
        RX packets 11  bytes 1674 (1.6 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 2673  bytes 564169 (550.9 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

-------configuration for controller--------

ml2_conf.ini

[ml2] 
type_drivers = flat,vlan 
tenant_network_types = 
mechanism_drivers = linuxbridge 
extension_drivers = port_security

[ml2_type_flat] 
flat_networks = provider

[securitygroup] 
enable_ipset = true

linuxbridge_agent.ini

 [linux_bridge]  
 physical_interface_mappings = provider:eth0

 [vxlan]  
 enable_vxlan = false

 [securitygroup]  
 enable_security_group = true  
 firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver

Thanks for your help !!!

question from:https://stackoverflow.com/questions/65897382/openstack-instance-didnt-get-the-ip-from-dhcp-agent

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...