mysql从5.6版本开始,如果是命令行直接出现了数据库连接密码就会有以下警告:

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

如用mysql -uroot -proot -e 'show varibles;'或echo “show full processlist "|mysql -uroot -p`cat /root/passwd`;在返回查询的结果中的第一行都有mysql: [Warning] Using a password on the command line interface can be insecure.

  如何去掉这行报警呢!其它很简单,我们弄清了它是怎么出现的就好解决了,你可以试着用管道只显示最后一行。如mysql -uroot -proot -e 'show varibles‘ | tail -n1  但好像不起作用,为什么呢!因为它是标准错误输出。加上 2>/dev/null 就可以了。

  mysql -uroot -proot -e 'show varibles’ 2>/dev/nul

zabbix 3.4监控mysql,提示mysql: [Warning] Using a password on the command line interface can be insecure.的更多相关文章

  1. MySQL 5.6 Warning: Using a password on the command line interface can be insecure

    MySQL 5.6 在命令行输入密码,就会提示这些安全警告信息. Warning: Using a password on the command line interface can be inse ...

  2. MYSQL报警:Warning: Using a password on the command line interface can be insecure.

    问题描述:执行下面的语句,sql是执行成功了,但是出现了一个报警,报警看上去始终不舒服 mysql -hip -Pport -uuser -ppassword -e "use db;dele ...

  3. shell脚本中执行mysql 语句,去除warning using a password on the command line interface can be insecure信息

    方法二:使用mysql参数的方法 mysql -u$user -p$pass -D $db -e "select host from user;"当然,可以通过将传参的方式来传递 ...

  4. mysql处理警告 Warning: Using a password on the command line interface can be insecure.

    vim /etc/mysql/my.cnf [mysqldump] user=user_name password=password 格式: [只用密码的命令] user=用户名 password=密 ...

  5. mysql 5.7 Warning: Using a password on the command line interface can be insecure. 解决方案

    百度了好多,发现都是lunix环境下的,没有找到windows和OS 的,在lunix环境下的解决方案一般就是修改数据库配置文件 my.conf 在Windows 中是没有my.cnf 文件,而是叫做 ...

  6. 解决mysql连接输入密码提示Warning: Using a password on the command line interface can be insecure

    有时候客户端连接mysql需要指定密码时(如用zabbix监控mysql)5.6后数据库会给出个警告信息 mysql -uroot -pxxxx Warning: Using a password o ...

  7. 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 5.6 警告信息 comma ...

  8. mysql 备份报错mysqldump: [Warning] Using a password on the command line interface can be insecure.

    -------------------------------------------------------------------------------- mysql 备份报错mysqldump ...

  9. 【mysql报错】MySQL5.7.27报错“[Warning] Using a password on the command line interface can be insecure.”

    MySQL5.7.27报错“[Warning] Using a password on the command line interface can be insecure.”在命令行使用密码不安全警 ...

随机推荐

  1. math、numpy、pandas NaN 判断

    >> np.nan == np.nan False >> np.nan is np.nan True >> math.nan is np.nan False > ...

  2. Python网络爬虫之图片懒加载技术、selenium和PhantomJS

    引入 图片懒加载 selenium phantomJs 谷歌无头浏览器 知识点回顾 验证码处理流程 动态数据加载处理 一.图片懒加载 什么是图片懒加载? 案例分析:抓取站长素材http://sc.ch ...

  3. SQLAlchemy中表结构的一对一

    1.先导入相对应的库 from flask import Flask from flask_sqlalchemy import SQLAlchemy import pymysql pymysql.in ...

  4. PAT-L2-007 家庭房产 (union-find) 小数据 没有什么是暴力解决不了的!!

    题目分析: 典型的union-find 算法 想法: 先不着急 union 因为每一个人的房产信息不知道 所以先输入所有信息 同时保留与自己有关系的每一个人 待初始化每一个人的房产信息后,再union ...

  5. com.sun.org.apache.xerces.internal.impl.dv.util.Base64出现的问题

    import com.sun.org.apache.xerces.internal.impl.dv.util.Base64; 出现的问题是这个在eclipse中无法使用,解决方法如下: (1)进入ec ...

  6. Django ---- blog项目学习所得

    一.登录功能 1.采用ajax 提交form表单的方式 2.后台生成随机验证码,登录时提交验证码 3.用PLI库生成随机验证码,置于session中,登录时与前台提交的code进行upeer()的验证 ...

  7. 学习笔记TF014:卷积层、激活函数、池化层、归一化层、高级层

    CNN神经网络架构至少包含一个卷积层 (tf.nn.conv2d).单层CNN检测边缘.图像识别分类,使用不同层类型支持卷积层,减少过拟合,加速训练过程,降低内存占用率. TensorFlow加速所有 ...

  8. 简单说明 Virtual DOM 为啥快

    Virtual DOM 就是用 JS 的对象来描述 DOM 结构的一个 DOM 树.如: var element = { tagName: 'ul', // 节点标签名 props: { // DOM ...

  9. ios-计算时间方法

    -(NSString *)countPublishTime:(NSString *)sDate { NSDate *dtNow = [NSDate date]; NSDateFormatter *da ...

  10. 一不小心把win10的秘钥卸载了解决方法

    我遇到的第一个问题是Win10家庭版激活失败提示错误代码0xC004C003 然后我百度后看到一个解决方法是卸载秘钥然后再输入秘钥的,于是我执行了slmgr.vbs /upk,发现win10秘钥被卸载 ...