Ask Your Question
0

Ocata The placement API endpoint not found on Ubuntu

asked 2017-03-08 01:28:32 -0500

hb.deng gravatar image

Hello. I am here again,Last time I have try to install Ocata on Cenots 7,get placement API problem and fix it at last. But I stil get placement API try to install Ocata on Ubuntu.
I have apt-get install nova-placement-api and apache2 site seems work.
Listen 8778
<virtualhost *:8778="">
WSGIScriptAlias / /usr/bin/nova-placement-api
Seems I should create service endbpoint like this:
openstack service create --name placement --description "OpenStack Placement" placement
openstack endpoint create --region RegionOne placement public http://controller:8778
openstack endpoint create --region RegionOne placement admin http://controller:8778
openstack endpoint create --region RegionOne placement internal http://controller:8778

But when I restart nova service, I get the follow error:
2017-03-08 15:16:00.930 22919 WARNING nova.scheduler.client.report [req-70d8f814-a975-4fb4-adf2-647152f94c5f - - - - -] The placement API endpoint not found. Placement is optional in Newton, but required in Ocata. Please enable the placement service before upgrading.

root@controller:/var/log/nova# nova-status upgrade check +-------------------------------------------------------------------
| Upgrade Check Results
+-------------------------------------------------------------------
| Check: Cells v2
| Result: Success
| Details: None
+-------------------------------------------------------------------
| Check: Placement API
| Result: Failure
| Details: Placement API endpoint not found.
+-------------------------------------------------------------------
| Check: Resource Providers
| Result: Warning
| Details: There are no compute resource providers in the Placement
| service but there are 1 compute nodes in the deployment.
| This means no compute nodes are reporting into the
| Placement service and need to be upgraded and/or fixed.
| See
| http://docs.openstack.org/developer/nova/placement.html (http://docs.openstack.org/developer/n...)
| for more details.
+-------------------------------------------------------------------

I even try endpoint like http://controller:8778/placement ,http://controller:8780/placement,http://controller:8780,but still get same issue. and tcpdump -i any portrange 8700-8799 show nothing.Is there any step for setup Ocata send Placement API request?

edit retag flag offensive close merge delete

Comments

1

If you used the installation guide on docs.openstack.org, it seems to have gaps regarding cells and placement API.

Bernd Bausch gravatar imageBernd Bausch ( 2017-03-08 20:13:30 -0500 )edit

4 answers

Sort by ยป oldest newest most voted
0

answered 2017-04-26 15:30:16 -0500

prakashrao gravatar image

followed openstack ocata installation on ubuntu from this link.I have multinode environment with 3 nodes.One controller node running network services too and two compute nodes

https://docs.openstack.org/ocata/install-guide-ubuntu/nova-controller-install.html (https://docs.openstack.org/ocata/inst...) (https://docs.openstack.org/ocata/inst...)

After following the instructions i could not get placement service up on controller node.I then had to follow https://review.openstack.org/#/c/438328/15/doc/install-guide/source/nova-controller-install.rst (https://review.openstack.org/#/c/4383...) (https://review.openstack.org/#/c/4383...) specifically for configuration related to placement service and made some changes related to creation of placement endpoints.I had to use http://controller:8778 instead of http://controller/placement as documented in the instllation guide

After making changes the placement api status is success on controller node but compute nodes still give errors that placement-api is

CONTROLLER root@perfcontroller:~# nova-status upgrade check +-------------------------------------------------------------------+ | Upgrade Check Results | +-------------------------------------------------------------------+ | Check: Cells v2 | | Result: Success | | Details: None | +-------------------------------------------------------------------+ | Check: Placement API | | Result: Success | | Details: None | +-------------------------------------------------------------------+ | Check: Resource Providers | | Result: Warning | | Details: There are no compute resource providers in the Placement | | service but there are 2 compute nodes in the deployment. | | This means no compute nodes are reporting into the | | Placement service and need to be upgraded and/or fixed. | | See | | http://docs.openstack.org/developer/nova/placement.html (http://docs.openstack.org/developer/n...) (http://docs.openstack.org/developer/n...) | | for more details. | +----------------------------------------------------------

COMPUTE Node

On restart nova-compute service i get this

/var/log/nova-compute.log 017-04-24 14:33:59.315 3644 WARNING nova.compute.monitors [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] Excluding nova.compute.monitors.cpu monitor virt_driver. Not in the list of enabled monitors (CONF.compute_monitors). 2017-04-24 14:34:03.164 3644 WARNING nova.scheduler.client.report [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] The placement API endpoint not found. Placement is optional in Newton, but required in Ocata. Please enable the placement service before upgrading. 2017-04-24 14:34:03.166 3644 WARNING nova.scheduler.client.report [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] Unable to refresh my resource provider record 2017-04-24 14:34:03.286 3644 INFO nova.compute.resource_tracker [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] Final resource view: name=perfcompute1 phys_ram=128826MB used_ram=512MB phys_disk=789GB used_disk=0GB total_vcpus=32 used_vcpus=0 pci_stats=[]

