【问题标题】:Mute a mysql warning message: mysql: [Warning] Using a password on the command line interface can be insecure静音 mysql 警告消息:mysql: [Warning] 在命令行界面上使用密码可能不安全
【发布时间】:2021-06-18 19:09:54
【问题描述】:

MYSQL 5.6 和 5.7 一直显示烦人的消息

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

在 vagrant/cygwin/ 本地环境的命令行中。如果我使用命令行在 Amazon EC2 实例中运行它,MySQL 根本不会返回此警告。有什么办法可以关闭这个警告吗?谢谢!

【问题讨论】:

    标签: mysql amazon-ec2 vagrant


    【解决方案1】:

    我也在为此寻找解决方案。我能想到的只有:

    mysql -u root -p"password" 2>/dev/null
    

    【讨论】:

      【解决方案2】:

      我遇到了同样的问题!

      你见过这个:https://dev.mysql.com/doc/refman/5.6/en/mysql-config-editor.html 吗?

      您可以轻松保存您的凭据并将其用于:

      mysql -G your_conn_name
      

      【讨论】:

        猜你喜欢
        • 2014-07-08
        • 2021-07-10
        • 2018-01-28
        • 2017-11-08
        • 2011-02-17
        • 2020-08-03
        • 2018-01-02
        • 1970-01-01
        • 2018-01-21
        相关资源
        最近更新 更多