91超碰碰碰碰久久久久久综合_超碰av人澡人澡人澡人澡人掠_国产黄大片在线观看画质优化_txt小说免费全本

溫馨提示×

溫馨提示×

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

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

glibc方式安裝mysql

發布時間:2020-07-15 01:56:24 來源:網絡 閱讀:2273 作者:知者不言 欄目:MySQL數據庫

下載安裝包 mysql-5.6.38-linux-glibc2.12-x86_64.tar.gz
創建mysql用戶
useradd -r mysql -s /sbin/nologin
解壓文件
tar -zxvf mysql-5.6.38-linux-glibc2.12-x86_64.tar.gz -C /opt/
改名
mv /opt/mysql-5.6.38-linux-glibc2.12-x86_64/ /opt/mysql-5.6
創建數據目錄
mkdir /data
更改目錄屬組

chown -R mysql.mysql /data
chown -R mysql.mysql /opt/mysql-5.6/

安裝mysql

 cd /opt/mysql-5.6/scripts/
 ./mysql_install_db --basedir=/opt/mysql-5.6/ --datadir=/data --user=mysql --pid-file=/opt/mysql-5.6/mysql.pid

安裝mysql報錯
FATAL ERROR: please install the following Perl modules before executing
缺少autoconf 包
yum-y install autoconf
error while loading shared libraries: libaio.so.1:
缺少libaio-devel包
yum -y install libaio-devel
添加啟動腳本
cp /opt/mysql-5.6/support-files/mysql.server /etc/init.d/mysqld

修改配置文件

vi /etc/my.cnf
[mysqld]
 basedir = /opt/mysql-5.6
 datadir = /data
 socket = /tmp/mysql.sock
 pid-file =/opt/mysql-5.6/mysql.pid
 log-bin=mysql-bin
 binlog_format=mixed
 character-set-server = utf8
 max_connections = 3000
 default_storage_engine = InnoDB
 innodb_file_per_table = 1
 innodb_open_files = 500
 innodb_buffer_pool_size = 64M
 innodb_write_io_threads = 4
 innodb_read_io_threads = 4
 innodb_thread_concurrency = 0
 innodb_purge_threads = 1
 innodb_flush_log_at_trx_commit = 2
 innodb_log_buffer_size = 2M
 innodb_log_file_size = 32M
 innodb_log_files_in_group = 3
 innodb_max_dirty_pages_pct = 90
 innodb_lock_wait_timeout = 120
 interactive_timeout = 28800
 wait_timeout = 28800
 lower_case_table_names=1
 event_scheduler=1
 skip-name-resolve=1
[mysqldump]
 quick
 max_allowed_packet = 32M

啟動mysql

/etc/init.d/mysqld start

修改root密碼

cd /opt/mysql-5.6
./bin/mysqladmin -u root password '123'

登錄mysql

cd  /opt/mysql-5.6
./bin/mysql -uroot -p'123'

刪除空用戶和空密碼

delete from mysql.user where user='';
delete from mysql.db where user='';

報錯

ERROR 2002 (HY000): Can't connect to local MySQL server through socket 
'/tmp/mysql.sock' (2)

找到mysql.sock文件,然后做個軟連接
ln -s /opt/mysql-5.6/mysql.sock /tmp/mysql.sock

向AI問一下細節

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

AI

宿州市| 葫芦岛市| 瓦房店市| 西华县| 新津县| 木里| 云安县| 衡南县| 哈尔滨市| 新平| 建宁县| 平罗县| 桐城市| 古浪县| 洪湖市| 丰台区| 虎林市| 简阳市| 澜沧| 尚义县| 丰原市| 泸定县| 屏东县| 岫岩| 新竹市| 司法| 育儿| 大兴区| 中宁县| 湟中县| 乡城县| 会同县| 鱼台县| 浏阳市| 孙吴县| 富平县| 浦北县| 胶南市| 乌兰察布市| 莎车县| 杭州市|