ERROR 1044 (42000): Access denied for user 'xuhive'@'%' to database 'hive'

1.我首先创建了一个hive用户然后执行create database hive报错如下

ERROR 1044 (42000): Access denied for user 'xuhive'@'%' to database 'hive'

2.上网查到权限不够退出当前用户到root用户下赋予hive权限

grant all on *.* to 'hive'@'%' identified by 'hive';

3.然后在执行

 grant all on *.* to 'hive'@'localhost' identified by 'hive';
4.最后flush privileges;
5.重新切换hive用户下执行create database hive
posted on 2016-03-30 16:34  问候你爸  阅读(1301)  评论(0编辑  收藏  举报