CentOS LNMP安装
来源:互联网 发布:windows snmp 软件 编辑:程序博客网 时间:2024/06/04 17:54
一、安装好CentOS,登陆CentOS
二、输入命令
yum install screen 或 apt-get install screenyum install net-toolsscreen -S lnmpyum install wgetwget -c http://soft.vpser.net/lnmp/lnmp1.1-full.tar.gz && tar zxf lnmp1.1-full.tar.gz && cd lnmp1.1-full && ./centos.sh
安装过程中需要输入Mysql root的密码,和询问安装PHP、MariaDB等模块的版本,选择后按任意键开始。
安装结束以后,LNMP脚本就会自动安装编译Nginx、MySQL、PHP、phpMyAdmin、Zend Optimizer这几个软件。
三、虚拟主机
新增:
/root/vhost.sh
删除命令:
ssh登陆执行命令:rm /usr/local/nginx/conf/vhost/域名.conf如,前面我们添加的主域名是www.vpser.net,则该命令为:rm /usr/local/nginx/conf/vhost/www.vpser.net.conf
虚拟主机配置文件在:/usr/local/nginx/conf/vhost/域名.conf
伪静态规则文件需要放在/usr/local/nginx/conf/ 下面。
四、其它
1、eAccelerator
在lnmp解压后的目录(我这里目录是/lnmp1.1-full),执行./eaccelerator.sh
2、xcache
./xcache.sh
3、memcached
./memcached.sh
4、imageMagick
./imageMagick.sh
5、Redis
./redis.sh
6、mysql 远程登陆权限
grant all PRIVILEGES on databasename.* to 'user'@'%' identified by '123456';flush privileges;
五、状态管理
LNMP状态管理命令:
LNMP状态管理: /root/lnmp {start|stop|reload|restart|kill|status}
Nginx状态管理:/etc/init.d/nginx {start|stop|reload|restart}
MySQL状态管理:/etc/init.d/mysql {start|stop|restart|reload|force-reload|status}
Memcached状态管理:/etc/init.d/memcached {start|stop|restart}
PHP-FPM状态管理:/etc/init.d/php-fpm {start|stop|quit|restart|reload|logrotate}
PureFTPd状态管理: /etc/init.d/pureftpd {start|stop|restart|kill|status}
ProFTPd状态管理: /etc/init.d/proftpd {start|stop|restart|reload}
如重启LNMP,输入命令:/root/lnmp restart 即可,单独重启mysql:/etc/init.d/mysql restart
LNMPA状态管理命令:
LNMPA状态管理: /root/lnmpa {start|stop|reload|restart|kill|status}
Nginx状态管理:/etc/init.d/nginx {start|stop|reload|restart}
MySQL状态管理:/etc/init.d/mysql {start|stop|restart|reload|force-reload|status}
Memcached状态管理:/etc/init.d/memcached {start|stop|restart}
PureFTPd状态管理: /etc/init.d/pureftpd {start|stop|restart|kill|status}
ProFTPd状态管理: /etc/init.d/proftpd {start|stop|restart|reload}
Apache状态管理:/etc/init.d/httpd {start|stop|restart|graceful|graceful-stop|configtest|status}
安装参考:
http://lnmp.org/install.html
- 基于centos安装LNMP
- Centos 6.2安装lnmp
- linux centos 安装lnmp
- CentOS LNMP安装
- centos安装配置lnmp
- CentOS安装LNMP
- CentOS 7 安装lnmp
- CentOS 安装lnmp环境
- centos 安装 lnmp
- centos之lnmp 安装
- centos安装lnmp
- centos安装lnmp
- Centos 7 LNMP 安装
- centos 安装 lnmp 环境
- 阿里云centos 安装lnmp
- CentOS编译安装LNMP环境
- CentOS 编译安装搭建LNMP
- CentOS下安装LNMP环境
- java基础---类集框架一
- 线段树学习——入门篇
- VC实现HTTP协议的GET和POST方法
- Linux内核中实现生产者与消费者(避免无效唤醒)
- 一份130+题的题目列表
- CentOS LNMP安装
- UVa 340 Master-Mind Hints
- 创建oracle数据库,用户、表空间、设置角色权限脚本
- linux 网络编程相关结构体
- 分组并排序
- 从头开始写java--第三篇:最简单的java程序
- 使用批处理命令移动子目录下的所有文件到当前目录下,并删除子目录
- 感受傅立叶数学之美
- 堆与栈详解