centos 6.6 服务器配置

2017-06-08  本文已影响0人  riordan

1、mysql 5.7安装

Step1: 检测系统是否自带安装MySQL

#yum list installed | grep mysql

Step2: 删除系统自带的mysql及其依赖 命令:

# yum -y remove mysql-libs.x86_64

Step3: 给CentOS添加rpm源:

#wget https://dev.mysql.com/get/mysql57-community-release-el6-11.noarch.rpm

#yum localinstall mysql57-community-release-el6-11.noarch.rpm

Step4:安装mysql 服务器 命令:

# yum install mysql-community-server

#service mysqld start

#grep password /var/log/mysqld.log

从输出中查找初始密码

#mysql -u root -p

以初始密码登录

mysql>set password = password('your password');

mysql>USE mysql;

mysql>select host from user where user = 'root';

mysql>UPDATE user SET HOST = '%'  WHERE user ='root';

mysql> flush privileges;

2、安装redis

Step1: 安装jemalloc

#wget https://github.com/jemalloc/jemalloc/archive/4.4.0.tar.gz
#tar -zxvf 4.4.0.tar.gz -C /usr/local

#cd /usr/local/jemalloc-4.4.0

#./autogen.sh

#./configure --prefix=/usr/local

#make & make install

如果提示doc下文档找不到,按照文件名复制出文件就可以了

Step2:安装tcl 8.5

#yum install tcl

Step2:下载编译安装redis3.2

#wget http://download.redis.io/redis-stable.tar.gz

#tar zxvf redis-stable.tar.gz -C /usr/local

#cd /usr/local/redis-stable/src

#make

#make test

检查有无报错

#make install

查看redis-server安装位置

#find / -name redis-server

安装redis服务

#/usr/local/redis-stable/utils/./install_server.sh

3、安装nginx

To set up the yum repository for RHEL/CentOS, create the file named/etc/yum.repos.d/nginx.repowith the following contents:

[nginx]

name=nginx repo

baseurl=http://nginx.org/packages/OS/OSRELEASE/$basearch/

gpgcheck=0

enabled=1

Replace “OS” with “rhel” or“centos”,depending on the distribution used, and “OSRELEASE”with “6” or “7”, for 6.x or 7.x versions,respectively.

配置结束后

#yum install nginx

4、安装java环境

#wget http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.rpm?AuthParam=1496973273_1cead8bbc8c29c48bffdb5cc29986aab

#yum localinstall jdk-8u131-linux-x64.rpm

上一篇下一篇

猜你喜欢

热点阅读