mybatis access denied问题

来源:互联网 发布:怎样成为淘宝直播 编辑:程序博客网 时间:2024/04/27 15:07

遇到如下错误:

com.ibatis.common.jdbc.exception.NestedSQLException:   --- The error occurred in com/arcsoft/web/adminconsolews/caas/model/OAuthUser.xml.  --- The error occurred while executing query.  --- Check the    SELECT user_id uid,username userName,email,mobile,unified_id   unifiedId,create_time registerTime,status,region,last_op_time   lastOpTime,check_code checkCode,active_time activeTime,vip_num vipnum   FROM oauth_user WHERE 1=1      and    (email like    concat('%', ?, '%') or mobile like concat('%', ?, '%') )                      ORDER BY create_time desc     .  --- Check the SQL Statement (preparation failed).  --- Cause: org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Access denied for user 'root'@'172.29.31.217' (using password: YES))


Access denied for user 'root'@'172.29.31.217' (using password: YES)这句话极具迷惑性,不仔细看,还以为是本机请求172.29.31.217上mysql server的root账户被拒绝了。

不仔细看就倒霉了,我花了一下午查问题,结果问题实质是本机ip地址为172.29.31.217,以root账号请求mysql server,改成其他的账号就ok了。


0 0
原创粉丝点击