Centos5.5+LAMP环境
Note:如果网络正常,apache服务正常,仍然不能访问网页。需要检查linux 防火墙是否关闭。
(
先重新启动防火墙
service iptables start
然后输入配置防火墙的命令并查看配置后的防火墙策略
iptables -I INPUT -p TCP --dport 80 -j ACCEPT
service iptables status
完成后如图所示,配置完成,远程访问服务器上的网页已经OK了

)
1.安装apache
[root@admin-pc mnt]# yum -y install httpd*
2.创建默认index.html页面(默认没有index.html页面)
[root@admin-pc mnt]# vi /var/www/html/index.html
<html>
<body>
this is a test a page for apache
</body>
</html>
3.enable ip访问在配置文件中
[root@admin-pc mnt]# vi /etc/httpd/conf/httpd.conf
ServerName www.example.com:80
4.重新启动 apache服务
[root@admin-pc mnt]# /etc/init.d/httpd stop
[root@admin-pc mnt]# /etc/init.d/httpd start
5.打开浏览器http://192.168.1.11/index.html

#安装mysql
1.[root@admin-pc mnt]# yum -y install mysql mysql-server
2.登录mysql(默认用户名和密码为空)
3.修改用户名和密码为root 123
[root@admin-pc mnt]# mysqladmin -u root -p password 123
4,重新登录mysql
[root@admin-pc mnt]# mysql -uroot -p123
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 67
Server version: 5.0.95 Source distribution
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql>
#安装 php
1.yum安装php
[root@admin-pc mnt]# yum -y install php*
2.创建index.php页面
[root@admin-pc mnt]# vi /var/www/html/index.php
3.编辑index.php页面
<?php
phpinfo();
?>
4.打开浏览器http://192.168.1.11/index.php

Centos5.5+LAMP环境的更多相关文章
- (转)CentOS5.5 下搭建 PHP 环境(最佳的LAMP环境)
本文详细阐述在 Linux 系统中搭建 PHP 环境,由于 PHP 就是由 C 语言编写的,最初也是运行在 Linux 系统中,所以Linux 是 PHP 的最佳环境. 关于本文中使用到的软件,请点击 ...
- lamp环境centos6.4
http://www.centos.bz/2011/09/centos-compile-lamp-apache-mysql-php/comment-page-1/#comments 编译安装: 首先卸 ...
- CentOS 6.5下的lamp环境rsyslog+MySQL+loganalyzer实现日志集中分析管理
前言 rsyslog系统日志,在CentOS5上叫syslog,而在CentOS6上叫rsyslog,是增强版的syslog,CentOS5上的配置文件在/etc/syslog.conf下,而Cent ...
- CentOS使用yum源中自带的rpm包安装LAMP环境
CentOS使用yum源中自带的rpm包安装LAMP环境.这是Linux下安装LAMP的环境一种最基本最简便的方式.新手可以从容安装使用. 1. 安装基础包(可选安装)yum install -y w ...
- Ubuntu14.04 lamp环境 php 无法加载mcrypt扩展
Ubuntu14.04中安装后的LAMP环境(http://www.cnblogs.com/daiyu/p/4380657.html)中没有加载:mcrypt扩展,后期再laravel5使用中发现报错 ...
- CentOS 7 yum方式配置LAMP环境
环境:CentOS 7 最小化安装 采用Putty连接 方法:采用YUM安装方法 目的:搭建Apache+Mysql+PHP环境 1,安装Apache yum install httpd //默认情况 ...
- CentOS下搭建LAMP环境详解
前言:在这里将介绍如何在CentOS下搭建LAMP环境(全部使用源码编译安装),用于web服务器开发. •LAMP: Linux + Apache + PHP + Mysql. •系统: CentOS ...
- 7. LAMP环境搭建
一.准备工作 1.安装编译工具gcc.gcc-c++ 注意解决依赖关系,推荐使用yum安装,若不能联网可使用安装光盘做为yum源-- 1)编辑yum配置文件: # mount /dev/cdrom / ...
- Ubuntu-server14.04搭建LAMP环境
转自:http://www.cnblogs.com/myzhibie/p/4330327.html 对于很多PHP初学开发者来讲,搭建一个可用于生产的LAMP环境是一件费时费力的事情,本文以 ubun ...
随机推荐
- Rumor
Vova promised himself that he would never play computer games... But recently Firestorm — a well-kno ...
- 转载:EQ--biquad filter
http://www.musicdsp.org/files/Audio-EQ-Cookbook.txt https://arachnoid.com/BiQuadDesigner/index.html ...
- iview渲染函数
<Table border :columns="discountColumns" :data="discountData.rows"></Ta ...
- TCP/IP详解,卷1:协议--1
引言 很多不同的厂家生产各种型号的计算机,它们运行完全不同的操作系统,但 T C P / I P 协议 族允许它们互相进行通信.这一点很让人感到吃惊,因为它的作用已远远超出了起初的设想. T C P ...
- 排查 k8s 集群 master 节点无法正常工作的问题
搭建的是 k8s 高可用集群,用了 3 台 master 节点,2 台 master 节点宕机后,仅剩的 1 台无法正常工作. 运行 kubectl get nodes 命令出现下面的错误 The c ...
- 【visio】数据流图
率属于 软件和数据库 又名 Gane-Sarson图,数据流图示描述系统数据流程关系的工具,它可以综合的反映出数据在系统中的来源.流动.处理和存储情况,可以将数据流形象具体的表现出来. 在大型项目中, ...
- [Python] CondaHTTPError: HTTP 000 CONNECTION FAILED for url
CondaHTTPError: HTTP 000 CONNECTION FAILED for url 遇到这个问题 解决方法如下两个 一.C:\Users\Administrator 目录下 编辑 . ...
- APP项目下载及运行
1.首先下载Git 2.再下载安装node.js 3.dos窗口下载node.js依赖jar包 执行命令:npm install 4.从Git上down项目 5.运行项目 在项目根目录下 右键 打开 ...
- 【原】接口mock作用
1.前后端 接口定义完成 并发开工 2.测试拿到mock接口 编写用例 3.mock接口 模拟异常服务器返回值 500 404 4.mock接口 模拟数据 不修改线上数据库
- blog主题——黑夜
blog主题,存储一下 /* Author: Io_oTI*/ /*Public*/ * { margin: 0; padding: 0; box-sizing: border-box; trans ...