APC正常运行时间很短

APC正常运行时间很短

本文介绍了APC正常运行时间很短的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的服务器信息:

  • APC版本:3.1.9
  • PHP版本:5.2.17
  • 服务器:LiteSpeed
  • PHP:DSO.
  • cPanel:是的.
  • WHM:是的.

我很少打开apc.php,我通常在高峰流量下打开它,每天大约3-6次.我大部分时间都在打开它,正常运行时间很短,范围从20分钟到5个小时不等.但是,我从未收到过任何错误电子邮件,例如Litespeed自行重新启动时.

I rarely open my apc.php, i usually open it on my peak traffic, about 3-6 times a day.Most of the time i open it, uptime is low, ranged from 20 minutes to 5 hours. However i've never received any error e-mail such as when my Litespeed restarts by itself.

  • APC内存使用率很低,为10-25%.
  • 碎片也很低,< 1%.

这是我的APC设置.

apc.cache_by_default    1
apc.canonicalize    1
apc.coredump_unmap  0
apc.enable_cli  1
apc.enabled 1
apc.file_md5    0
apc.file_update_protection  2
apc.filters
apc.gc_ttl  3600
apc.include_once_override   0
apc.lazy_classes    0
apc.lazy_functions  0
apc.max_file_size   20M
apc.mmap_file_mask
apc.num_files_hint  1000
apc.preload_path
apc.report_autofilter   0
apc.rfc1867 0
apc.rfc1867_freq    0
apc.rfc1867_name    APC_UPLOAD_PROGRESS
apc.rfc1867_prefix  upload_
apc.rfc1867_ttl 3600
apc.serializer  default
apc.shm_segments    1
apc.shm_size    512M
apc.slam_defense    1
apc.stat    0
apc.stat_ctime  0
apc.ttl 0
apc.use_request_time    1
apc.user_entries_hint   4096
apc.user_ttl    7200
apc.write_lock  1

我可以做些什么来延长正常运行时间吗?我的另一个小问题是,当APC重新启动时,其缓存是否被刷新了?

Is there anything i can do to make uptime longer?And my other little question is, when APC restarts itself, is its cache flushed?

推荐答案

在litespeed论坛上询问后,这是因为我的Litespeed似乎每1-2小时重新启动一次.我的托管人说,LiteSpeed每1-2小时重新启动一次是为了在处理统计信息时轮换访问日志.我的服务器上的管道日志记录已启用,可以解决此问题.

After i asked on litespeed forum, it is because my Litespeed seems restarted every 1-2 hours. My hosting said that the reason that LiteSpeed restarts every 1-2 hours is in order to rotate the access logs when processing statistics. Piped logging on my server has been enabled to fix this issue.

这篇关于APC正常运行时间很短的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-23 05:58