I am trying to connect to hive tables from StraRocks using external catalog.
StartRocks version
version info
Version: 3.1.5
Git: 5d8438a
Build Info: StarRocks@localhost
Build Time: 2023-11-24 03:58:58
Note: our hadoop infrastructure using kerberos authentication and we are using a service ID to connect to the database/tables in Hive.
We are successfully generated kerberos ticket on bottn fe and be nodes.
Steps performed: Ran below queries from MySQL client after connecting the DB using admin ID
CREATE EXTERNAL CATALOG OPRHQA PROPERTIES
( “type”=“hive”,
“hive.metastore.uris”=“thrift://XXXX:9083,thrift://$$$$$$:9083” );
post this i am unable to create any database under this catalog (OPRHQA).
But able create databases on “default_catalog”. So tried using “default_catalog” instead of “OPRHQA”.
executed below command before creating the external tables.
SET CATALOG default_catalog;
USE default_catalog.starrocks_test;
After this we trued to create external tables by executing below query, but it fails.
CREATE EXTERNAL TABLE hive_external_table
(
ctry_cd
int,
ctry_nm
string,
sregn_cd
string,
sregn_nm
string,
regn_cd
string,
regn_nm
string,
ctry_cd_alpha_cd
string,
zone_cd
int,
actv_ind
string,
insrt_ts
string,
upd_ts
string
)
ENGINE=HIVE
PROPERTIES (
“resource” = “hive”,
“database” = “opcode”,
“table” = “tedc_ctry”,
“hive.metastore.uris” = “thrift://XXXXXX:10000”
);
Error:-
[Code: 1064, SQL State: 42000] Unexpected exception: HIVE resource [hive] not exists
Could you please guide me what i am doing wrong ?
Thanks !
Vineeth