Home  >  Article  >  Backend Development  >  用共享内存解决MYSQL数据库的压力,可行不?解决办法

用共享内存解决MYSQL数据库的压力,可行不?解决办法

WBOY
WBOYOriginal
2016-06-13 13:50:35825browse

用共享内存解决MYSQL数据库的压力,可行不?
现在的服务器内存都比较大,用共享内存解决MYSQL数据库的压力,可行不呢。
共享内存用来存些非常及时的数据,比如聊天的数据。不知道PHP的共享内存稳定不?

------解决方案--------------------
1、PHP的共享内存函数随操作系统的不同,而不同
2、第三方的 memcached 需安装 memcached 服务和扩展,不是一定能搞好的。另外操作 memcached 的代码 开销 远比操作 mysql 来的大
3、内存表只是表类型不同,操作上与其他类型的表是一样的

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn