Ask Your Question

uts9's profile - activity

2016-12-28 05:41:39 -0500 received badge  Nice Answer (source)
2016-07-06 23:08:26 -0500 edited question Problem to login with ssh key using heat template

Hi guys,

I am new with OpenStack and I don't know how to solve this problem. I checked here and didn't find anything similar.

I created two VMs using the same Linux image. One using the HEAT template and another manually.

Both using the same key pair. the VM that I created manually, I am able to login using key pair (ubuntu and fedora account), but the one that I used the heat template does not allow me to login. I got a message "Server refuse our key"

I am trying to connect using putty

This is my template:

heat_template_version: 2013-05-23
description: Heat template to spin up small VM + floating ip using existing network
parameters:
  public_network:
    type: string
    label: ext-net
    description: Public network with floating IP addresses.
    default: 

  private_net_id:
    type: string
    description: ID of the internal network
    default: 

  private_subnet_id:
    type: string
    description: ID of private sub network into which servers get deployed
    default: 1e169801-f902-4b2d-9f5f-c6ad14c1c189

resources:
  server_port:
    type: OS::Neutron::Port
    properties:
      network_id: { get_param: private_net_id }
      fixed_ips:
        - subnet_id: { get_param: private_subnet_id }
      security_groups:
        - 0093ad96-0fca-42d2-beee-61e80488e7ed

  instance0:
    type: OS::Nova::Server
    properties:
      name: ubuntu01
      image: 0ac1ac59-f5d2-4e55-8c09-73c8adaf19eb
      flavor: m1.small
      key_name: cloud
      networks:
        - port: { get_resource: server_port }

  floating_ip:
    type: OS::Neutron::FloatingIP
    properties:
      floating_network: { get_param: public_network }

  floating_ip_assoc:
    type: OS::Neutron::FloatingIPAssociation
    properties:
      floatingip_id: { get_resource: floating_ip }
      port_id: { get_resource: server_port }

outputs:
  instance0_ip:
    description: IP address of instance0 in provider network
    value: { get_attr: [ instance0, first_address ] }
2016-06-24 14:46:22 -0500 received badge  Enlightened (source)
2016-06-24 14:46:22 -0500 received badge  Good Answer (source)
2016-01-25 15:26:27 -0500 received badge  Famous Question (source)
2016-01-02 01:35:53 -0500 commented question Install openstack on centos 7

Check whether you have all the required yum repositories. Try running yum install iptables-ipv6 first and proceed with packstack run.

2016-01-02 01:30:09 -0500 answered a question separate tenant public endpoint

Each endpoint will have publicurl, internalurl and adminurl. You can get the list of endpoints by running keystone endpoint-list command. So while creating an endpoint you can specify a different ip address for public endpoint(provided you have multiple nic s).

2016-01-02 01:26:13 -0500 answered a question PackStack fails with - Error: Unable to connect to mongodb server!

You need to change mongo db bind ip in /etc/mongod.conf file. You can still use Ceilometer.

2016-01-02 01:23:27 -0500 commented answer meta-data problem: 404 not found and http error 500

Could you please provide more details.

2016-01-02 01:22:11 -0500 edited question meta-data problem: 404 not found and http error 500

I have a small cluster of 8 machines , 4 of them are running compute node. The instances can't get meta-data with a console-output:

2011-07-25 07:12:08,521 - DataSourceEc2.py[WARNING]:   07:12:08 [70/100]: http error [500]

I set an iptables nat rule on network node to change dst IP address from 169.254.169.254:80 to 10.50.4.22:8773(CC_host ip),and also set an SNAT rule so that the instances can access the Internet. I run tcpdump on the network node and controller node, both can get packets on port 8773, so I conclude the link between Controller and instances is OK. I also use an IP in the fixed_ip list to run curl 10.50.4.22:8773 and get an output:

1.0
2007-01-19
2007-03-01
2007-08-29
2007-10-10
2007-12-15
2008-02-01
2008-09-01
2009-04-04

but when I run curl 10.50.4.22:8773/2009-04-04/, it turns out 404 error:

<html>
 <head>
  <title>404 Not Found</title>
 </head>
 <body>
  <h1>404 Not Found</h1>
  The resource could not be found.<br /><br />



 </body>
