[ubuntu-cloud] Instance cannot contact metadata service

Peter Matulis peter.matulis at canonical.com
Tue Mar 1 17:21:46 UTC 2011


Hi, I am running a simple all-Lucid 2-machine cloud (frontend and node).
 The frontend is a KVM guest.  When I boot an instance, however, there
is a problem with it contacting the metadata service on the frontend.
>From euca-get-console-output I see

2011-03-01 15:00:11,341 - DataSourceEc2.py[WARNING]: waiting for
metadata service at http://169.254.169.254/2009-04-04/meta-data/instance-id

2011-03-01 15:00:11,343 - DataSourceEc2.py[WARNING]:   15:00:11 [
1/100]: url error [timed out]

(I have attached the entire output of that command.)

>From the frontend, I can contact this service:

$ telnet 169.254.169.254 80
Trying 169.254.169.254...
Connected to 169.254.169.254.
Escape character is '^]'.


On my client (laptop),

$ euca-describe-availability-zones verbose
AVAILABILITYZONE        pmatulis-cluster        192.168.7.1
AVAILABILITYZONE        |- vm types     free / max   cpu   ram  disk
AVAILABILITYZONE        |- m1.small     0007 / 0008   1    192     2
AVAILABILITYZONE        |- c1.medium    0007 / 0008   1    256     5
AVAILABILITYZONE        |- m1.large     0003 / 0004   2    512    10
AVAILABILITYZONE        |- m1.xlarge    0003 / 0003   2   1024    20
AVAILABILITYZONE        |- c1.xlarge    0001 / 0001   4   2048    20



$ euca-describe-instances $inst
RESERVATION     r-3D210799      admin   default
INSTANCE        i-3AA10650      emi-905717E0    192.168.7.20
172.19.1.2      running uecuser 0               m1.small
2011-03-01T14:58:37.177Z     pmatulis-cluster eki-F66E1CE4



On the frontend,

$ ip addr show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
state UNKNOWN qlen 1000
    link/ether 52:54:00:4b:f5:76 brd ff:ff:ff:ff:ff:ff
    inet 169.254.169.254/32 scope link eth0:metadata
    inet 192.168.7.1/24 brd 192.168.7.255 scope global eth0
    inet 172.19.1.1/27 brd 172.19.1.31 scope global eth0:priv
    inet 192.168.7.20/32 scope global eth0:pub
    inet6 fe80::5054:ff:fe4b:f576/64 scope link
       valid_lft forever preferred_lft forever



$ sudo iptables -L -n
[sudo] password for ubuntu:
Chain INPUT (policy ACCEPT)
target     prot opt source               destination

Chain FORWARD (policy DROP)
target     prot opt source               destination
ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0           ctstate
ESTABLISHED
ACCEPT     all  --  0.0.0.0/0           !172.19.0.0/16
admin-default  all  --  0.0.0.0/0            0.0.0.0/0
ACCEPT     all  --  172.19.1.0/27        172.19.1.0/27

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination

Chain admin-default (1 references)
target     prot opt source               destination
ACCEPT     tcp  --  0.0.0.0/0            172.19.1.0/27       tcp dpt:22
ACCEPT     icmp --  0.0.0.0/0            172.19.1.0/27



$ sudo iptables -L -n -t nat
[sudo] password for ubuntu:
Chain PREROUTING (policy ACCEPT)
target     prot opt source               destination
DNAT       tcp  --  172.19.0.0/16        169.254.169.254     tcp dpt:80
to:169.254.169.254:8773
DNAT       all  --  0.0.0.0/0            192.168.7.20        to:172.19.1.2

Chain POSTROUTING (policy ACCEPT)
target     prot opt source               destination
SNAT       all  --  172.19.1.2          !172.19.0.0/16       to:192.168.7.20
MASQUERADE  all  -- !127.0.0.0/8         !172.19.0.0/16

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination
DNAT       all  --  0.0.0.0/0            192.168.7.20        to:172.19.1.2


-- 
Peter
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: get-console-output.txt
URL: <https://lists.ubuntu.com/archives/ubuntu-cloud/attachments/20110301/cf3a1783/attachment-0001.txt>


More information about the Ubuntu-cloud mailing list