首页 > 代码库 > centos安装lamp环境

centos安装lamp环境

通过yum安装,需要联网且为su账号
  • yum -y install httpd php mysql mysql-server php-mysql
  • 设置开启启动mysql,httpd
    /sbin/chkconfig httpd on 
    /sbin/chkconfig --add mysqld 
    /sbin/chkconfig mysqld on 
    /sbin/service httpd start 
    /sbin/service mysqld start
  • 检测启动

检测apache:ps aux | grep httpd

检测mysql:netstat -tulnp | grep :3306

 

 

 

 

 

centos安装lamp环境