</html>

Then I checked the instance_metadata in Mysql database and find out it's empty.

I am confused and don't know why. Could somebody solve this problem? T.T

2016-01-02 01:20:26 -0500 commented question metadata and subnet gateway

Are you using DVR?. I am getting this error on my kilo setup when DVR is enabled.

Facing same issue on Kilo setup

Node1: Controller + Network + Compute (l3_agent.ini -> agent_type dvr_snat )
Node2: Compute (l3_agent.ini -> agent_type dvr)
2016-01-02 01:16:47 -0500 commented question metadata and subnet gateway

Fixed.

I nova.conf I had old settings from Kilo:

# service_neutron_metadata_proxy = True
# neutron_metadata_proxy_shared_secret = secret
service_metadata_proxy = True
metadata_proxy_shared_secret = secret
2016-01-02 01:16:13 -0500 edited question metadata and subnet gateway

Hi all, a short question:

I need to enable the metadata agent with route injection but my subnets all have a gateway (which is required to connecting the tenant's subnets to the admin router) so is it possible to have metadata working on a subnet also if this one has a gateway?

Actually in the VM's logs I see:

2015-07-13 08:23:59,574 - url_helper.py[WARNING]: Calling 'http://169.254.169.254/2009-04-04/meta-data/instance-id' failed [0/120s]: bad status code [404]

and in /var/log/neutron/neutron-metadata-agent.log:

2015-07-13 10:24:52.867 943515 INFO eventlet.wsgi.server [-] 172.16.0.2,<local> - - [13/Jul/2015 10:24:52] "GET /2009-04-04/meta-data/instance-id HTTP/1.1" 404 176 0.073210

In my qrouter's NAT table I have:

Chain neutron-l3-agent-PREROUTING (1 references)
target     prot opt source               destination
REDIRECT   tcp  --  anywhere             169.254.169.254      tcp dpt:http redir ports 9697

but i have no services running on port 9697.

Thanks for info.

2016-01-02 01:14:24 -0500 answered a question wget http://169.254.169.254/2009-04-04/meta-data/instance-id - error 404?

Facing same issue on Kilo setup

Node1: Controller + Network + Compute (l3_agent.ini -> agent_type dvr_snat ) Node2: Compute (l3_agent.ini -> agent_type dvr)

Update: Issue is resolved after setting use_forwarded_for=True in /etc/nova/nova.conf

nova/api/metadata/handler.py

  144     def _handle_remote_ip_request(self, req):
  145         remote_address = req.remote_addr
  146         if CONF.use_forwarded_for:
  147             remote_address = req.headers.get('X-Forwarded-For', remote_address)
  148 
  149         try:
  150             meta_data = self.get_metadata_by_remote_address(remote_address)
  151         except Exception:
  152             LOG.exception(_('Failed to get metadata for ip: %s'),
  153                           remote_address)
  154             msg = _('An unknown error has occurred. '
  155                     'Please try your request again.')
  156             raise webob.exc.HTTPInternalServerError(explanation=unicode(msg))
  157 
  158         if meta_data is None:
  159             LOG.error(_LE('Failed to get metadata for ip: %s'),
  160                       remote_address)
  161 
  162         return meta_data
2015-12-26 21:50:47 -0500 received badge  Famous Question (source)
2015-12-24 07:24:58 -0500 received badge  Notable Question (source)
2015-12-24 07:24:58 -0500 received badge  Popular Question (source)
2015-12-05 05:26:48 -0500 asked a question VM creation failure :NovaException: Unexpected vif_type=binding_failed

VM creation is failing on my OpenStack Kilo setup on Centos7 . Below is the error message. I have also posted nova.conf, neutron.conf , ml2_conf.ini and ovs_neutron_plugin.ini configuration files.

Any help would be greatly appreciated.

UPDATE1 - Issue started after setting host parameter in /etc/nova/nova.conf. If I comment this parameter I am able to launch a VM. Is there any way to set the hostname withut breaking the setup?

2015-12-04 15:42:02.210 9571 INFO nova.compute.resource_tracker [req-9152f41d-f4fc-4901-a420-013df7f1e656 - - - - -] Compute_service record updated for hpgen6:localhost.localdomain
2015-12-04 15:42:04.768 9571 ERROR nova.compute.manager [req-491a677b-118b-456d-8089-4b448420b24a b5b27e2547cb4b15968788d0416286f2 84433161b0254f5bb712d9eed6c37992 - - -] [instance: 81959887-811b-46d7-88ff-728c7be5241a] Instance failed to spawn
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a] Traceback (most recent call last):
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2473, in _build_resources
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     yield resources
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2345, in _build_and_run_instance
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     block_device_info=block_device_info)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 2388, in spawn
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     write_to_disk=True)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 4189, in _get_guest_xml
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     context)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 4060, in _get_guest_config
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     flavor, virt_type)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/vif.py", line 374, in get_config
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     _("Unexpected vif_type=%s") % vif_type)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a] NovaException: Unexpected vif_type=binding_failed
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]

