cd /usr/local/src
wget https://downloads.mariadb.com/MariaDB/mariadb-10.2.6/bintar-linux-glibc_214-x86_64/mariadb-10.2.6-linux-glibc_214-x86_64.tar.gz
tar zxvf mariadb-10.2.6-linux-glibc_214-x86_64.tar.gz
mv mariadb-10.2.6-linux-glibc_214-x86_64 /usr/local/mariadb
cd /usr/local/mariadb
./scripts/mysql_install_db --user=mysql --basedir=/usr/local/mariadb/ --datadir=/data/mariadb
cp support-files/my-small.cnf /usr/local/mariadb/my.cnf
vi /usr/local/mariadb/my.cnf //定义basedir和datadir
cp support-files/mysql.server /etc/init.d/mariadb
vim /etc/init.d/mariadb //定义basedir、datadir、conf以及启动参数
关闭mysql服务,开启mariadb服务
安装apache
还没安装成功,。。。。。。。。。
安装apr, apr-util,没问题,安装httpd,make && make install时提示
试过方法如下:
在configure后加上 “--with-included-apr”。再重新编译, make, make install. 即可。
问题又来了,加上--with-included-apr之后,编译,报错如下:
configure: error: Bundled APR requested but not found at ./srclib/. Download and unpack the corresponding apr and apr-util packages to ./srclib/.
错误为:apr,apr-util缺失,需要下载并解压到./srclib/目录下
尝试方法如下:
还没解决问题,明天再看。
原文地址:http://blog.51cto.com/13528516/2073749