前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >Gentoo 安装Cacti 错误

Gentoo 安装Cacti 错误

作者头像
星哥玩云
发布2022-06-29 21:17:34
9450
发布2022-06-29 21:17:34
举报
文章被收录于专栏:开源部署开源部署

1.cacti 安装时区出错

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 /var/www/localhost/htdocs/cacti/lib/functions.php on line 486 02/11/2014 06:25:10 AM - SYSTEM STATS: Time:0.1238 Method:cmd.php Processes:1 Threads:N/A Hosts:2 HostsPerProcess:2 DataSources:1 RRDsProcessed:1 OK u:0.00 s:0.00 r:0.02 解决如下

vim /etc/php/cli-php5.5/php.ini

date.timezone = Asia/Shanghai

vim /etc/php/apache2-php5.5/php.ini

date.timezone = Asia/Shanghai

2.安装cacti-spine emerge -avq cacti-spine

登陆cacti后设置

Poller Type

The poller type to use. This setting will take effect at next polling interval. spine (默认是cmd.php)

3.收集的时候出现

POLLER: Poller[0] Maximum runtime of 300 seconds exceeded. Exiting http://chinaapp.sinaapp.com/thread-tag/poller-poller0-maximum-runtime-of-298-seconds-exceeded-exiting 报错的原因是因为: cacti php crontab里面默认执行时间超过了300秒,而cacti默认是5分钟就是300秒去获取一次数据,所以导致有些服务器的数据没有获取。 所以想到了增大spine的进程和线程数。 cacti->Console->setting->Poller->: 修改cacti setting的poller设置. settting–>poller: Maximum Concurrent Poller Processes 把1改成4 Maximum Threads per Process 把1改成2 Number of PHP Script Servers 把1改成6 即可 4.crontab -l

*/1 * * * * /usr/bin/php /var/www/localhost/htdocs/cacti/poller.php --force &>/dev/null

5.Settings--poller

Poller Interval The polling interval in use. This setting will effect how often rrd's are checked and updated. NOTE: If you change this value, you must re-populate the poller cache. Failure to do so, may result in lost data. every minute

Cron Interval The cron interval in use. You need to set this setting to the interval that your cron or scheduled task is currently running. every minute

不能正常出图,注意查看日志 Console -> Utilities -> View Cacti Log File

本文参与?腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客?前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与?腾讯云自媒体同步曝光计划? ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档
http://www.vxiaotou.com