Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
Svn-to-Git
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王进波
Svn-to-Git
Commits
6cdbe9a6
Commit
6cdbe9a6
authored
Sep 28, 2018
by
王进波
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
c7e81a1f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
64 additions
and
1 deletion
+64
-1
README.md
README.md
+1
-0
常用命令行.md
doc/常用命令行.md
+63
-1
No files found.
README.md
View file @
6cdbe9a6
...
...
@@ -44,6 +44,7 @@
-
[
Calibre-web电子书网站的使用
](
doc/Calibre-web的使用.md
)
-
[
ike-scan扫描服务端的ike加密算法
](
doc/ike-scan扫描服务端的ike加密算法.md
)
-
[
用 LinqPad 进行快速开发
](
doc/LinqPad快速开发数据轮询持久化.md
)
-
[
用Quartz.net开发定时调度
]
...
...
doc/常用命令行.md
View file @
6cdbe9a6
...
...
@@ -98,7 +98,7 @@ root@ubuntu:/# sudo du -hsx * | sort -rh | head -10
5.3M run
```
###
mysql
主从复制状态查询
###
MySQL
主从复制状态查询
Start the MySQL command-line utility on the slave server:
...
...
@@ -114,3 +114,65 @@ Check the replication status using the show slave status command (the status of
mysql> SHOW SLAVE STATUS
\G
;
```
### MySQL 从服务启停
```
shell
start slave
;
stop slave
;
```
### MySQL 8.0 caching_sha2_password认证
MySQL 从8.0 版本以后默认使用
`caching_sha2_password plugin`
进行身份验证,之前的版本默认使用
`mysql_native_password plugin`
进行身份验证的客户端连接 8.0 时会报错,在
`caching_sha2_password plugin`
下修改用户密码的语句如下:
登录后执行
```
sql
ALTER
USER
user
IDENTIFIED
WITH
caching_sha2_password
BY
'password'
;
```
将密码验证回复成
`caching_sha2_password plugin`
的语句如下:
登录后执行
```
shell
use mysql
;
select
host,user,plugin from user
;
```
打印如下
```
shell
+-----------+------------------+-----------------------+
| host | user | plugin |
+-----------+------------------+-----------------------+
| localhost | mysql.infoschema | caching_sha2_password |
| localhost | mysql.session | caching_sha2_password |
| localhost | mysql.sys | caching_sha2_password |
| localhost | root | caching_sha2_password |
+-----------+------------------+-----------------------+
4 rows
in
set
(
0.00 sec
)
```
执行语句修改plugin为
`mysql_native_password plugin`
```
shell
ALTER USER
'root'
@
'localhost'
IDENTIFIED WITH mysql_native_password BY
'你的密码'
;
flush privileges
;
```
打印如下
```
shell
+-----------+------------------+-----------------------+
| host | user | plugin |
+-----------+------------------+-----------------------+
| localhost | mysql.infoschema | caching_sha2_password |
| localhost | mysql.session | caching_sha2_password |
| localhost | mysql.sys | caching_sha2_password |
| localhost | root | mysql_native_password |
+-----------+------------------+-----------------------+
4 rows
in
set
(
0.00 sec
)
```
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment