手机版
你好,游客 登录 注册 搜索
背景:
阅读新闻

CentOS 6.3安装配置LAMP服务器(Linux+Apache+MySQL+PHP5)

[日期:2012-11-19] 来源:Linux社区  作者:yanghuawu [字体: ]

3、关闭SELINUX
 
[root@server ~]# vim /etc/selinux/config
 
# This file controls the state of SELinux on the system.
 
# SELINUX= can take one of these three values:
 
#    enforcing - SELinux security policy is enforced.
 
#    permissive - SELinux prints warnings instead of enforcing.
 
#    disabled - No SELinux policy is loaded.
 
#SELINUX=enforcing  #注释掉强制
 
SELINUX=disabled    #关闭
 
# SELINUXTYPE= can take one of these two values:
 
#    targeted - Targeted processes are protected,
 
#    mls - Multi Level Security protection.
 
#SELINUXTYPE=targeted  #注释掉
 
:wq  #保存退出
 
 
 
重启系统
 
[root@server ~]# reboot
 
 
 
安装软件包:
 
4、安装Apache
 
检查是否安装httpd,使用YUM 自动安装:
 
[root@server ~]# rpm -qa |grep httpd
 
[root@server ~]# yum -y install httpd    #根据提示,输入Y安装即可成功安装
 
 
 
启动Apache
 
[root@server ~]# service httpd start
 
正在启动 httpd:httpd: apr_sockaddr_info_get() failed for server
 
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
 
                                                          [确定]
 
 
 
设为开机启动
 
[root@server ~]# chkconfig httpd on
 
 
 
重启Apache
 
[root@server ~]# service httpd restart
 
停止 httpd:                                              [确定]
 
正在启动 httpd:httpd: apr_sockaddr_info_get() failed for server
 
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
 
                                                          [确定]
 
 
查看启动Apache运行状态
 
[root@server ~]# service httpd status
 
httpd (pid  1290) 正在运行...
 
浏览器访问:http://10.1.4.44

CentOS 6.3安装配置LAMP服务器(Linux+Apache+MySQL+PHP5)

linux
相关资讯       lamp  CentOS LAMP  CentOS 6.3安装LAMP  CentOS 6.3 LAMP 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款