Ask Your Question
0

OpenStack Dashboard - Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS) [closed]

asked 2014-05-28 14:57:35 -0500

danoreilly gravatar image

updated 2014-05-28 15:39:29 -0500

SamYaple gravatar image

RHEL 6.5. When I installed Dashboard, I made the change to ALLOWED_HOSTS to add my system's name. When I try to login in, both Chrome and IE give me "an unexpected error has occurred". I've tried both FQDN and just the canonical name. I have no idea what's going on. Can anybody help????

The /var/log/httpd/error_log shows me:

<br>
[Wed May 28 19:13:38 2014] [error] Internal Server Error: /dashboard/<br>
[Wed May 28 19:13:38 2014] [error] Traceback (most recent call last):<br>
[Wed May 28 19:13:38 2014] [error]   File "/usr/lib/python2.6/site-packages/django/core/handlers/base.py", line 89, in get_response<br>
[Wed May 28 19:13:38 2014] [error]     response = middleware_method(request)<br>
[Wed May 28 19:13:38 2014] [error]   File "/usr/lib/python2.6/site-packages/django/middleware/common.py", line 55, in process_request<br>
[Wed May 28 19:13:38 2014] [error]     host = request.get_host()<br>
[Wed May 28 19:13:38 2014] [error]   File "/usr/lib/python2.6/site-packages/django/http/__init__.py", line 223, in get_host<br>
[Wed May 28 19:13:38 2014] [error]     "Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS): %s" % host)<br>
[Wed May 28 19:13:38 2014] [error] SuspiciousOperation: Invalid HTTP_HOST header (you may need to set ALLOWED_HOSTS): tm1cldctll01
edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by danoreilly
close date 2014-06-05 16:42:00.859436

2 answers

Sort by ยป oldest newest most voted
0

answered 2014-05-28 15:41:46 -0500

SamYaple gravatar image

In /etc/openstack-dashboard/local_settings.py you need to add your host name to the ALLOWED_HOSTS = [ .... ] section

Alternatively, for testing purposes you should set DEBUG = True. You won't need to modify the allowed hosts section while running in debug _AND_ you get much better output when Horizon encounters an error.

edit flag offensive delete link more

Comments

Hello, I am also facing the same issue. Could you help ?

bharath25191 gravatar imagebharath25191 ( 2016-11-10 17:17:26 -0500 )edit
0

answered 2014-05-28 16:03:44 -0500

danoreilly gravatar image

First of all, there's no local_settings.py file, just local_settings. Am I missing something or is this a documentation problem? Second, with DEBUG = True, what log file could I look at to see what's going on? Setting it to TRUE didn't change anything.

edit flag offensive delete link more

Comments

Did you find any solution, I am also facing the same issue

bharath25191 gravatar imagebharath25191 ( 2016-11-10 17:17:05 -0500 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-05-28 14:57:35 -0500

Seen: 5,434 times

Last updated: May 28 '14