error 503 centreon 如何正确重定向这个

error 503 centreon how can redirect properly this

当我尝试连接我的地址时 172.16.16.170:5000 这是我得到的页面,我不知道如何修复,我认为这是配置错误,但我现在不知道在哪里。我在 apache2 中配置端口,现在出现了一个页面,但 steal 不工作,我重新启动 apache2 和 centreon 服务,然后重新启动我的服务器

问我是否需要更多信息我不知道该怎么做

如果您正处于使用 Debian 9 安装 Centreon 19.04.01 的第一步,您可以检查此后的不同操作并检查您的操作可能遗漏了什么。

> groupadd -g 6000 centreon useradd -u 6000 -g centreon -m -r -d
> /var/lib/centreon -c "Centreon Admin" -s /bin/bash centreon
> usermod -aG centreon centreon-broker

您需要 PHP 7.1 和最近发布的 Centreon。

apt-get install apt-transport-https lsb-release ca-certificates -y
wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg
echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" >> /etc/apt/sources.list.d/php.list
apt-get update
apt-get install php7.1 php7.1-opcache libapache2-mod-php7.1 php7.1-mysql php7.1-curl php7.1-json php7.1-gd php7.1-mcrypt php7.1-intl php7.1-mbstring php7.1-xml php7.1-zip php7.1-fpm php7.1-readline -y

您需要更多的 Debian 9 软件包,Centreon 团队建议使用 MariaDB 数据库。

apt-get install php7.1-sqlite3 php-pear sudo tofrodos bsd-mailx lsb-release mariadb-server libconfig-inifiles-perl libcrypt-des-perl libdigest-hmac-perl libdigest-sha-perl libgd-perl php7.1-ldap php7.1-snmp php-db php-date -y

模块激活

a2enmod proxy_fcgi setenvif proxy rewrite
a2enconf php7.1-fpm
a2dismod php7.1
systemctl restart apache2 php7.1-fpm

在 Centreon 设置期间,日期时区现在是强制性的。

vi /etc/php/7.1/fpm/php.ini

[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = America/Toronto

安装PHP作曲家

php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
php composer-setup.php --install-dir=/usr/bin --filename=composer
composer install --no-dev --optimize-autoloader

安装Javascript依赖项

apt-get install curl
curl -sL https://deb.nodesource.com/setup_8.x | bash -
apt-get install -y nodejs
npm install
npm run build

使用 install.sh 脚本启动 Centreon 安装应该很好。

之后,在尝试访问 Web 前端之前,您必须允许为您的 Apache Web 服务器配置 Centreon。

a2enconf centreon.conf

建议将 Centreon 日志文件与其他文件分开。

vi /etc/apache2/conf-available/centreon.conf

在 Directory 指令后添加这两行。

ErrorLog /var/log/apache2/error.centreon.log
CustomLog /var/log/apache2/access.centreon.log combined

Apache 重新启动后,现在会创建两个单独的日志文件。

ls -l /var/log/apache2/*.centreon.log
-rw-r--r-- 1 root root   0 janv. 30 17:39 /var/log/apache2/access.centreon.log
-rw-r--r-- 1 root root 243 janv. 30 17:39 /var/log/apache2/error.centreon.log

重启会议

systemctl restart apache2 php7.1-fpm

然后再次尝试到达您的 Centreon URL