我在我的VM上安装了monitorix,并按如下方式设置conf文件:

# Monitorix - configuration file
#
# See monitorix.conf(5) manpage for a detailed description of each option.
#

title = MonitorIX
hostname = <host_ip>
theme_color = black
refresh_rate = 150
iface_mode = graph
enable_zoom = y
netstats_in_bps = n
disable_javascript_void = n
temperature_scale = c
show_gaps = n
global_zoom = 1
max_historic_years = 1
accept_selfsigned_certs = y
image_format = PNG
include_dir = /etc/monitorix/conf.d

base_dir = /var/lib/monitorix/www/
base_lib = /var/lib/monitorix/
base_url = /monitorix
base_cgi = /monitorix-cgi

<httpd_builtin>
        enabled = y
        host =
        port = 8000
        user = nobody
        group = nobody
        log_file = /var/log/monitorix-httpd
        hosts_deny = all
        hosts_allow = <host_ip>
        <auth>
                enabled = n
                msg = Monitorix: Restricted access
                htpasswd = /var/lib/monitorix/htpasswd
        </auth>
</httpd_builtin>


# Log files pathnames
# -----------------------------------------------------------------------------
log_file        = /var/log/monitorix
secure_log      = /var/log/secure
mail_log        = /var/log/maillog
milter_gl       = /var/milter-greylist/greylist.db
imap_log        = /var/log/imap
hylafax_log     = /var/spool/hylafax/etc/xferfaxlog
cups_log        = /var/log/cups/page_log
ftp_log         = /var/log/proftpd/access.log
fail2ban_log    = /var/log/fail2ban.log
spamassassin_log        = /var/log/maillog
clamav_log      = /var/log/clamav/clamav.log
cg_logdir       = /var/CommuniGate/SystemLogs/
squid_log       = /var/log/squid/access.log

imap_log_date_format = %b %d
secure_log_date_format = %b %e

现在,我尝试从浏览器启动它,得到以下错误:
被禁止的
您没有访问/监视此服务器的权限。
在本地主机端口8000侦听的Monitorix HTTP服务器

最佳答案

试试这个:

chmod 755 -R  /var/lib/monitorix/www/

关于linux - 我尝试设置monitorix并收到错误消息:您无权访问此服务器上的/monitorix,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/44413754/

10-10 09:06