Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Eliminate the alarm of password login

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Welcome to the MySQL 8.0 must-know course series.

MySQL8.0 must know-automatic deployment of https://edu.51cto.com/course/16368.html MySQL8.0 must know parameters standardized configuration https://edu.51cto.com/course/16358.html

The command line shows how to eliminate when a password logs in:

Mysql: [Warning] Using a password on the command line interface can be insecure.

Solution:

1. When logging in on the command line, the password is not explicitly entered

Mysql-uroot-p-S / mysqldb/db_ark/mysql.sock

two。 Put the account number and password into the [client] group of the parameter file.

Common parameter file location

/ etc/my.cnf

~ / .my.cnf, home directory (HOME=/home/mysql) can be defined by yourself.

Login parameters

[client]

User=root

Password=mysql

Socket=/mysqldb/db_ark/mysql.sock

3. Use the login path

Create a login path

Mysql_config_editor set-login-path=ark-user=root-socket=/mysqldb/db_ark/mysql.sock-password

Use the login path

Mysql-login-path=ark

View the login path file

File / .mylogin.cnf

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report