用 yum 安装 MRTG 並设定好之后也把 apache 的 httpd.conf 加上 mrtg 的目录,但 http://server/mrtg 卻一直出現 403 Forbidden。
在 httpd.conf 怎麼看都找不出哪裡有問題,後來才發現套件會自動在 /etc/httpd/conf.d/下安裝 mrtg.conf。(這雖然這個的確很貼心)

#
# This configuration file maps the mrtg output (generated daily)
# into the URL space. By default these results are only accessible
# from the local host.
#
Alias /mrtg /var/www/html/mrtg

<Location /mrtg>
Order deny,allow
Deny from all
Allow from 127.0.0.1
Allow from ::1
# Allow from .example.com
</Location>

修改mrtg.conf 为

Alias /mrtg /var/www/html/mrtg

<Location /mrtg>
# Order deny,allow
# Deny from all
Order allow,deny
Allow from all
Allow from 127.0.0.1
Allow from ::1
# Allow from .example.com
</Location>

后重新启动httpd(service httpd restart)正常访问。

最新文章

  1. android 两种实现计时器时分秒的实现,把时间放在你的手中~
  2. ASP.NET Web API 控制器执行过程(一)
  3. webpack构建vue项目(再谈配置)
  4. C#刨根究底:《你必须知道的.NET》读书笔记系列
  5. SqlServer--模糊查询-通配符
  6. oracle之集合操作函数---minus、union、intersect
  7. 正则匹配&lt;{$vcode}&gt;变量
  8. jsp中的&lt;jsp:setProperty&gt;中的param属性
  9. 烂泥:CentOS安装及配置TFTP服务器
  10. 第一次学习QT
  11. js中定义对象的方式有哪些?
  12. HOJ 1096 Divided Product (DFS)
  13. WdatePicker日历控件使用方法(转)
  14. Linux 下开启ssh服务(转)
  15. oracle与sqlserver利用函数生成年月日加流水号
  16. what is yaml ?
  17. js小函数工具
  18. zabbix之 zabbix server 跟 agent 更换ip地址
  19. inst_for_mysql5.7.sh
  20. BBS--后台管理页面,编辑文章,xss攻击

热门文章

  1. 协程概念,原理及实现(c++和node.js实现)
  2. CommandBehavior.CloseConnection使用
  3. C#——反射动态创建类的实例
  4. 错误处理:vmware下克隆centos7配置静态ip地址网卡问题
  5. java_servlet执行流程和生命周期
  6. CAD处理键盘按钮被释放(com接口VB语言)
  7. C# MVC ajax上传 文件
  8. linux常用命令--ubuntu
  9. C#工具帮助类
  10. RESTful API - 介绍