当查看 Graphite 中的 statsd 数据时,图表显示当前时间是 future 两个小时。例如,如果我们在上午 9:00 查看 Graphite ,图表会告诉我们现在是上午 11:00。数据按照应有的方式排列 - 如果我们在上午 9:00 有 99 个事件,那么我们可以在上午 11:00 在图表上看到这 99 个事件。
运行 statsd 的主机上的时钟是正确的,我们尝试停止和启动 statsd 进程。关于在哪里解决这个问题还有其他建议吗?
最佳答案
通过创建此文件修复(因为我们在加利福尼亚州)
$ cat /opt/graphite/webapp/graphite/local_settings.py
# Set your local timezone (django will *try* to figure this out automatically)
# If your graphs appear to be offset by a couple hours then this probably
# needs to be explicitly set to your local timezone.
TIME_ZONE = 'America/Los_Angeles'
找到答案here
关于linux - statsd 当前时间是 future 两个小时——如何解决?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16662139/