nova_placement in unhealthy state in containerized overcloud
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
tripleo |
Fix Released
|
Medium
|
Jose Luis Franco |
Bug Description
After deploying a containerized overcloud (Queens and master), the nova_placement containers appears in "unhealthy" state (observed in a local installation as well as in the CI jobs):
babc9cbb7fe3 192.168.
Queens job: Log: http://
Master job: Log: http://
When checking the error logs inside the container for the vhost, we can see the following log printed out multiple times in the /var/log/
[Wed Jul 11 11:53:14.091902 2018] [autoindex:error] [pid 20] [client 172.16.2.5:58606] AH01276: Cannot serve directory /var/www/
[Wed Jul 11 11:53:44.207633 2018] [autoindex:error] [pid 20] [client 172.16.2.5:58954] AH01276: Cannot serve directory /var/www/
And the /openstack/
172.16.2.5 - - [11/Jul/
172.16.2.5 - - [11/Jul/
172.16.2.5 - - [11/Jul/
172.16.2.5 - - [11/Jul/
172.16.2.5 - - [11/Jul/
The content of the /etc/httpd/
<VirtualHost 172.16.2.5:8778>
ServerName overcloud-
## Vhost docroot
DocumentRoot "/var/www/
## Directories, there should at least be a declaration for /var/www/
<Directory "/var/www/
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Require all granted
</Directory>
## Logging
ErrorLog "/var/log/
ServerSignature Off
CustomLog "/var/log/
SetEnvIf X-Forwarded-Proto https HTTPS=1
WSGIApplicati
WSGIDaemonProcess placement-api display-
WSGIProcessGroup placement-api
WSGIScriptAlias /placement "/var/www/
</VirtualHost>
When sending the same HTTP request done by /openstack/ healthcheck we get a 403:
()[root@ overcloud- controller- 0 /]# curl -v -g -k -q --fail --max-time 10 --user-agent curl-healthceck http:// overcloud- controller- 0.internalapi. localdomain: 8778 controller- 0.internalapi. localdomain port 8778 (#0) controller- 0.internalapi. localdomain (172.16.2.5) port 8778 (#0) controller- 0.internalapi. localdomain: 8778 overcloud- controller- 0.internalapi. localdomain: 8778/): response: 403, time: 0.006, size: 0
* About to connect() to overcloud-
* Trying 172.16.2.5...
* Connected to overcloud-
> GET / HTTP/1.1
> User-Agent: curl-healthceck
> Host: overcloud-
> Accept: */*
>
* The requested URL returned error: 403 Forbidden
* Closing connection 0
curl (http://
curl: (22) The requested URL returned error: 403 Forbidden
But adding the /placement/ directory at the end of the URI, as defined in the WSGIScriptAlias seems to return a 201:
()[root@ overcloud- controller- 0 /]# curl -v -g -k -q --fail --max-time 10 --user-agent curl-healthceck http:// overcloud- controller- 0.internalapi. localdomain: 8778/placement/ controller- 0.internalapi. localdomain port 8778 (#0) controller- 0.internalapi. localdomain (172.16.2.5) port 8778 (#0) controller- 0.internalapi. localdomain: 8778 API-Version: placement 1.0 API-Version, Accept- Encoding request- id: req-90eaa18e- 5e4c-47b1- 9ab1-932e0e98bb 38 controller- 0.internalapi. localdomain left intact overcloud- controller- 0.internalapi. localdomain: 8778/placement/): response: 200, time: 0.009, size: 75
* About to connect() to overcloud-
* Trying 172.16.2.5...
* Connected to overcloud-
> GET /placement/ HTTP/1.1
> User-Agent: curl-healthceck
> Host: overcloud-
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Mon, 16 Jul 2018 06:44:14 GMT
< Server: Apache
< OpenStack-
< vary: OpenStack-
< x-openstack-
< Content-Length: 75
< Content-Type: application/json
<
* Connection #0 to host overcloud-
{"versions": [{"min_version": "1.0", "max_version": "1.17", "id": "v1.0"}]}curl (http://
The error is in the WSGIScriptAlias value defined in puppet-nova.