简体   繁体   English

PHP Opcode缓存在硬盘中?

[英]PHP Opcode cached in hard disk?

I have websites developed in PHP. 我有用PHP开发的网站。 Im using Opcode cache. 我正在使用操作码缓存。

But because Opcode cache like eAccelerator or APC is cached in RAM, I needs too much RAM. 但是由于操作码缓存(例如eAccelerator或APC)缓存在RAM中,因此我需要太多RAM。

So Im looking for any project or technique which cache the PHP Opcode in hard disk. 因此,我正在寻找将PHP Opcode缓存在硬盘中的任何项目或技术。

Thanks so much 非常感谢

(my website is not generate money, so Im thinking about cheaper solution) (我的网站不赚钱,所以我正在考虑更便宜的解决方案)

all op-code caches allow you to configure the maximum size of shared memory used (look for a configuration option with shm - for SHared Memory - in the name, eg. apc.shm_size ). 所有操作码缓存允许您配置使用的共享内存的最大尺寸(寻找与SHM配置选项- 共享内存 -在名称,例如。 apc.shm_size )。 so you can control that they don't use too much ram. 这样您就可以控制他们不使用过多的内存。

some caches also allow you to cache on disk instead/besides of caching in ram: 一些缓存还允许您缓存在磁盘上,而不是在ram中进行缓存:

the question is if a small amount of shared memory or a disk only cache gains you anything in performance compared to plain php without op-code cache. 问题是,与没有操作码缓存的普通php相比,少量的共享内存或仅磁盘缓存可以为您带来任何性能提升。 as always when using a cache, you should benchmark this. 与使用缓存时一样,您应该对此进行基准测试。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM