消除MySQL连接时的Warning:Using a password on the command line interface can be insecure.
Posted 一个菜鸡运维
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了消除MySQL连接时的Warning:Using a password on the command line interface can be insecure.相关的知识,希望对你有一定的参考价值。
MySQL5.6之后的版本在通过客户端连接或者备份时时都会有出现如下的一个警告:
Warning: Using a password on the command line interface can be insecure.
在一些脚本操作中可能会造成一些干扰,这里介绍下两种方式来避免这个输出。
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 1637
Server version: 5.7.31-0ubuntu0.16.04.1 (Ubuntu)
Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;‘ or ‘h‘ for help. Type ‘c‘ to clear the current input statement.
mysql>
2:重定向警告
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 1640
Server version: 5.7.31-0ubuntu0.16.04.1 (Ubuntu)
Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;‘ or ‘h‘ for help. Type ‘c‘ to clear the current input statement.
mysql>
以上是关于消除MySQL连接时的Warning:Using a password on the command line interface can be insecure.的主要内容,如果未能解决你的问题,请参考以下文章
MYSQL报警:Warning: Using a password on the command line interface can be insecure.
mysql 备份报错mysqldump: [Warning] Using a password on the command line interface can be insecure.
Warning: Using a password on the command line interface can be insecure.
zabbix监控mysql之Warning: Using a password on the command line interface can be insecure.