#cd /usr/ports/databases/memcachedb #make install cleanrc.conf:
memcachedb_enable="YES"
#/usr/local/etc/rc.d/memcachedb start
#sockstat | grep 11211 nobody memcachedb 70265 15 tcp4 127.0.0.1:11211 *:* nobody memcachedb 70265 16 udp4 127.0.0.1:11211 *:*
#cd /usr/ports/databases/pecl-memcached #make install clean
#grep memcached /usr/local/etc/php/extensions.ini extension=memcached.so
#/usr/local/etc/rc.d/php-fpm restart/usr/local/etc/nginx/fastcgi_params:
fastcgi_param PHP_VALUE "session.save_handler=memcached\nsession.save_path=127.0.0.1:11211 enabled";or php.ini:
session.save_handler = memcached session.save_path=127.0.0.1:11211 enabled
#/usr/local/etc/rc.d/nginx restartcheck phpinfo():
session.save_handler | memcached | memcached |
session.save_path | 127.0.0.1:11211 enabled | 127.0.0.1:11211 enabled |
#memstat --servers localhost Server: localhost (11211) pid: 70265 uptime: 2053 time: 1371163073 version: 1.2.0 pointer_size: 64 rusage_user: 0.094042 rusage_system: 0.081473 ibuffer_size: 512 curr_connections: 5 total_connections: 107 connection_structures: 7 cmd_get: 86 cmd_set: 181 get_hits: 85 get_misses: 1 bytes_read: 33199 bytes_written: 25535 threads: 4
Посилання:
Немає коментарів:
Дописати коментар