1

通常我使用 NAT 仅用于 Internet 访问,使用 packstack 时用于 openstack 管理 ip 的 Hostonly 私有接口,从笔记本电脑主机访问仪表板工作正常。

今天我直接在 NAT 上安装了 packstack,从 CLI 一切正常,但仪表板除外。

2: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 08:00:27:cb:a7:ab brd ff:ff:ff:ff:ff:ff
inet 10.0.2.15/24 brd 10.0.2.255 scope global dynamic enp0s3

我为 NAT 设置端口转发:

127.0.0.1: 2080 to guest 80

然后我可以访问http://127.0.0.1:2080但不能访问http://127.0.0.1:2080/dashboard,出现错误:

404 Not Found
The requested URL /dashboard/ was not found on this server.

事实上,虚拟机内的仪表板也无法正常工作,

[root@localhost ~(keystone_admin)]# curl http://10.0.2.15/dashboard
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>500 Internal Server Error</title>
</head><body>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator at
[no address given] to inform them of the time this error occurred,
and the actions you performed just before this error.</p>
<p>More information about this error may be available
in the server error log.</p>
</body></html>

所以看起来问题出在节点内部,而不是端口转发。

检查 /etc/httpd/conf.d/15-horizo​​n_vhost.conf

## Server aliases
ServerAlias 10.0.2.15
ServerAlias localhost
ServerAlias localhost
4

0 回答 0