nova.conf on compute node and controller node [placement] os_region_name = RegionOne project_domain_name = Default project_name = service auth_type = password user_domain_name = Default auth_url = http://perfcontroller:35357/v3 username = placement password = abc123

If i try to launch any instance i am getting "No Valid hosts" error

Any help is appreciated!

edit flag offensive delete link more

Comments

Finally it worked for me following https://ask.openstack.org/en/question/105800/ocatathe-placement-api-endpoint-not-found-placement-is-optional-in-newton-but-required-in-ocata-please-enable-the-placement-service-before-upgrading/#.There (https://ask.openstack.org/en/question...) is a line in default nova.conf that needs to be commented out!

prakashrao gravatar imageprakashrao ( 2017-05-15 17:46:50 -0500 )edit
0

answered 2017-04-24 16:56:14 -0500

prakashrao gravatar image

updated 2017-04-24 22:16:59 -0500

I followed openstack ocata installation on ubuntu from this link.I have multinode environment with 3 nodes.One controller node running network services too and two compute nodes https://docs.openstack.org/ocata/inst....

After following the instructions i could not get placement service up on controller node.I then had to follow https://review.openstack.org/#/c/4383... (https://review.openstack.org/#/c/4383...) specifically for configuration related to placement service and made some changes related to creation of placement endpoints.I had to use http://controller:8778 instead of http://controller/placement as documented in the instllation guide

After making changes the placement api status is success on controller node but compute nodes still give errors that placement-api is

CONTROLLER

root@perfcontroller:~# nova-status upgrade check 
+-------------------------------------------------------------------+ 
| Upgrade Check Results | 
+-------------------------------------------------------------------+ 
| Check: Cells v2 | 
| Result: Success | 
| Details: None | 
+-------------------------------------------------------------------+
| Check: Placement API | 
| Result: Success | 
| Details: None | 
+-------------------------------------------------------------------+ 
| Check: Resource Providers | 
| Result: Warning | 
| Details: There are no compute resource providers in the Placement | 
| service but there are 2 compute nodes in the deployment. | 
| This means no compute nodes are reporting into the | 
| Placement service and need to be upgraded and/or fixed. |
| See | 
| http://docs.openstack.org/developer/nova/placement.html | 
| for more details. | 
+----------------------------------------------------------

COMPUTE Node

On restart nova-compute service i get this

/var/log/nova-compute.log 017-04-24 14:33:59.315 3644 WARNING nova.compute.monitors [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] Excluding nova.compute.monitors.cpu monitor virt_driver. Not in the list of enabled monitors (CONF.compute_monitors). 
2017-04-24 14:34:03.164 3644 WARNING nova.scheduler.client.report [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] The placement API endpoint not found. Placement is optional in Newton, but required in Ocata. Please enable the placement service before upgrading. 
2017-04-24 14:34:03.166 3644 WARNING nova.scheduler.client.report [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] Unable to refresh my resource provider record 
2017-04-24 14:34:03.286 3644 INFO nova.compute.resource_tracker [req-9a917ab1-9caf-4fab-a9df-50763f8946dd - - - - -] Final resource view: name=perfcompute1 phys_ram=128826MB used_ram=512MB phys_disk=789GB used_disk=0GB total_vcpus=32 used_vcpus=0 pci_stats=[]

nova.conf on compute node and controller node

[placement] 
os_region_name = RegionOne 
project_domain_name = Default 
project_name = service 
auth_type = password 
user_domain_name = Default 
auth_url = http://perfcontroller:35357/v3 
username = placement 
password = abc123

If i try to launch any instance i am getting "No Valid hosts" error

edit flag offensive delete link more

Comments

On my packstack-based installation, Placement runs as follows:

$ ps -ef|grep placement
nova      2424   625  0 03:21 ?        00:00:53 placement_wsgi  -DFOREGROUND

If it doesn't run on your controller, check the Nova log files for startup errors.

Bernd Bausch gravatar imageBernd Bausch ( 2017-04-24 22:22:27 -0500 )edit

If it does run, and you see it listening on port 8778, run openstack catalog list to see the placement API endpoint. Try to find out why the compute nodes can't access that endpoint (e.g. on the compute nodes, get a token using placement authentication and use it to access the endpoint via curl).

Bernd Bausch gravatar imageBernd Bausch ( 2017-04-24 22:25:12 -0500 )edit

Perhaps debug logging provides more info. Enable it if you haven't done it yet.

Bernd Bausch gravatar imageBernd Bausch ( 2017-04-24 22:35:35 -0500 )edit
0

