亚洲激情专区-91九色丨porny丨老师-久久久久久久女国产乱让韩-国产精品午夜小视频观看

溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

percona-server-5.7.11-4源碼安裝手冊

發布時間:2020-08-16 18:29:09 來源:ITPUB博客 閱讀:154 作者:yepkeepmoving 欄目:MySQL數據庫
MySQL5.7出來有段時間了,一直沒時間玩玩,這兩天有時間下了percona的裝了下,發現還是有很多好玩的東西,下面是簡單的源碼安裝記錄(二進制安裝比較簡單,源碼安裝對OS包的依賴比較嚴重,尤其是zlib包,建議用RHEL6.5以上版本,本實驗用的是centos7

環境描述:

安裝軟件

描述

操作系統

CentOS7_x86_64 (CentOS Linux release 7.2.1511 (Core))

數據庫軟件

percona-server-5.7.11-4.tar.gz(源碼安裝包)

Percona-Server-5.7.11-4-Linux.x86_64.ssl101.tar.gz(二進制安裝包)


軟件下載:

https://www.percona.com/downloads/Percona-Server-5.7/LATEST/

依賴包安裝:
rpm -q gcc gcc-c++ ncurses-devel cmake libaio bison zlib-devel
利用Yum安裝依賴包 yum install package_name  -y

[root@localhost home]# cat /etc/yum.repos.d/CentOS-Base.repo

[Base]

name=CentOS7 ISO Base

baseurl=file:///mnt/cdrom

enabled=1

gpgcheck=0


上傳并解壓安裝包:

[root@localhost soft]# cd /tools/soft/MySQL/

[root@localhost MySQL]# tar -xzvf percona-server-5.7.11-4.tar.gz


創建授權用戶:
/usr/sbin/groupadd mysql
/usr/sbin/useradd mysql -g mysql -d /home/mysql -s /sbin/nologin
mkdir /home/mysql/data
mkdir /home/mysql/log
mkdir /home/mysql/tmp
mkdir /home/mysql/binlog
mkdir /usr/local/mysql

chown -R mysql.mysql /usr/local/mysql

chown -R mysql.mysql /home/mysql


源碼包編譯安裝:

cd /tools/soft/
tar -xzvf boost_1_59_0.tar.gz

mv boost_1_59_0 /usr/local/boost

cd percona-server-5.7.11-4

cmake  . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql \

-DMYSQL_UNIX_ADDR=/home/mysql/mysql.sock \

-DWITH_BOOST=/usr/local/boost \

-DDEFAULT_CHARSET=utf8 \

-DDEFAULT_COLLATION=utf8_general_ci \

-DWITH_MYISAM_STORAGE_ENGINE=1 \

-DWITH_INNOBASE_STORAGE_ENGINE=1 \

-DWITH_ARCHIVE_STORAGE_ENGINE=1 \

-DWITH_BLACKHOLE_STORAGE_ENGINE=1 \

-DWITH_EDITLINE=bundled \

-DENABLED_LOCAL_INFILE=1 \

-DMYSQL_DATADIR=/home/mysql/data \

-DMYSQL_TCP_PORT=3306 \

-DZLIB_INCLUDE_DIR:PATH=/usr/include \

-DENABLE_DOWNLOADS=1


make  -j  8

make install


初始化數據庫:

cd /usr/local/mysql/
./bin/mysqld --initialize-insecure --user=mysql --basedir=/usr/local/mysql --datadir=/home/mysql/data

./bin/mysql_ssl_rsa_setup --user=mysql --basedir=/usr/local/mysql --datadir=/home/mysql/data


配置數據庫:

cd /usr/local/mysql/

cp support-files/my-default.cnf  /etc/my.cnf

>/etc/my.cnf
vi /etc/my.cnf

[client]

socket=/home/mysql/mysql.sock

[mysqld]

symbolic-links=0

server_id                  = 120

default_storage_engine     = Innodb

user                       = mysql

port                       = 3306

basedir                    = /usr/local/mysql

datadir                    = /home/mysql/data

tmpdir                     = /home/mysql/tmp

socket                     = /home/mysql/mysql.sock

pid_file                   = /home/mysql/mysql.pid

 

# Character Sets & Collations

character_set_server       = utf8

collation_server           = utf8_general_ci

 

open_files_limit           = 10240

explicit_defaults_for_timestamp

 

# Buffer

max_allowed_packet         = 256M

max_heap_table_size        = 256M

net_buffer_length          = 8K

sort_buffer_size           = 2M

join_buffer_size           = 4M

read_buffer_size           = 2M

read_rnd_buffer_size       = 16M

 

#log_error

log_error                  = /home/mysql/log/error.log

 

#binlog

log_bin                    = /home/mysql/binlog/mysql-bin

binlog_cache_size          = 32M

max_binlog_cache_size      = 2G

max_binlog_size            = 500M

binlog_format              = mixed

log_output                 = FILE

expire_logs_days           = 5

 

# Slow Query Parameter

slow_query_log             = 1

long_query_time            = 3

slow_query_log_file        = /home/mysql/log/slow-query.log

 

# General Log

#general_log                = 0

#general_log_file           = /data/mysqldata/3307/general-query.log

 

# Innodb Engine Parameter

#innodb_data_file_path     = ibdata1:1G:autoextend

innodb_buffer_pool_size    = 500M

innodb_log_file_size       = 200M

innodb_log_files_in_group  = 3

#innodb_flush_log_at_trx_commit = 2

innodb_lock_wait_timeout   = 20

 

[mysql]

no_auto_rehash

 

[mysqld_safe]

log-error=/home/mysql/log/error.log



配置mysql系統服務:

cd /usr/local/mysql

cp support-files/mysql.server  /etc/init.d/mysql

chkconfig --add mysql

chkconfig mysql on

啟動數據庫:
service mysql start




向AI問一下細節

免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。

AI

石城县| 来宾市| 义马市| 英超| 泽州县| 平凉市| 荥经县| 南阳市| 敦化市| 响水县| 石渠县| 潜山县| 江油市| 张掖市| 阜阳市| 城口县| 故城县| 兴国县| 马山县| 横山县| 华池县| 正镶白旗| 淮南市| 郸城县| 改则县| 剑河县| 六盘水市| 当雄县| 永州市| 南安市| 通河县| 青海省| 南乐县| 邢台县| 贵阳市| 调兵山市| 富川| 商丘市| 斗六市| 利川市| 秀山|