LLsMP顾名思义是Linux+LiteSpeed+MySQL+PHP的一套Web环境。相信可能大家对LNMP更熟悉一些,至于孰好孰坏,这里也不卖弄了,毕竟自己也是刚刚接触LLsMP,所以不方便多说,但是从现有资料来看,LiteSpeed的负载能力很强,占用资源也极低,而且对于.htaccess的rewrite规则支持也非常不错,这也是Nginx一个很大的缺陷吧(许多伪静态的规则需要自己完成…)。
LLsMP一键安装包及使用教程
本文介绍的LLsMP一键安装包是llsmp.org进行发布,本文仅对常用设置与命令进行整理汇总!
1.安装LLsMP
2.安装更多附加组件
3.LLsMP相关管理命令
4.LLsMP常用目录
5.截止本文发表,最新版本0.6已知的问题
安装LLsMP
支持平台:CentOS 5/6 , Debian 5/6 , Ubuntu 10/11
安装命令:
安装PHP5.3版本完成之後要重启MYSQL
/etc/init.d/mysql start
CentOS:
PHP5.2
wget http://llsmp.googlecode.com/files/llsmp0.6_centos.tar.gz;tar zxvf llsmp0.6_centos.tar.gz;cd centos;sh install.sh
PHP5.3
wget http://llsmp.googlecode.com/files/llsmp0.6_centos.tar.gz;tar zxvf llsmp0.6_centos.tar.gz;cd centos;sh install.sh php5.3
Debian:
PHP5.2
wget http://llsmp.googlecode.com/files/llsmp0.6_debian.tar.gz;tar zxvf llsmp0.6_debian.tar.gz;cd debian;sh install.sh
PHP5.3
wget http://llsmp.googlecode.com/files/llsmp0.6_debian.tar.gz;tar zxvf llsmp0.6_debian.tar.gz;cd debian;sh install.sh php5.3
Ubuntu:
PHP5.2
wget http://llsmp.googlecode.com/files/llsmp0.6_ubuntu.tar.gz;tar zxvf llsmp0.6_ubuntu.tar.gz;cd ubuntu;sh install.sh
PHP5.3
wget http://llsmp.googlecode.com/files/llsmp0.6_ubuntu.tar.gz;tar zxvf llsmp0.6_ubuntu.tar.gz;cd ubuntu;sh install.sh php5.3
安装更多附加组件:
安装eAccelerator : sh /root/llsmp/eaccelerator.sh
安装Zend Optimizer : sh /root/llsmp/zend_optimizer.sh
安装ionCube Loader : sh /root/llsmp/ioncube.sh
安装Google Performace Tools : sh /root/llsmp/perftools.sh
安装FTP(vsftpd) : sh /root/llsmp/vsftpd.sh
安装Nginx前端 : sh /root/llsmp/nginx.sh
LLsMP相关管理命令:
创建Litespeed虚拟主机 : sh /root/llsmp/vhost.sh
添加FTP账号 : sh /root/llsmp/vsftpd.sh
重要!虚拟主机权限修正: chown -R nobody:nobody /home/wwwroot/域名/html
创建Nginx虚拟主机 : sh /root/llsmp/nginx.sh
备份指令 : sh /root/llsmp/backup.sh
重启Litespeed : /etc/init.d/lsws restart
重启MySQL : /etc/init.d/mysql(d) restart
重启Nginx : /etc/init.d/nginx restart
LLsMP常用目录:
Litespeed管理后台 : http://{ip}:7080
phpMyAdmin : http://{ip}/phpmyadmin/
php.ini目录 : /usr/local/lsws/lsphp5/lib/php.ini
MySQL配置文件my.cnf : /etc/my.cnf (Centos) | /etc/mysql/my.cnf (Debian/Ubuntu)
Nginx配置目录: /etc/nginx/nginx.conf 及 /etc/nginx/conf.d/下
虚拟主机目录: /home/wwwroot
LLsMP安装日志: /root/llsmp/install.log
截止本文发表,最新版本0.6已知的问题:
1.已知部分KVM上的Debian无法安装LLsMP
cp: cannot create regular file '/usr/local/lsws/DEFAULT/html/installlog.html': No such file or directory
sed: can't read /usr/local/lsws/DEFAULT/html/installlog.html: No such file or directory
sed: can't read /usr/local/lsws/DEFAULT/html/installlog.html: No such file or directory
sed: can't read /usr/local/lsws/DEFAULT/html/installlog.html: No such file or directory
sed: can't read /usr/local/lsws/DEFAULT/html/installlog.html: No such file or directory
原因是Litespeed安装未成功,expect出现错误
待修正
2.安装LLsMP 的PHP5.3版本登录phpmyadmin出现#2002错误
原因是脚本问题,MySQL未自动重启,请手动重启
/etc/init.d/mysql start
3.VPS重启,而Litespeed和MySQL未随机启动
手动设置开机启动
Debian/Ubuntu:
update-rc.d lsws defaults
update-rc.d mysql defaults
CentOS:
chkconfig –level 345 lsws on
chkconfig –level 345 mysql on
文章来源:微魔部落