nova.conf

[DEFAULT]
notification_driver=ceilometer.compute.nova_notifier
notification_driver=nova.openstack.common.notifier.rpc_notifier
notification_topics=notifications
core_plugin=ml2
rpc_backend=rabbit
network_manager = nova.network.manager.FlatDHCPManager
internal_service_availability_zone=internal
default_availability_zone=nova
my_ip=10.0.0.4
host=hpgen6
notify_api_faults=False
state_path=/var/lib/nova
report_interval=10
enabled_apis=ec2,osapi_compute,metadata
ec2_listen=0.0.0.0
ec2_workers=24
osapi_compute_listen=0.0.0.0
osapi_compute_workers=24
metadata_listen=0.0.0.0
metadata_workers=24
compute_manager=nova.compute.manager.ComputeManager
service_down_time=60
rootwrap_config=/etc/nova/rootwrap.conf
auth_strategy=keystone
use_forwarded_for=False
novncproxy_host=0.0.0.0
novncproxy_port=6080
heal_instance_info_cache_interval=60
reserved_host_memory_mb=512
network_api_class=nova.network.neutronv2 ...
(more)
2015-12-05 05:25:13 -0500 asked a question VM creation failure NovaException: Unexpected vif_type=binding_failed

VM creation is failing on my OpenStack Kilo setup on Centos7 . Below is the error message. I have also posted nova.conf, neutron.conf , ml2_conf.ini and ovs_neutron_plugin.ini configuration files.

Any help would be greatly appreciated.

2015-12-04 15:42:02.210 9571 INFO nova.compute.resource_tracker [req-9152f41d-f4fc-4901-a420-013df7f1e656 - - - - -] Compute_service record updated for hpgen6:localhost.localdomain
2015-12-04 15:42:04.768 9571 ERROR nova.compute.manager [req-491a677b-118b-456d-8089-4b448420b24a b5b27e2547cb4b15968788d0416286f2 84433161b0254f5bb712d9eed6c37992 - - -] [instance: 81959887-811b-46d7-88ff-728c7be5241a] Instance failed to spawn
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a] Traceback (most recent call last):
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2473, in _build_resources
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     yield resources
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2345, in _build_and_run_instance
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     block_device_info=block_device_info)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 2388, in spawn
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     write_to_disk=True)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 4189, in _get_guest_xml
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     context)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 4060, in _get_guest_config
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     flavor, virt_type)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/vif.py", line 374, in get_config
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]     _("Unexpected vif_type=%s") % vif_type)
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a] NovaException: Unexpected vif_type=binding_failed
2015-12-04 15:42:04.768 9571 TRACE nova.compute.manager [instance: 81959887-811b-46d7-88ff-728c7be5241a]

nova.conf

