当前位置:Gxlcms >
数据库问题 >
11.6 MariaDB安装 11.7/11.8/11.9 Apache安装
11.6 MariaDB安装 11.7/11.8/11.9 Apache安装
时间:2021-07-01 10:21:17
帮助过:20人阅读
11.6 MariaDB安装

?vi /usr/local/mariadb/my.cnf //定义basedir和datadir这里的basedir和datadir不用定义
?vim /etc/init.d/mariadb //定义basedir、datadir、conf以及启动参数

然后按ESC退出编辑输入 /start查到启动脚本命令,增加--defaults-file="$conf"

启动前查看一下有没有mysqld在启动,如果有就要先停掉,因为它们用的端口都是一样的,会产生冲突
ps aux |grep mysql 查看
?etc/init.d/mariadb start 启动mariadb服务


修改指定的配置文件
vi /usr/local/mariadb/my.cnf
在[mysqld] 下面加上datadir = /data/mariadb 就可以了

重新启动服务,datadir=/data/mariadb就达到了预期的效果了,所以不能只在启动脚本里定义,要在配置文件里定义才后

11.7 11.8 11.9 Apache安装


make install完成后查看apache2.4目录

查看调用了那些模式

也可以用这个命令查看调用的模块

安装完了后启动apache
扩展
apache dso https://yq.aliyun.com/articles/6298
apache apxs http://man.chinaunix.net/newsoft/ApacheMenual_CN_2.2new/programs/apxs.html
apache工作模式 http://www.cnblogs.com/fnng/archive/2012/11/20/2779977.html
11.6 MariaDB安装 11.7/11.8/11.9 Apache安装
标签:九周第五次课(2月27日)