首页 > 代码库 > Warning: Using a password on the command line interface can be insecure.解决办法
Warning: Using a password on the command line interface can be insecure.解决办法
被一个小朋友问到,直接公布答案:
If your MySQL client/server version is a 5.6.x a way to avoid the WARNING message are using the mysql_config_editor tools:
mysql_config_editor set --login-path=local --host=localhost --user=username --password
Then you can use in your shell script:
mysql --login-path=local -e "statement"
instead of:
mysql -u username -p pass -e "statement"
Warning: Using a password on the command line interface can be insecure.解决办法
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。