Custom Search

Monday, November 23, 2015

under cloud neutron dnsmasq-dhcp debugging

* Here "40:ea:a7:33:7f:0e" is the MAC address of bare-metal node to be provisioned. We have enabled network boot (PXE boot) for the interface which has MAC address "40:ea:a7:33:7f:0e". So UC will get DHCP request from that interface of bare-metal node.

* Here "10.140.15.31" is the IP allocated by dnsmasq-dhcp server running in UC to bare-metal node.

* So we should able to capture following data while running "#nova boot" from UC and confirm that UC getting dhcp request from provisioned node.

1)
In UC:

root@uc1:~# tail -f /var/log/syslog | grep 40:ea:a7:33:7f:0e
Nov 23 02:15:50 uc1 dnsmasq-dhcp[42934]: DHCPDISCOVER(tapbe2e899a-38) 40:ea:a7:33:7f:0e
Nov 23 02:15:50 uc1 dnsmasq-dhcp[42934]: DHCPOFFER(tapbe2e899a-38) 10.140.15.31 40:ea:a7:33:7f:0e
Nov 23 02:15:54 uc1 dnsmasq-dhcp[42934]: DHCPREQUEST(tapbe2e899a-38) 10.140.15.31 40:ea:a7:33:7f:0e
Nov 23 02:15:54 uc1 dnsmasq-dhcp[42934]: DHCPACK(tapbe2e899a-38) 10.140.15.31 40:ea:a7:33:7f:0e host-10-140-15-31

2)
In UC:

a)
root@uc1:~# ip netns
exec qdhcp-f6e86850-32e9-4366-a03b-2b2a9ac481f0

b)
root@uc1:~# ip netns exec qdhcp-f6e86850-32e9-4366-a03b-2b2a9ac481f0 ifconfig
tapbe2e899a-38

c)
root@uc1:~# ip netns exec qdhcp-f6e86850-32e9-4366-a03b-2b2a9ac481f0 tcpdump -vv -i tapbe2e899a-38 | grep 40:ea:a7:33:7f:0e

    0.0.0.0.bootpc > 255.255.255.255.bootps: [udp sum ok] BOOTP/DHCP, Request from 40:ea:a7:33:7f:0e (oui Unknown), length 548, xid 0xa7117f0d, secs 4, Flags [Broadcast] (0x8000)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
    0.0.0.0.bootpc > 255.255.255.255.bootps: [udp sum ok] BOOTP/DHCP, Request from 40:ea:a7:33:7f:0e (oui Unknown), length 548, xid 0xa7117f0d, secs 4, Flags [Broadcast] (0x8000)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      source link-address option (1), length 8 (1): 40:ea:a7:33:7f:0e
      source link-address option (1), length 8 (1): 40:ea:a7:33:7f:0e
     
3)
In UC:

root@uc1:~# tcpdump -vv -i br-ctlplane | grep 40:ea:a7:33:7f:0e

tcpdump: listening on br-ctlplane, link-type EN10MB (Ethernet), capture size 65535 bytes
    0.0.0.0.bootpc > 255.255.255.255.bootps: [udp sum ok] BOOTP/DHCP, Request from 40:ea:a7:33:7f:0e (oui Unknown), length 548, xid 0xa7117f0d, secs 4, Flags [Broadcast] (0x8000)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
    0.0.0.0.bootpc > 255.255.255.255.bootps: [udp sum ok] BOOTP/DHCP, Request from 40:ea:a7:33:7f:0e (oui Unknown), length 548, xid 0xa7117f0d, secs 4, Flags [Broadcast] (0x8000)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      source link-address option (1), length 8 (1): 40:ea:a7:33:7f:0e
20:46:27.592585 ARP, Ethernet (len 6), IPv4 (len 4), Reply 10.140.15.31 is-at 40:ea:a7:33:7f:0e (oui Unknown), length 46
      source link-address option (1), length 8 (1): 40:ea:a7:33:7f:0e

4)
In UC:

root@uc1:~# tcpdump -vv -i phy-br-ctlplane | grep 40:ea:a7:33:7f:0e

tcpdump: WARNING: phy-br-ctlplane: no IPv4 address assigned
tcpdump: listening on phy-br-ctlplane, link-type EN10MB (Ethernet), capture size 65535 bytes

    0.0.0.0.bootpc > 255.255.255.255.bootps: [udp sum ok] BOOTP/DHCP, Request from 40:ea:a7:33:7f:0e (oui Unknown), length 548, xid 0xa7117f0d, secs 4, Flags [Broadcast] (0x8000)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
    0.0.0.0.bootpc > 255.255.255.255.bootps: [udp sum ok] BOOTP/DHCP, Request from 40:ea:a7:33:7f:0e (oui Unknown), length 548, xid 0xa7117f0d, secs 4, Flags [Broadcast] (0x8000)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      Client-Ethernet-Address 40:ea:a7:33:7f:0e (oui Unknown)
      source link-address option (1), length 8 (1): 40:ea:a7:33:7f:0e
      source link-address option (1), length 8 (1): 40:ea:a7:33:7f:0e

No comments:

Post a Comment