配置java
yum -y install java-1.8.0-openjdk*
安装msyql
# wget http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm
# rpm -ivh mysql-community-release-el7-5.noarch.rpm
# yum install mysql-community-server
重启 mysql
# service mysqld restart
配置密码:
set password for 'root'@'localhost' =password('password');
1、编码
mysql配置文件为/etc/my.cnf
最后加上编码配置
default-character-set =utf8
远程连接设置
把在所有数据库的所有表的所有权限赋值给位于所有IP地址的root用户
mysql> grant all privileges on . to root@’%’identified by ‘password’;
如果是新用户而不是root,则要先新建用户
mysql>create user 'username'@'%' identified by 'password';
配置nginx
http://blog.csdn.net/zzq900503/article/details/70049348
准备环境
yum -y install gcc gcc-c++ autoconf automake make
yum -y install gcc pcre-devel zlib zlib-devel openssl openssl-devel
下载
wget -c https://nginx.org/download/nginx-1.13.7.tar.gz
进行安装
./configure --prefix=/usr/nginx
make
make install
启动
cd /usr/local/nginx/sbin
./nginx
启动 nginx报错 缺少日志文件
1:基本命令
./nginx -h #帮助
./nginx -v #显示版本
./nginx -V #显示版本和配置信息
./nginx -t #测试配置
./nginx -q #测试配置时,只输出错误信息
./nginx -s stop #停止服务器
./nginx -s reload #重新加载配置
./nginx -s quit #不知道,估计和stop差不多
./nginx -s reopen #不知道,估计和reload类似
./nginx -p /nginx/path #默认为/usr/local/nginx(nginx安装路径),修改后影响log目录和html目录
./nginx -c /configure/file/path #配置文件路径,默认为conf/nginx.conf,有多个配置文件时很有用,用这个可以启动多个不同的nginx监听不同端口