启动Hive的两条指令,和测试hiveserver的一条指令

启动Hive

[root@hadoop hive-1.2.1]# hive --service metastore &
[1] 15831

[root@hadoop hive-1.2.1]# hive --service hiveserver2 &
[2] 16130

测试hiveserver2是否启动成功

[root@hadoop hive-1.2.1]# beeline -i ~/.hiverc -n root -u “jdbc:hive2://192.168.130.111:10000” -e “show databases;”

Connecting to jdbc:hive2://192.168.130.111:10000
Connected to: Apache Hive (version 1.2.1)
Driver: Hive JDBC (version 1.2.1)
Transaction isolation: TRANSACTION_REPEATABLE_READ
Running init script /root/.hiverc
/root/.hiverc (没有那个文件或目录)

OK
+----------------+--+
| database_name  |
+----------------+--+
| default        |
| zxy            |
+----------------+--+
2 rows selected (4.612 seconds)
Beeline version 1.2.1 by Apache Hive
Closing: 0: jdbc:hive2://192.168.130.111:10000

启动Hive的两条指令,和测试hiveserver的一条指令

上一篇:Spring-data-redis redis


下一篇:liunx 安装和解压命令