The last notes
All English-language materials have been translated fully automatically using the Google service
Making settings in Bitrix
Editing the file /bitrix/php_interface/dbconn.php
define("BX_CACHE_TYPE", "memcache");
define("BX_CACHE_SID", $_SERVER["DOCUMENT_ROOT"]."#01");
define("BX_MEMCACHE_HOST", "127.0.0.1");
define("BX_MEMCACHE_PORT", "11211");
Editing the file /bitrix/.settings.php
. If this section is in the file, then we bring it to the form, if there is no section, then add:
'cache' => array(
'value' => array (
'type' => 'memcache',
'sid' => $_SERVER["DOCUMENT_ROOT"]."#01",
'memcache' => array(
'host' => '127.0.0.1',
'port' => '11211',
),
),
'readonly' => false,
),
You can also create a file /bitrix/.settings_extra.php
return array(
'cache' => array(
'value' => array(
'type' => 'memcache',
'memcache' => array(
'host' => '127.0.0.1',
'port' => '11211',
),
'sid' => $_SERVER["DOCUMENT_ROOT"]."#01"
),
),
);
Editing the server side:
In the bitrixvm
control panel, activate the composite mode according to documentation
Set memcached
to BitrixVM
yum -y install memcached
In the file / etc / sysconfig / memcached
, replace the line OPTIONS
with:
OPTIONS = "- l 127.0.0.1"
We start the service
service memcached start
Adding memchaced
to startup
chkconfig memcached on
You may need to install the PHP-memcache
library, which is installed on BitrixVM
by default
yum -y install php-pecl-memcache
Bitrix memcached documentation
Clear cache memcached
Via telnet
telnet localhost 11211
flush_all
quit
Via netcat
echo "flush_all" | nc localhost 11211
Comments