码迷,mamicode.com
首页 > 数据库 > 详细

Nginx Mysql PHP总结

时间:2019-07-06 15:04:20      阅读:113      评论:0      收藏:0      [点我收藏+]

标签:install   follow   安装   http   bin   htm   load   href   mysql安装   

nginx安装http://nginx.org/en/download.html
cd /usr/local
cd nginx
cd conf
cd nginx.conf
cd html
./nginx -t
./nginx -s reload
vim nginx.conf
netstat -pantu | grep 80
server {
listen 80;
server_name www.nautilus.org;
location / {
root html/www;
index index.html index.htm;
}

mysql安装wget http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.22.tar.gz
mysql解压tar zxvf mysql-5.6.38.tar.gz
mkdir /usr/local/mysql
mkdir /usr/local/mysql/data
cd mysql-5.6.38/
开始编译安装:cmake
make
make install
修改目录属主权限
chown -R mysql:mysql /usr/local/mysql/data/
chown -R mysql:mysql /usr/local/mysql/
数据库初始化scripts/mysql_install_db --user=mysql --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data/mysql --pid-file=/usr/local/mysql/data/mysql/mysql.pid --tmpdir=/tmp
chown -R mysql:mysql my.cnf
vim my.cnf
basedir = /usr/local/mysql
datadir = /usr/local/mysql/data
cd /usr/local/mysql/support-files
./mysql.server start
cd /usr/local/mysql/bin
./mysql -u root -p

php安装wget http://cn2.php.net/distributions/php-5.6.0.tar.xz
xz -d php-5.6.0.tar.xz
tar xf php-5.6.0.tar -C /usr/local/src/
yum install zlib-devel libxml2-devel libjpeg-devel libjpeg-turbo-devel
yum install freetype-devel libpng-devel gd-devel libcurl-devel libxslt-devel bz2-devel
cd /usr/local/src/php-5.6.0/
./configure

Nginx Mysql PHP总结

标签:install   follow   安装   http   bin   htm   load   href   mysql安装   

原文地址:https://blog.51cto.com/14375816/2417646

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!