cacti ERROR 处理

简介: 问题一:PHP Warning:  date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.
问题一:PHP Warning:  date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /usr/share/cacti/cmd.php on line 257
OK u:0.02 s:0.02 r:0.09


[root@cacti ~ ]# vim /etc/php.ini
[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = PRC
修改好后重启httpd
[root@zabbix tmp]# service httpd restart



问题2:you don't have permission to access /cacti on this server
关闭SELINUX,
添加/etc/httpd/conf.d/cacti.conf
[root@cacti ~ ] # cat /etc/httpd/conf.d/cacti.conf
#
# Cacti: An rrd based graphing tool
#

# For security reasons, the Cacti web interface is accessible only to
# localhost in the default configuration. If you want to allow other clients
# to access your Cacti installation, change the httpd ACLs below.
# For example:
# On httpd 2.4, change "Require host localhost" to "Require all granted".
# On httpd 2.2, change "Allow from localhost" to "Allow from all".

Alias /cacti    /var/www/html/cacti


       
                # httpd 2.4
                Require all granted
                #Require host localhost
       
       
                # httpd 2.2
                Order deny,allow
                Deny from all
                Allow from localhost
       



        # mod_security overrides.
        # Uncomment these if you use mod_security.
        # allow POST of application/x-www-form-urlencoded during install
        #SecRuleRemoveById 960010
        # permit the specification of the rrdtool paths during install
        #SecRuleRemoveById 900011



# These sections marked "Require all denied" (or "Deny from all")
# should not be modified.
# These are in place in order to harden Cacti.

       
                Require all denied
       
       
                Order deny,allow
                Deny from all
       


       
                Require all denied
       
       
                Order deny,allow
                Deny from all
       


问题3:
spine安装
configure: error: Cannot find MySQL headers.  Use --with-mysql= to specify non-default path.
我是使用的centos7,没有mysql
[root@zabbix cacti-spine-0.8.8f]# yum install mariadb-devel -y

问题4:
fatal error: net-snmp/net-snmp-config.h: No such file or directory
[root@zabbix cacti-spine-0.8.8f]# yum install -y net-snmp-devel

问题5:
按照官方文档中编译安装spine会出错,官方文档的手册中的libtool方式可以成功
[root@zabbix cacti-spine-0.8.8f]# yum install libtool
[root@zabbix cacti-spine-0.8.8f]# aclocal
[root@zabbix cacti-spine-0.8.8f]# libtoolize --force
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, `config'.
libtoolize: linking file `config/ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
libtoolize: linking file `m4/libtool.m4'
libtoolize: linking file `m4/ltoptions.m4'
libtoolize: linking file `m4/ltsugar.m4'
libtoolize: linking file `m4/ltversion.m4'
libtoolize: linking file `m4/lt~obsolete.m4'
libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
[root@zabbix cacti-spine-0.8.8f]# autoheader
[root@zabbix cacti-spine-0.8.8f]# autoconf
[root@zabbix cacti-spine-0.8.8f]# automake
configure.ac:12: warning: AM_INIT_AUTOMAKE: two- and three-arguments forms are deprecated.  For more info, see:
configure.ac:12: http://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_005fINIT_005fAUTOMAKE-invocation
[root@zabbix cacti-spine-0.8.8f]# ./configure && make && make install
[root@zabbix etc]# cp spine.conf.dist /etc/spine.conf
[root@zabbix etc]# vim /etc/spine.conf 修改成相应的数据库信息.
DB_Host         localhost
DB_Database     cacti
DB_User         cactiuser
DB_Pass         cactiuser
DB_Port         3306

目录
相关文章
|
应用服务中间件 PHP nginx
PHP ERROR: failed to open error_log (/usr/var/log/php-fpm.log): No such file or directory (2)
PHP ERROR: failed to open error_log (/usr/var/log/php-fpm.log): No such file or directory (2)
161 1
|
关系型数据库 MySQL 应用服务中间件
linux篇-Parse error: syntax error, unexpected ‘new’ (T_NEW) in /usr/local/nginx/html/cacti/lib/adodb
linux篇-Parse error: syntax error, unexpected ‘new’ (T_NEW) in /usr/local/nginx/html/cacti/lib/adodb
170 0
linux篇-Parse error: syntax error, unexpected ‘new’ (T_NEW) in /usr/local/nginx/html/cacti/lib/adodb
|
PHP 数据库
Warning: mysqli_connect()_php链接MySQL8.0_异常
Warning: mysqli_connect()_php链接MySQL8.0_异常
219 0
Warning: mysqli_connect()_php链接MySQL8.0_异常
|
关系型数据库 MySQL
MySQL 启动错误: [ERROR] Can't find messagefile '/usr/share/errmsg.sys'(转载)
110623 21:49:41 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql 110623 21:49:41 [ERROR] Can't find messagefile '/usr/share/errmsg.
5152 0
|
JavaScript 关系型数据库 MySQL
|
关系型数据库 PHP Ubuntu
|
关系型数据库 PHP Ubuntu
|
监控 数据安全/隐私保护
|
SQL 关系型数据库 PHP