[DEFAULT]
notification_driver=ceilometer.compute.nova_notifier
notification_driver=nova.openstack.common.notifier.rpc_notifier
notification_topics=notifications
core_plugin=ml2
rpc_backend=rabbit
network_manager = nova.network.manager.FlatDHCPManager
internal_service_availability_zone=internal
default_availability_zone=nova
my_ip=10.0.0.4
host=hpgen6
notify_api_faults=False
state_path=/var/lib/nova
report_interval=10
enabled_apis=ec2,osapi_compute,metadata
ec2_listen=0.0.0.0
ec2_workers=24
osapi_compute_listen=0.0.0.0
osapi_compute_workers=24
metadata_listen=0.0.0.0
metadata_workers=24
compute_manager=nova.compute.manager.ComputeManager
service_down_time=60
rootwrap_config=/etc/nova/rootwrap.conf
auth_strategy=keystone
use_forwarded_for=False
novncproxy_host=0.0.0.0
novncproxy_port=6080
heal_instance_info_cache_interval=60
reserved_host_memory_mb=512
network_api_class=nova.network.neutronv2.api.API
default_floating_pool=public
force_snat_range=0.0.0.0/0
linuxnet_interface_driver = nova.network.linux_net.LinuxOVSInterfaceDriver
linuxnet_ovs_integration_bridge=br-int
metadata_host=10.0.0.4
dhcp_domain=novalocal
security_group_api=neutron
debug=True
verbose=True
log_dir=/var/log/nova
use_syslog=False ...
(more)
2015-11-07 07:14:04 -0500 received badge  Good Answer (source)
2015-10-25 23:36:18 -0500 received badge  Famous Question (source)
2015-09-17 22:27:22 -0500 received badge  Famous Question (source)
2015-07-28 04:56:41 -0500 received badge  Notable Question (source)
2015-07-21 07:48:08 -0500 commented answer missing cpu model

What about qemu?

2015-07-21 07:28:07 -0500 commented question How to restrict bandwidth for instances

Did you use any tool for checking the bandwidth? Could you please share the details.

2015-07-21 07:16:44 -0500 commented answer missing cpu model

Please share your hypervisorvirt_type details. Set cpu_mode=none in nova.conf and try.

Source

2015-07-21 02:12:01 -0500 answered a question How to setup a home lab accessible from public internet

If you are using NAT(port forwarding) then only one static IP is sufficient.

2015-07-21 01:30:15 -0500 commented question missing cpu model

Can you check your /usr/share/libvirt/cpu_map.xml file? Also you can run #virsh cpu-models ppc64

2015-07-21 01:18:08 -0500 received badge  Good Answer (source)
2015-07-20 09:46:48 -0500 received badge  Nice Answer (source)
2015-07-20 07:56:54 -0500 answered a question How can I create a Facebook auth login for Openstack?

Its done using OAuth2.

2015-07-13 02:31:28 -0500 received badge  Notable Question (source)
2015-07-13 02:31:28 -0500 received badge  Famous Question (source)
2015-07-13 02:31:28 -0500 received badge  Popular Question (source)
2015-07-12 04:12:36 -0500 received badge  Nice Answer (source)
2015-07-09 03:56:17 -0500 commented answer dhcp works but not stable

There should be a " BOOTP/DHCP, Reply" message from DHCP Server.

Please follow the steps provided in this article. Section: Debugging DHCP Issues with nova-network

2015-07-09 03:50:00 -0500 commented answer dhcp works but not stable

I get this output

# tcpdump -i any  port 67 or port 68 -e -n



08:36:58.845871   B fa:16:3e:e4:bb:ab ethertype 802.1Q (0x8100), length 338: vlan 1018, p 0, ethertype IPv4, 0.0.0.0.68 > 255.255.255.255.67: BOOTP/DHCP, Request from fa:16:3e:e4:bb:ab, length 290
08:36:58.845918 Out fa:16:3e:e4:bb:a
2015-07-09 03:19:36 -0500 answered a question dhcp works but not stable

Can you check for DHCP timeouts?

#tcpdump -i <interface> port 67 or port 68 -e -n
2015-07-08 07:35:08 -0500 answered a question How do I use python to call "neutron net-list"?

OpenStack provides python APIs. Please go through this document.

You can find few sample codes here.

2015-07-08 02:34:04 -0500 commented question How is DSCP supported on openstack ?

I guess it DSCP is supported through OVS QoS.

2015-07-08 02:08:32 -0500 commented question Change default (path) emulator for libvirt

Can you set the $PATH in root user's profile and try?

2015-07-07 13:51:31 -0500 received badge  Nice Answer (source)
2015-07-07 10:55:32 -0500 answered a question rejoin-stack doesnt work

Rejoin will just reconnects to the screen. Rejoin works only after running ./stack.sh