hive3升级

这篇具有很好参考价值的文章主要介绍了hive3升级。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

一、hive2升级到hive3步骤

1.备份hive2元数据库

mysqldump -h ip -u user-p hive > hive.sql

2.导入到hive3对应的hive元数据表

mysql -h ip -u litbaws -p hive3 < hive3.sql

3.更新hive_metastore数据表信息

3.1需要新增的表
序号 hive3
1 I_SCHEMA
2 MATERIALIZATION_REBUILD_LOCKS
3 METASTORE_DB_PROPERTIES
4 MIN_HISTORY_LEVEL
5 NEXT_WRITE_ID
6 REPL_TXN_MAP
7 RUNTIME_STATS
8 SCHEMA_VERSION
9 TXN_TO_WRITE_ID
10 WM_MAPPING
11 WM_POOL
12 WM_POOL_TO_TRIGGER
13 WM_RESOURCEPLAN
14 WM_TRIGGER
-- ----------------------------
-- Table structure for I_SCHEMA
-- ----------------------------
DROP TABLE IF EXISTS `I_SCHEMA`;
CREATE TABLE `I_SCHEMA`  (
  `SCHEMA_ID` bigint(20) NOT NULL,
  `SCHEMA_TYPE` int(11) NOT NULL,
  `NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `DB_ID` bigint(20) NULL DEFAULT NULL,
  `COMPATIBILITY` int(11) NOT NULL,
  `VALIDATION_LEVEL` int(11) NOT NULL,
  `CAN_EVOLVE` bit(1) NOT NULL,
  `SCHEMA_GROUP` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `DESCRIPTION` varchar(4000) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  PRIMARY KEY (`SCHEMA_ID`) USING BTREE,
  INDEX `DB_ID`(`DB_ID`) USING BTREE,
  INDEX `UNIQUE_NAME`(`NAME`) USING BTREE,
  CONSTRAINT `I_SCHEMA_ibfk_1` FOREIGN KEY (`DB_ID`) REFERENCES `DBS` (`DB_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for MATERIALIZATION_REBUILD_LOCKS
-- ----------------------------
DROP TABLE IF EXISTS `MATERIALIZATION_REBUILD_LOCKS`;
CREATE TABLE `MATERIALIZATION_REBUILD_LOCKS`  (
  `MRL_TXN_ID` bigint(20) NOT NULL,
  `MRL_DB_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `MRL_TBL_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `MRL_LAST_HEARTBEAT` bigint(20) NOT NULL,
  PRIMARY KEY (`MRL_TXN_ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for METASTORE_DB_PROPERTIES
-- ----------------------------
DROP TABLE IF EXISTS `METASTORE_DB_PROPERTIES`;
CREATE TABLE `METASTORE_DB_PROPERTIES`  (
  `PROPERTY_KEY` varchar(255) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `PROPERTY_VALUE` varchar(1000) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `DESCRIPTION` varchar(1000) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  PRIMARY KEY (`PROPERTY_KEY`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for MIN_HISTORY_LEVEL
-- ----------------------------
DROP TABLE IF EXISTS `MIN_HISTORY_LEVEL`;
CREATE TABLE `MIN_HISTORY_LEVEL`  (
  `MHL_TXNID` bigint(20) NOT NULL,
  `MHL_MIN_OPEN_TXNID` bigint(20) NOT NULL,
  PRIMARY KEY (`MHL_TXNID`) USING BTREE,
  INDEX `MIN_HISTORY_LEVEL_IDX`(`MHL_MIN_OPEN_TXNID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for NEXT_WRITE_ID
-- ----------------------------
DROP TABLE IF EXISTS `NEXT_WRITE_ID`;
CREATE TABLE `NEXT_WRITE_ID`  (
  `NWI_DATABASE` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `NWI_TABLE` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `NWI_NEXT` bigint(20) NOT NULL,
  UNIQUE INDEX `NEXT_WRITE_ID_IDX`(`NWI_DATABASE`, `NWI_TABLE`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for REPL_TXN_MAP
-- ----------------------------
DROP TABLE IF EXISTS `REPL_TXN_MAP`;
CREATE TABLE `REPL_TXN_MAP`  (
  `RTM_REPL_POLICY` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `RTM_SRC_TXN_ID` bigint(20) NOT NULL,
  `RTM_TARGET_TXN_ID` bigint(20) NOT NULL,
  PRIMARY KEY (`RTM_REPL_POLICY`, `RTM_SRC_TXN_ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for RUNTIME_STATS
-- ----------------------------
DROP TABLE IF EXISTS `RUNTIME_STATS`;
CREATE TABLE `RUNTIME_STATS`  (
  `RS_ID` bigint(20) NOT NULL,
  `CREATE_TIME` bigint(20) NOT NULL,
  `WEIGHT` bigint(20) NOT NULL,
  `PAYLOAD` blob NULL,
  PRIMARY KEY (`RS_ID`) USING BTREE,
  INDEX `IDX_RUNTIME_STATS_CREATE_TIME`(`CREATE_TIME`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for SCHEMA_VERSION
-- ----------------------------
DROP TABLE IF EXISTS `SCHEMA_VERSION`;
CREATE TABLE `SCHEMA_VERSION`  (
  `SCHEMA_VERSION_ID` bigint(20) NOT NULL,
  `SCHEMA_ID` bigint(20) NULL DEFAULT NULL,
  `VERSION` int(11) NOT NULL,
  `CREATED_AT` bigint(20) NOT NULL,
  `CD_ID` bigint(20) NULL DEFAULT NULL,
  `STATE` int(11) NOT NULL,
  `DESCRIPTION` varchar(4000) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `SCHEMA_TEXT` mediumtext CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL,
  `FINGERPRINT` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `SCHEMA_VERSION_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `SERDE_ID` bigint(20) NULL DEFAULT NULL,
  PRIMARY KEY (`SCHEMA_VERSION_ID`) USING BTREE,
  INDEX `CD_ID`(`CD_ID`) USING BTREE,
  INDEX `SERDE_ID`(`SERDE_ID`) USING BTREE,
  INDEX `UNIQUE_VERSION`(`SCHEMA_ID`, `VERSION`) USING BTREE,
  CONSTRAINT `SCHEMA_VERSION_ibfk_1` FOREIGN KEY (`SCHEMA_ID`) REFERENCES `I_SCHEMA` (`SCHEMA_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT,
  CONSTRAINT `SCHEMA_VERSION_ibfk_2` FOREIGN KEY (`CD_ID`) REFERENCES `CDS` (`CD_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT,
  CONSTRAINT `SCHEMA_VERSION_ibfk_3` FOREIGN KEY (`SERDE_ID`) REFERENCES `SERDES` (`SERDE_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for TXN_TO_WRITE_ID
-- ----------------------------
DROP TABLE IF EXISTS `TXN_TO_WRITE_ID`;
CREATE TABLE `TXN_TO_WRITE_ID`  (
  `T2W_TXNID` bigint(20) NOT NULL,
  `T2W_DATABASE` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `T2W_TABLE` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `T2W_WRITEID` bigint(20) NOT NULL,
  UNIQUE INDEX `TBL_TO_TXN_ID_IDX`(`T2W_DATABASE`, `T2W_TABLE`, `T2W_TXNID`) USING BTREE,
  UNIQUE INDEX `TBL_TO_WRITE_ID_IDX`(`T2W_DATABASE`, `T2W_TABLE`, `T2W_WRITEID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;


---------------------------------------------------------------------------------------------------------

-- ----------------------------
-- Table structure for WM_MAPPING
-- ----------------------------
DROP TABLE IF EXISTS `WM_MAPPING`;
CREATE TABLE `WM_MAPPING`  (
  `MAPPING_ID` bigint(20) NOT NULL,
  `RP_ID` bigint(20) NOT NULL,
  `ENTITY_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `ENTITY_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `POOL_ID` bigint(20) NULL DEFAULT NULL,
  `ORDERING` int(11) NULL DEFAULT NULL,
  PRIMARY KEY (`MAPPING_ID`) USING BTREE,
  UNIQUE INDEX `UNIQUE_WM_MAPPING`(`RP_ID`, `ENTITY_TYPE`, `ENTITY_NAME`) USING BTREE,
  INDEX `WM_MAPPING_FK2`(`POOL_ID`) USING BTREE
  -- CONSTRAINT `WM_MAPPING_FK1` FOREIGN KEY (`RP_ID`) REFERENCES `WM_RESOURCEPLAN` (`RP_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT,
  -- CONSTRAINT `WM_MAPPING_FK2` FOREIGN KEY (`POOL_ID`) REFERENCES `WM_POOL` (`POOL_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
DROP TABLE IF EXISTS `WM_POOL`;
CREATE TABLE `WM_POOL`  (
  `POOL_ID` bigint(20) NOT NULL,
  `RP_ID` bigint(20) NOT NULL,
  `PATH` varchar(767) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `ALLOC_FRACTION` double NULL DEFAULT NULL,
  `QUERY_PARALLELISM` int(11) NULL DEFAULT NULL,
  `SCHEDULING_POLICY` varchar(767) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  PRIMARY KEY (`POOL_ID`) USING BTREE,
  UNIQUE INDEX `UNIQUE_WM_POOL`(`RP_ID`, `PATH`) USING BTREE
  -- CONSTRAINT `WM_POOL_FK1` FOREIGN KEY (`RP_ID`) REFERENCES `WM_RESOURCEPLAN` (`RP_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;


-- ----------------------------
-- Table structure for WM_POOL_TO_TRIGGER
-- ----------------------------
DROP TABLE IF EXISTS `WM_POOL_TO_TRIGGER`;
CREATE TABLE `WM_POOL_TO_TRIGGER`  (
  `POOL_ID` bigint(20) NOT NULL,
  `TRIGGER_ID` bigint(20) NOT NULL,
  PRIMARY KEY (`POOL_ID`, `TRIGGER_ID`) USING BTREE,
  INDEX `WM_POOL_TO_TRIGGER_FK2`(`TRIGGER_ID`) USING BTREE
  -- CONSTRAINT `WM_POOL_TO_TRIGGER_FK1` FOREIGN KEY (`POOL_ID`) REFERENCES `WM_POOL` (`POOL_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT,
  -- CONSTRAINT `WM_POOL_TO_TRIGGER_FK2` FOREIGN KEY (`TRIGGER_ID`) REFERENCES `WM_TRIGGER` (`TRIGGER_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for WM_RESOURCEPLAN
-- ----------------------------
DROP TABLE IF EXISTS `WM_RESOURCEPLAN`;
CREATE TABLE `WM_RESOURCEPLAN`  (
  `RP_ID` bigint(20) NOT NULL,
  `NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `QUERY_PARALLELISM` int(11) NULL DEFAULT NULL,
  `STATUS` varchar(20) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `DEFAULT_POOL_ID` bigint(20) NULL DEFAULT NULL,
  PRIMARY KEY (`RP_ID`) USING BTREE,
  UNIQUE INDEX `UNIQUE_WM_RESOURCEPLAN`(`NAME`) USING BTREE,
  INDEX `WM_RESOURCEPLAN_FK1`(`DEFAULT_POOL_ID`) USING BTREE
  -- CONSTRAINT `WM_RESOURCEPLAN_FK1` FOREIGN KEY (`DEFAULT_POOL_ID`) REFERENCES `WM_POOL` (`POOL_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for WM_TRIGGER
-- ----------------------------
DROP TABLE IF EXISTS `WM_TRIGGER`;
CREATE TABLE `WM_TRIGGER`  (
  `TRIGGER_ID` bigint(20) NOT NULL,
  `RP_ID` bigint(20) NOT NULL,
  `NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `TRIGGER_EXPRESSION` varchar(1024) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `ACTION_EXPRESSION` varchar(1024) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `IS_IN_UNMANAGED` bit(1) NOT NULL DEFAULT b'0',
  PRIMARY KEY (`TRIGGER_ID`) USING BTREE,
  UNIQUE INDEX `UNIQUE_WM_TRIGGER`(`RP_ID`, `NAME`) USING BTREE
  -- CONSTRAINT `WM_TRIGGER_FK1` FOREIGN KEY (`RP_ID`) REFERENCES `WM_RESOURCEPLAN` (`RP_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;


-- 添加主键约束
ALTER TABLE WM_MAPPING ADD CONSTRAINT `WM_MAPPING_FK1` FOREIGN KEY (`RP_ID`) REFERENCES `WM_RESOURCEPLAN` (`RP_ID`);
ALTER TABLE WM_MAPPING ADD CONSTRAINT `WM_MAPPING_FK2` FOREIGN KEY (`POOL_ID`) REFERENCES `WM_POOL` (`POOL_ID`);
ALTER TABLE WM_POOL ADD CONSTRAINT WM_POOL_FK1 FOREIGN KEY(RP_ID) REFERENCES `WM_RESOURCEPLAN` (`RP_ID`);
ALTER TABLE WM_POOL_TO_TRIGGER ADD CONSTRAINT `WM_POOL_TO_TRIGGER_FK1` FOREIGN KEY (`POOL_ID`) REFERENCES `WM_POOL` (`POOL_ID`);
ALTER TABLE WM_POOL_TO_TRIGGER ADD CONSTRAINT `WM_POOL_TO_TRIGGER_FK2` FOREIGN KEY (`TRIGGER_ID`) REFERENCES `WM_TRIGGER` (`TRIGGER_ID`);
ALTER TABLE WM_RESOURCEPLAN ADD CONSTRAINT `WM_RESOURCEPLAN_FK1` FOREIGN KEY (`DEFAULT_POOL_ID`) REFERENCES `WM_POOL` (`POOL_ID`);
ALTER TABLE WM_TRIGGER ADD CONSTRAINT `WM_TRIGGER_FK1` FOREIGN KEY (`RP_ID`) REFERENCES `WM_RESOURCEPLAN` (`RP_ID`);
3.2需要更新字段的表
  • 数据为空的表,删除重建
序号 表名 hive3 hive2 备注
1 COMPLETED_TXN_COMPONENTS 7 4
2 DB_PRIVS 10 9 数据库权限
3 KEY_CONSTRAINTS 13 12
4 NOTIFICATION_LOG 9 8
5 PART_COL_PRIVS 11 10 分区列的授权信息
6 PART_COL_STATS 22 20 分区中列的统计信息
7 PART_PRIVS 10 9
8 PARTITION_EVENTS 7 6
9 TAB_COL_STATS 21 19 表中列的统计信息,包括数值类型的最大和最小值
10 TBL_COL_PRIVS 11 10 表中列的统计信息,包括数值类型的最大和最小值
11 TXN_COMPONENTS 6 5
-- ----------------------------
-- Table structure for COMPLETED_TXN_COMPONENTS
-- ----------------------------
DROP TABLE IF EXISTS `COMPLETED_TXN_COMPONENTS`;
CREATE TABLE `COMPLETED_TXN_COMPONENTS`  (
  `CTC_TXNID` bigint(20) NOT NULL,
  `CTC_DATABASE` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `CTC_TABLE` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `CTC_PARTITION` varchar(767) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `CTC_TIMESTAMP` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `CTC_WRITEID` bigint(20) NULL DEFAULT NULL,
  `CTC_UPDATE_DELETE` char(1) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  INDEX `COMPLETED_TXN_COMPONENTS_IDX`(`CTC_DATABASE`, `CTC_TABLE`, `CTC_PARTITION`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for DB_PRIVS
-- ----------------------------
DROP TABLE IF EXISTS `DB_PRIVS`;
CREATE TABLE `DB_PRIVS`  (
  `DB_GRANT_ID` bigint(20) NOT NULL,
  `CREATE_TIME` int(11) NOT NULL,
  `DB_ID` bigint(20) NULL DEFAULT NULL,
  `GRANT_OPTION` smallint(6) NOT NULL,
  `GRANTOR` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `GRANTOR_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PRINCIPAL_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PRINCIPAL_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `DB_PRIV` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `AUTHORIZER` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  PRIMARY KEY (`DB_GRANT_ID`) USING BTREE,
  UNIQUE INDEX `DBPRIVILEGEINDEX`(`AUTHORIZER`, `DB_ID`, `PRINCIPAL_NAME`, `PRINCIPAL_TYPE`, `DB_PRIV`, `GRANTOR`, `GRANTOR_TYPE`) USING BTREE,
  INDEX `DB_PRIVS_N49`(`DB_ID`) USING BTREE,
  CONSTRAINT `DB_PRIVS_FK1` FOREIGN KEY (`DB_ID`) REFERENCES `DBS` (`DB_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;


-- ----------------------------
-- Table structure for KEY_CONSTRAINTS
-- ----------------------------
DROP TABLE IF EXISTS `KEY_CONSTRAINTS`;
CREATE TABLE `KEY_CONSTRAINTS`  (
  `CHILD_CD_ID` bigint(20) NULL DEFAULT NULL,
  `CHILD_INTEGER_IDX` int(11) NULL DEFAULT NULL,
  `CHILD_TBL_ID` bigint(20) NULL DEFAULT NULL,
  `PARENT_CD_ID` bigint(20) NULL DEFAULT NULL,
  `PARENT_INTEGER_IDX` int(11) NOT NULL,
  `PARENT_TBL_ID` bigint(20) NOT NULL,
  `POSITION` bigint(20) NOT NULL,
  `CONSTRAINT_NAME` varchar(400) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `CONSTRAINT_TYPE` smallint(6) NOT NULL,
  `UPDATE_RULE` smallint(6) NULL DEFAULT NULL,
  `DELETE_RULE` smallint(6) NULL DEFAULT NULL,
  `ENABLE_VALIDATE_RELY` smallint(6) NOT NULL,
  `DEFAULT_VALUE` varchar(400) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  PRIMARY KEY (`CONSTRAINT_NAME`, `POSITION`) USING BTREE,
  INDEX `CONSTRAINTS_PARENT_TABLE_ID_INDEX`(`PARENT_TBL_ID`) USING BTREE,
  INDEX `CONSTRAINTS_CONSTRAINT_TYPE_INDEX`(`CONSTRAINT_TYPE`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for NOTIFICATION_LOG
-- ----------------------------
DROP TABLE IF EXISTS `NOTIFICATION_LOG`;
CREATE TABLE `NOTIFICATION_LOG`  (
  `NL_ID` bigint(20) NOT NULL,
  `EVENT_ID` bigint(20) NOT NULL,
  `EVENT_TIME` int(11) NOT NULL,
  `EVENT_TYPE` varchar(32) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `CAT_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `DB_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `TBL_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `MESSAGE` longtext CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL,
  `MESSAGE_FORMAT` varchar(16) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  PRIMARY KEY (`NL_ID`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for PART_COL_PRIVS
-- ----------------------------
DROP TABLE IF EXISTS `PART_COL_PRIVS`;
CREATE TABLE `PART_COL_PRIVS`  (
  `PART_COLUMN_GRANT_ID` bigint(20) NOT NULL,
  `COLUMN_NAME` varchar(767) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `CREATE_TIME` int(11) NOT NULL,
  `GRANT_OPTION` smallint(6) NOT NULL,
  `GRANTOR` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `GRANTOR_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PART_ID` bigint(20) NULL DEFAULT NULL,
  `PRINCIPAL_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PRINCIPAL_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PART_COL_PRIV` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `AUTHORIZER` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  PRIMARY KEY (`PART_COLUMN_GRANT_ID`) USING BTREE,
  INDEX `PART_COL_PRIVS_N49`(`PART_ID`) USING BTREE,
  INDEX `PARTITIONCOLUMNPRIVILEGEINDEX`(`AUTHORIZER`, `PART_ID`, `COLUMN_NAME`, `PRINCIPAL_NAME`, `PRINCIPAL_TYPE`, `PART_COL_PRIV`, `GRANTOR`, `GRANTOR_TYPE`) USING BTREE,
  CONSTRAINT `PART_COL_PRIVS_FK1` FOREIGN KEY (`PART_ID`) REFERENCES `PARTITIONS` (`PART_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for PART_COL_STATS
-- ----------------------------
DROP TABLE IF EXISTS `PART_COL_STATS`;
CREATE TABLE `PART_COL_STATS`  (
  `CS_ID` bigint(20) NOT NULL,
  `CAT_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT 'hive',
  `DB_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `TABLE_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `PARTITION_NAME` varchar(767) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `COLUMN_NAME` varchar(767) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `COLUMN_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `PART_ID` bigint(20) NOT NULL,
  `LONG_LOW_VALUE` bigint(20) NULL DEFAULT NULL,
  `LONG_HIGH_VALUE` bigint(20) NULL DEFAULT NULL,
  `DOUBLE_HIGH_VALUE` double(53, 4) NULL DEFAULT NULL,
  `DOUBLE_LOW_VALUE` double(53, 4) NULL DEFAULT NULL,
  `BIG_DECIMAL_LOW_VALUE` varchar(4000) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `BIG_DECIMAL_HIGH_VALUE` varchar(4000) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `NUM_NULLS` bigint(20) NOT NULL,
  `NUM_DISTINCTS` bigint(20) NULL DEFAULT NULL,
  `BIT_VECTOR` blob NULL,
  `AVG_COL_LEN` double(53, 4) NULL DEFAULT NULL,
  `MAX_COL_LEN` bigint(20) NULL DEFAULT NULL,
  `NUM_TRUES` bigint(20) NULL DEFAULT NULL,
  `NUM_FALSES` bigint(20) NULL DEFAULT NULL,
  `LAST_ANALYZED` bigint(20) NOT NULL,
  PRIMARY KEY (`CS_ID`) USING BTREE,
  INDEX `PART_COL_STATS_FK`(`PART_ID`) USING BTREE,
  INDEX `PCS_STATS_IDX`(`CAT_NAME`, `DB_NAME`, `TABLE_NAME`, `COLUMN_NAME`, `PARTITION_NAME`) USING BTREE,
  CONSTRAINT `PART_COL_STATS_FK` FOREIGN KEY (`PART_ID`) REFERENCES `PARTITIONS` (`PART_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for PART_PRIVS
-- ----------------------------
DROP TABLE IF EXISTS `PART_PRIVS`;
CREATE TABLE `PART_PRIVS`  (
  `PART_GRANT_ID` bigint(20) NOT NULL,
  `CREATE_TIME` int(11) NOT NULL,
  `GRANT_OPTION` smallint(6) NOT NULL,
  `GRANTOR` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `GRANTOR_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PART_ID` bigint(20) NULL DEFAULT NULL,
  `PRINCIPAL_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PRINCIPAL_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PART_PRIV` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `AUTHORIZER` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  PRIMARY KEY (`PART_GRANT_ID`) USING BTREE,
  INDEX `PARTPRIVILEGEINDEX`(`AUTHORIZER`, `PART_ID`, `PRINCIPAL_NAME`, `PRINCIPAL_TYPE`, `PART_PRIV`, `GRANTOR`, `GRANTOR_TYPE`) USING BTREE,
  INDEX `PART_PRIVS_N49`(`PART_ID`) USING BTREE,
  CONSTRAINT `PART_PRIVS_FK1` FOREIGN KEY (`PART_ID`) REFERENCES `PARTITIONS` (`PART_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for PARTITION_EVENTS
-- ----------------------------
DROP TABLE IF EXISTS `PARTITION_EVENTS`;
CREATE TABLE `PARTITION_EVENTS`  (
  `PART_NAME_ID` bigint(20) NOT NULL,
  `CAT_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `DB_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `EVENT_TIME` bigint(20) NOT NULL,
  `EVENT_TYPE` int(11) NOT NULL,
  `PARTITION_NAME` varchar(767) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `TBL_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  PRIMARY KEY (`PART_NAME_ID`) USING BTREE,
  INDEX `PARTITIONEVENTINDEX`(`PARTITION_NAME`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for TAB_COL_STATS
-- ----------------------------
DROP TABLE IF EXISTS `TAB_COL_STATS`;
CREATE TABLE `TAB_COL_STATS`  (
  `CS_ID` bigint(20) NOT NULL,
  `CAT_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT 'hive',
  `DB_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `TABLE_NAME` varchar(256) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `COLUMN_NAME` varchar(767) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `COLUMN_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL,
  `TBL_ID` bigint(20) NOT NULL,
  `LONG_LOW_VALUE` bigint(20) NULL DEFAULT NULL,
  `LONG_HIGH_VALUE` bigint(20) NULL DEFAULT NULL,
  `DOUBLE_HIGH_VALUE` double(53, 4) NULL DEFAULT NULL,
  `DOUBLE_LOW_VALUE` double(53, 4) NULL DEFAULT NULL,
  `BIG_DECIMAL_LOW_VALUE` varchar(4000) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `BIG_DECIMAL_HIGH_VALUE` varchar(4000) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `NUM_NULLS` bigint(20) NOT NULL,
  `NUM_DISTINCTS` bigint(20) NULL DEFAULT NULL,
  `BIT_VECTOR` blob NULL,
  `AVG_COL_LEN` double(53, 4) NULL DEFAULT NULL,
  `MAX_COL_LEN` bigint(20) NULL DEFAULT NULL,
  `NUM_TRUES` bigint(20) NULL DEFAULT NULL,
  `NUM_FALSES` bigint(20) NULL DEFAULT NULL,
  `LAST_ANALYZED` bigint(20) NOT NULL,
  PRIMARY KEY (`CS_ID`) USING BTREE,
  INDEX `TAB_COL_STATS_FK`(`TBL_ID`) USING BTREE,
  INDEX `TAB_COL_STATS_IDX`(`CAT_NAME`, `DB_NAME`, `TABLE_NAME`, `COLUMN_NAME`) USING BTREE,
  CONSTRAINT `TAB_COL_STATS_FK` FOREIGN KEY (`TBL_ID`) REFERENCES `TBLS` (`TBL_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;


-- ----------------------------
-- Table structure for TBL_COL_PRIVS
-- ----------------------------
DROP TABLE IF EXISTS `TBL_COL_PRIVS`;
CREATE TABLE `TBL_COL_PRIVS`  (
  `TBL_COLUMN_GRANT_ID` bigint(20) NOT NULL,
  `COLUMN_NAME` varchar(767) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `CREATE_TIME` int(11) NOT NULL,
  `GRANT_OPTION` smallint(6) NOT NULL,
  `GRANTOR` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `GRANTOR_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PRINCIPAL_NAME` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `PRINCIPAL_TYPE` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `TBL_COL_PRIV` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  `TBL_ID` bigint(20) NULL DEFAULT NULL,
  `AUTHORIZER` varchar(128) CHARACTER SET latin1 COLLATE latin1_bin NULL DEFAULT NULL,
  PRIMARY KEY (`TBL_COLUMN_GRANT_ID`) USING BTREE,
  INDEX `TABLECOLUMNPRIVILEGEINDEX`(`AUTHORIZER`, `TBL_ID`, `COLUMN_NAME`, `PRINCIPAL_NAME`, `PRINCIPAL_TYPE`, `TBL_COL_PRIV`, `GRANTOR`, `GRANTOR_TYPE`) USING BTREE,
  INDEX `TBL_COL_PRIVS_N49`(`TBL_ID`) USING BTREE,
  CONSTRAINT `TBL_COL_PRIVS_FK1` FOREIGN KEY (`TBL_ID`) REFERENCES `TBLS` (`TBL_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;

-- ----------------------------
-- Table structure for TXN_COMPONENTS
-- ----------------------------
DROP TABLE IF EXISTS `TXN_COMPONENTS`;
CREATE TABLE `TXN_COMPONENTS`  (
  `TC_TXNID` bigint(20) NOT NULL,
  `TC_DATABASE` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `TC_TABLE` varchar(128) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `TC_PARTITION` varchar(767) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL,
  `TC_OPERATION_TYPE` char(1) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL,
  `TC_WRITEID` bigint(20) NULL DEFAULT NULL,
  INDEX `TC_TXNID_INDEX`(`TC_TXNID`) USING BTREE,
  CONSTRAINT `TXN_COMPONENTS_ibfk_1` FOREIGN KEY (`TC_TXNID`) REFERENCES `TXNS` (`TXN_ID`) ON DELETE RESTRICT ON UPDATE RESTRICT
) ENGINE = InnoDB CHARACTER SET = latin1 COLLATE = latin1_swedish_ci ROW_FORMAT = Dynamic;
  • 数据不为空的表
序号 表名 hive3 hive2 备注
1 DBS 7 6 存放数据库信息
2 GLOBAL_PRIVS 9 8
3 SERDES 7 3 hive序列化相关的东西
4 TBL_PRIVS 10 9 权限表,重点看一下
5 TBLS 13 12
6 TXNS 10 9
  • 执行sql
ALTER TABLE `DBS` ADD CTLG_NAME VARCHAR(255) DEFAULT 'hive';
ALTER TABLE `GLOBAL_PRIVS` ADD AUTHORIZER VARCHAR(255) DEFAULT 'SQL';
ALTER TABLE `SERDES` ADD DESCRIPTION	varchar(4000);
ALTER TABLE `SERDES` ADD SERIALIZER_CLASS	varchar(4000);
ALTER TABLE `SERDES` ADD DESERIALIZER_CLASS	varchar(4000);
ALTER TABLE `SERDES` ADD SERDE_TYPE		int(11) DEFAULT 0;
ALTER TABLE `TBL_PRIVS` ADD AUTHORIZER varchar(128) DEFAULT 'SQL';
ALTER TABLE `TBLS` ADD OWNER_TYPE	varchar(10) DEFAULT 'USER';
ALTER TABLE `TXNS` ADD TXN_TYPE	int(11);

3.3需要更改数据的表
  • VERSION需要更改一下版本号

    UPDATE `hive2`.`VERSION` SET `SCHEMA_VERSION` = '3.1.3', `VERSION_COMMENT` = 'Hive release version 3.1.3' WHERE `VER_ID` = 1;
    
  • DBS需要更新数据库对应的路径文章来源地址https://www.toymoban.com/news/detail-709716.html

UPDATE `hive2`.`DBS` SET `DESC` = NULL, `DB_LOCATION_URI` = 'hdfs://ip-10-5-1-85.ec2.internal:8020/user/hive/warehouse/dyh2.db', `NAME` = 'dyh2', `OWNER_NAME` = 'hadoop', `OWNER_TYPE` = 'USER', `CTLG_NAME` = 'hive' WHERE `DB_ID` = 2;

4.hive3上集群需要的操作

4.1更改元数据对应的库名
  • 修改/etc/hive/conf/hive-site.xml文件
<value>jdbc:mysql://ip:3306/hive_metastore?createDatabaseIfNotExist=true</value>
4.2重启HiveMetaStore对应服务
sudo jps | grep Jar
sudo kill -9 pid

二、hive3新特性

  1. 执行引擎变更为**TEZ**,不使用MR
  2. 成熟的ACID大数据事务支持
  3. LLAP用于妙极,毫秒级查询访问
  4. 基于Apache Ranger的统一权限管理
  5. 默认开启HDFS ACLs
  6. Beeline代替Hive Cli,降低启动开销
  7. 不再支持内嵌Metastore
  8. Spark Catalog不与Hive Catalog集成,但可以互相访问
  9. 批处理使用TEZ,实时查询使用LLAP
  10. Hive3支持联邦查询

到了这里,关于hive3升级的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包 赞助服务器费用

相关文章

  • Hive3 on Spark3配置

    大数据组件 版本 Hive 3.1.2 Spark spark-3.0.0-bin-hadoop3.2 OS 版本 MacOS Monterey 12.1 Linux - CentOS 7.6 1)Hive on Spark说明 Hive引擎包括:默认 mr 、 spark 、 Tez 。 Hive on Spark :Hive既作为存储元数据又负责SQL的解析优化,语法是HQL语法,执行引擎变成了Spark,Spark负责采用RDD执行。 Spark on Hive :

    2024年02月04日
    浏览(39)
  • centos7上hive3.1.3安装及配置

    hive是基于hadoop的数据仓库软件,部署运行在linux系统之上,安装之前必须保证hadoop环境运行正常,hive本身不是分布式软件,它的分布式主要是借助hadoop实现,存储是hdfs,计算是mapreduce。 需要同时安装apache-hive-3.1.3-bin.tar.gz和mysql-5.7.42-1.el7.x86_64.rpm-bundle.tar两个软件,因为hive的

    2024年02月09日
    浏览(43)
  • hadoop3.2.1+hive3.1.2-docker安装

    建立hadoop用的内部网络(此步出错,若与其它网段冲突,可省略) #指定固定ip号段 建立Master容器,映射端口 10000端口为hiveserver2端口,后面本地客户端要通过beeline连接hive使用,有其他组件要安装的话可以提前把端口都映射出来 若创建了网段则可指定网段运行 创建slave1 172.17.

    2024年02月08日
    浏览(40)
  • hive修改spark版本重新编译,hive3.1.3 on spark3.3.0

    我的是hive3.1.3 spark3.3.0(请先将自己的 hive on mr 搭建完场,有简单了解在搞这个) 1.下载hive源码 2. maven编译:mvn clean -DskipTests package -Pdist (idea 编译不行,能行的评论告诉我) 右键 - Git Bash idea打开项目,右键pom 添加成maven项目 修改pom中自己所需依赖的版本

    2023年04月21日
    浏览(52)
  • 关于hive3多表leftjoin导致数据丢失问题及解决方案

    最近业务场景需要将一张大表通过name名字关联多个小表去获取他们的id,大表数据9000w,小表数据最大180w,最小30w,我以主表leftjoin的时候发现了数据丢失问题 代码如下  结果显示数据我t7的数据由180w剩下9w,发生了严重的数据丢失,在别的表也有不同程度的丢失问题. 最后发现这个问

    2024年02月15日
    浏览(53)
  • Java(115)Java通过jdbc接口连接hive3.1.2

    hive版本:3.1.2 jdbc:hive-jdbc-uber-2.6.5.0-292.jar 下载驱动地址:https://github.com/timveil/hive-jdbc-uber-jar/releases/tag/v1.9-2.6.5 CREATE TABLE regre_one.hive2_varchar( ID int, aes varchar(1000), sm4 varchar(1000), sm4_a varchar(1000), email varchar(1000), phone varchar(1000), ssn varchar(1000), military varchar(1000), passport varchar(1000)

    2024年02月05日
    浏览(53)
  • Ubuntu下安装Hive3.1.2教程(附MySQL安装方法及安装包)

    Hive 的安装需要建立在 Hadoop 的之上(类似于Hbase) ,关于 Hadoop 的单机安装以及伪分布式安装可以参考作者的另两篇博客: Ubuntu下单机安装Hadoop详细教程(附所需安装包下载) Ubuntu下伪分布式安装Hadoop详细教程 本文安装的 Hadoop 及 Java 环境基于林子雨老师的《大数据技术原

    2024年02月04日
    浏览(51)
  • [sqoop]hive3.1.2 hadoop3.1.1安装sqoop1.4.7

    Hadoop3.2.4+Hive3.1.2+sqoop1.4.7安装部署_hadoop sqoop安装_alicely07的博客-CSDN博客 sqoop-env.sh 末尾添加 环境变量 先创建目录,解决警告:accumulo does not exist! (1)添加jdbc驱动包:将MySQL数据库的JDBC驱动包mysql-connector-java-5.1.37.jar添加到Sqoop安装目录的lib目录中。 (2)删除Sqoop安装目录的

    2024年02月07日
    浏览(60)
  • 一百零一、Kettle——Kettle8.2.0本地连接Hive3.1.2(踩坑,亲测有效)

    这是目前遇到的最简单但最头疼的安装,因为是在公司之前用过的服务器上进行安装测试,加上又使用比较新的版本,结果踩了不少坑。Kettle连接Hive这个坑,从2023年4月11日下午开始,一致到2023年4月12日中午才弄好,不得不写篇博客记录一下这段难忘的经历。 真是郁闷了半天

    2024年02月07日
    浏览(48)
  • 一百六十、Kettle——Linux上安装的Kettle9.2.0连接Hive3.1.2

    Kettle9.2.0在Linux上安装好后,需要与Hive3.1.2数据库建立连接 之前已经在本地上用kettle9.2.0连上Hive3.1.2 kettle9.2.0安装包网盘链接 链接:https://pan.baidu.com/s/15Zq9wNDwyMnc3qFVxYOMXw?pwd=zwae  提取码:zwae 1、Hive312的lib里面MySQL驱动包的版本是mysql-connector-java-5.1.37.jar 2、Kettle9.2里MySQL驱动包的

    2024年02月12日
    浏览(68)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包