answered 2018-07-16 05:49:48 -0500

hey there it not so complicated just open these ports on controller(s) 5000,5672,8778 (tcp & udp)

REMEMBER in centos 7 you (can't do that from iptables!) use:

firewall-cmd --zone=public --add-port=5000/tcp --permanent firewall-cmd --reload

edit flag offensive delete link more
0

answered 2017-03-08 10:11:55 -0500

hb.deng gravatar image

updated 2017-03-08 10:26:49 -0500

I'am here to update this issue. I have try copy /etc/nova/nova.conf from another Ubuntu. Seems fix this issue.Here is my new config file(Default Ubuntu nova.conf file have some issue I am not very clearly now).
[DEFAULT]
vif_plugging_timeout = 300
vif_plugging_is_fatal = True
use_neutron = True
firewall_driver = nova.virt.firewall.NoopFirewallDriver
#compute_driver = libvirt.LibvirtDriver
#default_ephemeral_format = ext4
#pointer_model = ps2mouse
#dhcpbridge_flagfile = /etc/nova/nova-dhcpbridge.conf
graceful_shutdown_timeout = 5
metadata_workers = 2
osapi_compute_workers = 2
transport_url = rabbit://openstack:RABBIT_PASS@controller
instances_path = /var/lib/nova/instances/
state_path = /var/lib/nova
enabled_apis = osapi_compute,metadata
metadata_listen = 0.0.0.0
osapi_compute_listen = 0.0.0.0
#instance_name_template = instance-%08x
my_ip = 10.10.10.26
default_floating_pool = public
scheduler_default_filters = AllHostsFilter
#scheduler_default_filters = RetryFilter,AvailabilityZoneFilter,RamFilter,DiskFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,ServerGroupAntiAffinityFilter,ServerGroupAffinityFilter,SameHostFilter,DifferentHostFilter
scheduler_driver = filter_scheduler
rootwrap_config = /etc/nova/rootwrap.conf
allow_resize_to_same_host = True
debug = True
capabilities=hypervisor=qemu,os=linux;window
[wsgi]
api_paste_config = /etc/nova/api-paste.ini

[database]
connection = mysql+pymysql://nova:NOVA_DBPASS@controller/nova?charset=utf8

[api_database]
connection = mysql+pymysql://nova:NOVA_DBPASS@controller/nova_api?charset=utf8

[keystone_authtoken]
auth_uri = http://controller:5000
auth_url = http://controller:35357
memcached_servers = 10.10.10.26:11211
signing_dir = /var/cache/nova
#cafile = /opt/stack/data/ca-bundle.pem
#auth_uri = http://10.10.10.26/identity
project_domain_name = Default
project_name = service
user_domain_name = Default
password = abc123.
username = nova
#auth_url = http://10.10.10.26/identity_admin
auth_type = password

[oslo_concurrency]
lock_path = /var/lib/nova/tmp

[vnc]
xvpvncproxy_host = 0.0.0.0
novncproxy_host = 0.0.0.0
vncserver_proxyclient_address = controller
vncserver_listen = controller
xvpvncproxy_base_url = http://10.10.10.26:6081/console
novncproxy_base_url = http://10.10.10.26:6080/vnc_auto.html

[spice]
html5proxy_base_url = http://10.10.10.26:6082/spice_auto.html

[oslo_messaging_notifications]
driver = messaging

[glance]
api_servers = http://10.10.10.26:9292

[conductor]
workers = 2

[cinder]
os_region_name = RegionOne

[libvirt]
#live_migration_uri = qemu+ssh://stack@%s/system
#cpu_mode = none
#virt_type = qemu
virt_type = qemu

[placement]
os_region_name = RegionOne
project_domain_name = Default
project_name = service
user_domain_name = Default
password = abc123.
username = placement
auth_url = http://10.10.10.26:35357/v3
auth_type = password

[neutron]
service_metadata_proxy = True
url = http://10.10.10.26:9696
region_name = RegionOne
auth_strategy = keystone
project_domain_name = Default
project_name = service
user_domain_name = Default
password = abc123.
username = neutron
auth_url = http://controller:35357
auth_type = password

[key_manager]
#fixed_key = c90a3ae875ca80658cd3498d2527517a20764f3e9d2c8ea1092136c44863b9fa



vi default nova.conf case this issue.And I still do not know what wrong with it. May help some one get the same issue.

edit flag offensive delete link more

Comments

under the placement section, project_domain_name has to be 'default' or 'Default'. Or is the case immaterial?

DarkKnight gravatar imageDarkKnight ( 2017-04-25 03:47:54 -0500 )edit

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

2 followers

Stats

Asked: 2017-03-08 01:28:32 -0500

Seen: 5,992 times

Last updated: Apr 26 '17