osrf / cloudsim-legacy

Apache License 2.0
1 stars 1 forks source link

OpenStack dhcp #146

Closed osrf-migration closed 10 years ago

osrf-migration commented 11 years ago

Original report (archived issue) by Hugo Boyer (Bitbucket: hugomatic, GitHub: hugomatic).


I'm having problems running the puppet-vagrant branch. I can install the software successfully, but I am not able to create instances with the correct IP.

This was found in the log when trying to launch a cirros instance with the desired IPs:

This problems seems to be in the vagrant virtual machine (since it is where OpenStack is installed), but it could also be a problem with the host (since it works on other machines)

Any thoughs?

#!bash

Starting network...
udhcpc (v1.20.1) started
Sending discover...
Sending select for 172.16.1.2...
Received DHCP NAK
Sending discover...
Sending select for 192.168.56.101...
Lease of 192.168.56.101 obtained, lease time 3600
cirros-ds 'net' up at 12.09
checking http://169.254.169.254/2009-04-04/instance-id
failed 1/20: up 12.46. request failed
failed 2/20: up 14.70. request failed
failed 3/20: up 16.97. request failed
failed 4/20: up 19.22. request failed
failed 5/20: up 21.46. request failed
failed 6/20: up 23.78. request failed
failed 7/20: up 26.11. request failed
failed 8/20: up 28.39. request failed
failed 9/20: up 30.64. request failed
failed 10/20: up 32.89. request failed
failed 11/20: up 35.14. request failed
failed 12/20: up 37.38. request failed
failed 13/20: up 39.74. request failed
failed 14/20: up 42.01. request failed
failed 15/20: up 44.28. request failed
failed 16/20: up 46.58. request failed
failed 17/20: up 48.84. request failed
failed 18/20: up 51.09. request failed
failed 19/20: up 53.36. request failed
failed 20/20: up 55.67. request failed
failed to read iid from metadata. tried 20
no results found for mode=net. up 57.97. searched: nocloud configdrive ec2
failed to get instance-id of datasource
Starting dropbear sshd: generating rsa key... generating dsa key... OK
=== network info ===
if-info: lo,up,127.0.0.1,8,::1
if-info: eth0,up,192.168.56.101,24,fe80::f816:3eff:fe66:8055
ip-route:192.168.56.0/24 dev eth0  src 192.168.56.101 
osrf-migration commented 11 years ago

Original comment by Esteve Fernandez (Bitbucket: esteve, GitHub: esteve).


What's the host OS? Did you already have a host-only interface? 192.168.56.101 is the default IP address that VirtualBox uses for the host-only interfaces, so it seems instances are picking up addresses from the wrong network interface.

What does /sbin/ifconfig look like on the host OS? And on the VM?

Did you start the VM via "vagrant up" or through the VirtualBox GUI?

Thanks!

osrf-migration commented 11 years ago

Original comment by Hugo Boyer (Bitbucket: hugomatic, GitHub: hugomatic).


#!python
hugo@hugobox:~/code/esteve/cloudsim$ uname -a
Linux hugobox 3.2.0-45-generic #70-Ubuntu SMP Wed May 29 20:12:06 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
hugo@hugobox:~/code/esteve/cloudsim$ ifconfig
eth2      Link encap:Ethernet  HWaddr 90:2b:34:39:aa:45  
          inet addr:192.168.1.149  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::922b:34ff:fe39:aa45/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2656806 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1635016 errors:0 dropped:0 overruns:0 carrier:1
          collisions:0 txqueuelen:1000 
          RX bytes:3407947467 (3.4 GB)  TX bytes:183804230 (183.8 MB)
          Interrupt:48 

eth3      Link encap:Ethernet  HWaddr 90:2b:34:39:aa:55  
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:20 Memory:f7500000-f7520000 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:7122078 errors:0 dropped:0 overruns:0 frame:0
          TX packets:7122078 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:3661272856 (3.6 GB)  TX bytes:3661272856 (3.6 GB)

vboxnet0  Link encap:Ethernet  HWaddr 0a:00:27:00:00:00  
          inet addr:172.16.0.254  Bcast:172.16.255.255  Mask:255.255.0.0
          inet6 addr: fe80::800:27ff:fe00:0/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:8303 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:608929 (608.9 KB)

vboxnet1  Link encap:Ethernet  HWaddr 0a:00:27:00:00:01  
          inet addr:10.10.0.1  Bcast:10.10.255.255  Mask:255.255.0.0
          inet6 addr: fe80::800:27ff:fe00:1/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:250 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:30052 (30.0 KB)

On the cirros instance, this dmesg error was also seen:

#!python

Jul 18 11:54:12 cirros kern.info kernel: [   10.207972] eth0: IPv6 duplicate address fe80::f816:3eff:fef6:7a97 detected!

I found something somewhat related to that problem here: bug on launchpad

I'm trying a few things but I am still in the dark...

osrf-migration commented 11 years ago

Original comment by Esteve Fernandez (Bitbucket: esteve, GitHub: esteve).


Could you run ifconfig from inside the "outer" VM? i.e. the one started by "vagrant up". Also, what's the output of ifconfig from inside the cirros instance?

How did you obtain the cirros log? Via the OpenStack Dashboard or from inside the cirros instance?

osrf-migration commented 11 years ago

Original comment by Hugo Boyer (Bitbucket: hugomatic, GitHub: hugomatic).


This looks like a problem specific to my machine.

This is my ifconfig:

#!python

eth2      Link encap:Ethernet  HWaddr 90:2b:34:39:aa:45  
          inet addr:192.168.1.149  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::922b:34ff:fe39:aa45/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4941317 errors:0 dropped:0 overruns:0 frame:0
          TX packets:3332989 errors:0 dropped:0 overruns:0 carrier:1
          collisions:0 txqueuelen:1000 
          RX bytes:5428546740 (5.4 GB)  TX bytes:468153297 (468.1 MB)
          Interrupt:48 

eth3      Link encap:Ethernet  HWaddr 90:2b:34:39:aa:55  
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:20 Memory:f7500000-f7520000 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:243826635 errors:0 dropped:0 overruns:0 frame:0
          TX packets:243826635 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:792833544108 (792.8 GB)  TX bytes:792833544108 (792.8 GB)

vboxnet0  Link encap:Ethernet  HWaddr 0a:00:27:00:00:00  
          inet addr:172.16.0.254  Bcast:172.16.255.255  Mask:255.255.0.0
          inet6 addr: fe80::800:27ff:fe00:0/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26325 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:2038336 (2.0 MB)

vboxnet1  Link encap:Ethernet  HWaddr 0a:00:27:00:00:01  
          inet addr:10.10.0.1  Bcast:10.10.255.255  Mask:255.255.0.0
          inet6 addr: fe80::800:27ff:fe00:1/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:747 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:76433 (76.4 KB)
osrf-migration commented 11 years ago

Original comment by Esteve Fernandez (Bitbucket: esteve, GitHub: esteve).


The host-only adapters look good. Could you do a vagrant ssh and type ifconfig from inside the outer VM? I'd like to make sure that the network adapters are mapped correctly.

Thanks!

osrf-migration commented 11 years ago

Original comment by Esteve Fernandez (Bitbucket: esteve, GitHub: esteve).


Did it work for you Hugo? Can I close this ticket?

Thanks.

osrf-migration commented 10 years ago

Original comment by Hugo Boyer (Bitbucket: hugomatic, GitHub: hugomatic).