Ask Your Question
0

Devstack - Problem loading ssh keys on instance

asked 2016-12-28 05:52:03 -0500

d.carmignani gravatar image

updated 2016-12-29 02:20:06 -0500

Hi all, I have a Devstack installation. I'm able to create new instances, but the system is not able to load the SSH key into the cloud instances, and therefore I cannot login.

Can you help me, or tell me where to find the error? In the logs of the instance I read:

[   36.770256] cloud-init[351]: [CLOUDINIT] url_helper.py[WARNING]: Calling 'http://169.254.169.254/2009-04-04/meta-data/instance-id' failed [1/120s]: bad status code [500]
[  156.118739] cloud-init[351]: [CLOUDINIT] util.py[WARNING]: No instance datasource found! Likely bad things to come!
[  156.132344] cloud-init[349]: 2016-12-28 10:59:11,453 - util.py[WARNING]: No instance datasource found! Likely bad things to come!
[  156.303936] cloud-init[349]: .
[  156.325527] systemd[1]: Started LSB: Cloud init.
[  156.349451] systemd[1]: Starting LSB: Cloud init modules --mode config...
[  156.365910] systemd[1]: Starting OpenBSD Secure Shell server...
[  156.393152] systemd[1]: Started OpenBSD Secure Shell server.
[  156.862700] sshd[367]: Could not load host key: /etc/ssh/ssh_host_rsa_key
[  156.877257] sshd[367]: Could not load host key: /etc/ssh/ssh_host_dsa_key
[  156.889778] sshd[367]: Could not load host key: /etc/ssh/ssh_host_ecdsa_key
[  156.902279] sshd[367]: Could not load host key: /etc/ssh/ssh_host_ed25519_key
[  156.916299] sshd[367]: Server listening on 0.0.0.0 port 22.
[  156.924316] sshd[367]: Server listening on :: port 22.
[  160.786372] cloud-config[366]: Starting Cloud service: cloud-initCan not apply stage config, no datasource found! Likely bad things to come!

And this is the content of q-meta.log

    2016-12-28 16:10:12.709 INFO eventlet.wsgi.server [-] 192.168.100.9,<local> - - [28/Dec/2016 16:10:12] "GET /2009-04-04/meta-data/instance-id HTTP/1.1" 500 229 0.277316
2016-12-28 16:10:13.659 DEBUG oslo_messaging._drivers.amqpdriver [-] CAST unique_id: 7d59e56f05074bc6b3afd9efe370a727 exchange 'neutron' topic 'q-reports-plugin' from (pid=5887) _send /usr/local/lib/python2.7/dist-packages/oslo_messaging/_drivers/amqpdriver.py:442
2016-12-28 16:10:14.839 DEBUG eventlet.wsgi.server [-] (5900) accepted '' from (pid=5900) server /usr/local/lib/python2.7/dist-packages/eventlet/wsgi.py:868
2016-12-28 16:10:14.839 DEBUG neutron.agent.metadata.agent [-] Request: GET /2009-04-04/meta-data/instance-id HTTP/1.0
2016-12-28 16:10:15.010 ERROR neutron.agent.metadata.agent [-] Unexpected error.
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent Traceback (most recent call last):
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent   File "/opt/stack/neutron/neutron/agent/metadata/agent.py", line 90, in __call__
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent     return self._proxy_request(instance_id, tenant_id, req)
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent   File "/opt/stack/neutron/neutron/agent/metadata/agent.py", line 193, in _proxy_request
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent     body=req.body)
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent   File "/usr/local/lib/python2.7/dist-packages/httplib2/__init__.py", line 1609, in request
2016-12-28 16:10:15.010 TRACE neutron.agent.metadata.agent     (response, content) = self._request ...
(more)
edit retag flag offensive close merge delete

Comments

It looks like your metadata service is not running. You can find out why and get it running, or you can force the config drive using nova.conf parameter force_config_drive = True. Cirros instances get metadata from the config drive if the metadata API doesn't work.

Bernd Bausch gravatar imageBernd Bausch ( 2016-12-28 08:37:22 -0500 )edit

I premise that I'm not an expert of OpenStack/Devstack. I can find the "q-meta" window in screen so I suppose that the metadata service is running but I see an error regarding File "/opt/stack/neutron/neutron/agent/metadata/agent.py", line 90, in __call__ return self._proxy_request

d.carmignani gravatar imaged.carmignani ( 2016-12-28 10:42:34 -0500 )edit

share the error log. You find it in /opt/stack/logs/q-meta.log.

The screen itself may exist even if the process has died.

Bernd Bausch gravatar imageBernd Bausch ( 2016-12-28 19:28:10 -0500 )edit

Pasted on the question

d.carmignani gravatar imaged.carmignani ( 2016-12-29 02:20:45 -0500 )edit

How can I troubleshoot the metadata server? Could it be a problem of configuration? This is part of the content of local.conf disable_service n-net ENABLED_SERVICES+=,q-svc,q-dhcp,q-meta,q-agt,q-l3

d.carmignani gravatar imaged.carmignani ( 2016-12-29 08:03:30 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2016-12-30 10:24:43 -0500

d.carmignani gravatar image

Solved: the problem was the IP address of the devstack host that needs to be into the no_proxy variable

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2016-12-28 05:52:03 -0500

Seen: 339 times

Last updated: Dec 30 '16