redhat利用yum快速搭建LAMP环境
LAMP LAMP环境,对于PHP开发及其开源的PHP项目的部署都很关键的。
LAMP的含义:
L ---Linux
A ---Apache web
M ---Mysql database
P ---Php
01、 Apache的安装
yum install -y httpd
vim /etc/httpd/conf/httpd.conf
DirectoryIndex index.html index.php ###添加默认首页
AddType application/x-httpd-php .php ###添加php的支持
vim /var/www/html/index.php ###测试php
<?php phpinfo(); ?>
02、MySQL-server
yum install -y mysql-server
service mysqld start
mysqladmin -u root pasword '123123'; ###设置数据库root密码
mysql_secure_installation ###初始化安全设置
mysql -u root -p
create database mvpbang default character set utf8; ###创建数据库,设定字符集
grant all on mvpbang.* to 'mvp'@'%' identified by '123123'; ###给数据库建立用户
grant all on mvpbang.* to 'mvp'@'localhost' identified by '123123'; ###可以本地登录
flush privileges;
03、php
yum install -y php php-mysql
yum install -y php-gd php-xml php-process php-mbstring php-bcmath ###扩展组件
https://pkgs.org/ ###找不到rpm可以在此下载
rpm -ivh *.rpm --force --nodeps ###本地强制安装
04、测试
service httpd restart
service mysqld restart
http://172.24.0.27
redhat利用yum快速搭建LAMP环境的更多相关文章
- CentOS6.5使用yum快速搭建LAMP环境
1.安装Apache # yum -y install httpd # 开机自启动 # chkconfig httpd on # 启动httpd 服务 # service httpd start # ...
- CentOS 6.5使用yum快速搭建LAMP环境
由于这里采用yum方式安装,前提是我们必须配置好yum源.为了加快下载速度,建议使用网易的yum源. 这种方式对于初学者来说,非常方便,但是可定制性不强,而且软件版本较低.一般用于实验和学习环境. 1 ...
- Centos6 使用yum快速搭建LAMP环境
1.安装Apache [root@localhost ~]# yum -y install httpd # 开机自启动 [root@localhost ~]# chkconfig httpd on ...
- CentOS 7使用yum快速搭建LAMP环境
1.安装Apache [root@localhost ~]# yum -y install httpd # 开机自启动 [root@localhost ~]# chkconfig httpd on # ...
- 如何《快速搭建LAMP环境》
阿里云体验平台简介 阿里云开发者实验室提供免费云资源和丰富的场景化实践,旨在帮助开发者在学习应用技术,了解阿里云产品的特性. 教程介绍 本教程引用自阿里云体验实验室介绍如何快速搭建Docker环境,并 ...
- 用yum快速搭建LAMP平台
实验环境: [root@nmserver-7 html]# cat /etc/redhat-release CentOS Linux release 7.5.1804 (Core) [root@nms ...
- CentOS7用yum快速搭建LAMP平台
实验环境: [root@nmserver-7 html]# cat /etc/redhat-release CentOS release 7.3.1611 (AltArch) [root@nmserv ...
- CentOS快速搭建LAMP环境
LAMP -- Linux Apache MySQL PHP 在CentOS安装的顺序,我一般是Apache -> MySQL -> PHP 第一步.安装并配置Apache 1.使用yu ...
- 用yum快速搭建LAMP平台与虚拟域名配置
实验环境: [root@nmserver-7 html]# cat /etc/redhat-release CentOS release 7.3.1611 (AltArch) [root@nmserv ...
随机推荐
- JDBC 连Sql Server 接数据库--The TCP/IP connection to the host localhost, port 1433 has failed
原文:https://blog.csdn.net/qq_39241986/article/details/80848855 这样的错误,你有遇到过吗? The TCP/IP connection to ...
- 点集转线python最优代码
import arcpy import os import types def convertPoints(): arcpy.env.overwriteOutput = True inPts = ar ...
- Windows 7 卸载 IE10
今天微软为Windows 7发布了IE10预览版,你是否已经安装?根据笔者的体验,IE10确实如微软所说,在速度.性能等各方面都有了明显提升. 不过,IE10发布预览版安装后会直接替代IE9,如果你想 ...
- 带你走进EJB--它都有哪些Bean
通过前面一系列EJB的博客,我们已经对EJB有了一个宏观的了解.为够更好的在企业项目中使用EJB,我们很有必要对EJB的一些基本内容进行深入,这次我们主要进行的主题是Enterprise Java B ...
- [9] 圆环(Ring)图形的生成算法
顶点数据的生成 bool YfBuildRingVertices ( Yreal radius, Yreal assistRadius, Yreal height, Yuint slices, Yui ...
- linux C 多线程/线程池编程 同步实例
在多线程.线程池编程中经常会遇到同步的问题. 1.创建线程 函数原型:int pthread_create(pthread_t *thread, const pthread_attr_t *attr, ...
- mysql09---sql语句优化
Sql语句本身的优化 问题是: 如何从一个大项目中,迅速的定位执行速度慢的语句. (定位慢查询) 首先我们了解mysql数据库的一些运行状态如何查询(比如想知道当前mysql运行的时间/一共执行了多少 ...
- Android下拉刷新-SwipeRefreshLayout
现在市面上新闻类的App基本上都有下拉刷新,算是一个标配吧,网上关于下拉刷新的博客也有很多,实现方式可以使用开源的PullToRefresh,自定义ListView,或者可以直接使用LineLayOu ...
- AS 代码模板 文件模板 Templates MD
修改 File and Code Templates Settings –> Editor –>[File and Code Templates] 或者在右键new时选择子菜单[Edite ...
- WCF 添加 RESTful 支持,适用于 IIS、Winform、cmd 宿主
You can expose the service in two different endpoints. the SOAP one can use the binding that support ...