posts - 144,comments - 11,views - 87105
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
Apache安装
yum install httpd
启动
systemctl start httpd.service #启动
systemctl stop httpd.service #停止
systemctl restart httpd.service #重启
第二、设置开机启动/关闭
systemctl enable httpd.service #开机启动
systemctl disable httpd.service #开机不启动
第三、检查httpd状态
systemctl status httpd.service
 
  
 
关闭防火墙
关闭:systemctl stop firewalld.service
查看状态:systemctl status firewalld.service

  

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
PHP安装
yum -y install php
 
php各项服务安装:
yum -y install php-gd php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-snmp php-soap curl curl-devel php-mysql
 
  
 
安装MariaDB数据库
CentOS 7.0中,已经使用MariaDB替代了MySQL数据库,原因你懂的,MYSQL被Oracle收购以后,前景堪忧,所以MYSQL兄弟MariaDB就出来了,继续开源事业。
安装:yum -y install mariadb-server mariadb-client
启动:systemctl start mariadb.service
停止:systemctl stop mariadb.service
查看状态:systemctl status mariadb.service
开机启动:systemctl enable mariadb.service
重启:systemctl restart mariadb.service<br><br>

增加了密码后的登录格式如下:

[root@localhost local]#mysql -u root -p

Enter password: (输入密码)

其中-u后跟的是用户名,-p要求输入密码,回车后在输入密码处输入密码。

注意:这个mysql文件在/usr/bin目录下,与后面讲的启动文件/etc/init.d/mysql不是一个文件。

 

[root@localhost local]#/usr/bin/mysqladmin -u root password '123456'

  

1
2
网站文件夹:
/var/www/html

  

posted on   chenlw101  阅读(422)  评论(0编辑  收藏  举报
编辑推荐:
· 对象命名为何需要避免'-er'和'-or'后缀
· SQL Server如何跟踪自动统计信息更新?
· AI与.NET技术实操系列:使用Catalyst进行自然语言处理
· 分享一个我遇到过的“量子力学”级别的BUG。
· Linux系列:如何调试 malloc 的底层源码
阅读排行:
· 对象命名为何需要避免'-er'和'-or'后缀
· JDK 24 发布,新特性解读!
· C# 中比较实用的关键字,基础高频面试题!
· .NET 10 Preview 2 增强了 Blazor 和.NET MAUI
· SQL Server如何跟踪自动统计信息更新?
历史上的今天:
2019-03-12 深拷贝
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

点击右上角即可分享
微信分享提示