The new updated mod_lsapi version 1.1-4 and criu-lve version 2.7-9 for CloudLinux 7 are available for download from our updates-testing repository.
mod_lsapi 1.1-4
Changelog:
criu-lve 2.7-9
Changelog:
The new features:
Аdded possibility to CRIU to create images for different virtual hosts under the same user. With these changes, the function of the mod_lsapi_reset_me flag was modified. From now on, if a user needs to clean CRIU images for lsphp, he should create a file: ~/mod_lsapi_reset_me_[vhost_name]. Where [vhost_name] is a ServerName from the VirtualHost block in the configuration file. On the next restart of lsphp, the images will be cleaned.
Example:
cd; touch mod_lsapi_reset_me_criu.test.com
where vhost.conf contains:
ServerName criu.test.com
...
This mode is enabled by default and creates a separate lsphp process for each virtual host.
2. There is lsapi_per_user (default off) option in mod_lsapi that creates only one lsphp process for a user, regardless of the number of his virtual hosts. We don't recommend to use this option with CRIU for now, but if you use it, make sure that your virtual hosts (under the same user) have the same environment configurations. If they are not the same, this may cause undesirable lsphp process operation.
Also, mod_lsapi_reset_me_[vhost_name] flag will not work for a user when
lsapi_per_user option is On.
Note that CRIU can not correctly freeze lsphp with PrivateTmp enabled. For correct work, PrivateTmp should be false in httpd.service file.
For example:
# cat httpd.service
[Unit]
Description=Apache web server managed by cPanel EasyApache
ConditionPathExists=!/etc/httpddisable
ConditionPathExists=!/etc/apachedisable
ConditionPathExists=!/etc/httpdisable
[Service]
Type=forking
ExecStart=/usr/local/cpanel/scripts/restartsrv_httpd --no-verbose
PIDFile=/var/run/apache2/httpd.pid
PrivateTmp=false
[Install]
WantedBy=multi-user.target
How to install (cPanel EA3, EA4 and RPM based systems only):
Control panels and configuration that currently support mod_lsapi+CRIU:
RPM based panels (Plesk or clean OS) + alt-php56 or alt-php70
cPanel EasyApache 3 + alt-php56 or alt-php70
cPanel EasyApache 4 + alt-php56 or alt-php70, ea-php56 or ea-php70
DirectAdmin + alt-php56 or alt-php70
Required Alt-PHP or ea-php versions:
[alt-php56-5.6.30-2+]
[alt-php70-7.0.15-2+]
[ea-php56-php-5.6.30-1.cloudlinux.2+]
[ea-php70-php-7.0.15-1.cloudlinux.2+]
To update Alt-PHP with freezing support (non cPanel and DirectAdmin):
yum groupupdate alt-php --enablerepo=cloudlinux-updates-testingTo install Alt-PHP with freezing support:
yum groupinstall alt-php --enablerepo=cloudlinux-updates-testingTo update ea-php (EasyApache 4) with freezing support:
yum-config-manager --enable cl-ea4-testingyum update ea-php* --enablerepo=cloudlinux-updates-testingyum-config-manager --disable cl-ea4-testingFor install ea-php (EasyApache 4) with freezing support:
yum-config-manager --enable cl-ea4-testingInstall via web-interface or
yum install ea-php* --enablerepo=cloudlinux-updates-testingyum-config-manager --disable cl-ea4-testingmod_lsapi installation and update:
cPanel EasyApache 3 & RPM Based:
$ yum update liblsapi liblsapi-devel --enablerepo=cloudlinux-updates-testing$ yum update mod_lsapi --enablerepo=cloudlinux-updates-testing$ service httpd restart$ systemctl restart criuInstallation for EasyApache 4:
To update:
$ yum update ea-apache24-mod_lsapi liblsapi liblsapi-devel --enablerepo=cloudlinux-updates-testing --enablerepo=cl-ea4-testing$ service httpd restart$ systemctl restart criuTo install:
$ yum install ea-apache24-mod_lsapi liblsapi liblsapi-devel --enablerepo=cloudlinux-updates-testing --enablerepo=cl-ea4-testing$ service httpd restartDirectadmin:
$ yum update liblsapi liblsapi-devel --enablerepo=cloudlinux-updates-testing$ cd /usr/local/directadmin/custombuild$ ./build set cloudlinux_beta yes$ ./build update$ ./build mod_lsapi$ service httpd restart$ systemctl restart criuAfter installing mod_lsapi, read http://docs.cloudlinux.com/index.html?mod_lsapi_installation.html and enable mod_lsapi on your server.
CRIU activation:
systemctl enable criusystemctl start criuAdd to /etc/apache2/conf.d/lsapi.conf or /usr/local/apache/conf/lsapi.conf or /etc/httpd/conf.d/lsapi.conf the following strings:
lsapi_criu On
lsapi_criu_socket_path /var/run/criu/criu_service.socket
lsapi_backend_semtimedwait On
lsapi_backend_initial_start 30
lsapi_criu_use_shm Off
And restart Apache.