本文共 1578 字,大约阅读时间需要 5 分钟。
通过选择适合的镜像获取 Apache Atlas 1.2.0 源码包,并上传至您的 Linux环境下进行解压:
tar -zxvf apache-atlas-1.2.0-sources.tar.gz
解压后即可获得 Atlas 源码目录。
进入 Atlas 源码目录,使用 Maven 进行编译:
mvn clean -DskipTests package -Pdist,embedded-hbase-solr
编译完成后,目标文件会出现在:
/export/servers/apache-atlas-sources-1.2.0/distro/target
修改 atlas-application.properties 配置文件,根据需求调整以下参数:
atlas.graph.storage.backend=hbaseatlas.graph.storage.hbase.table=apache_atlas_janusatlas.graph.storage.hostname=localhost
atlas.graph.storage.hbase.regions-per-server=1
atlas.notification.embedded=true
修改 hive-site.xml 添加 Atlas 插件:
hive.exec.post.hooks org.apache.atlas.hive.hook.HiveHook
更新 hive-env.sh 文件,添加 HIVE_AUX_JARS_PATH:
export HIVE_AUX_JARS_PATH=/export/servers/apache-atlas-sources-1.2.0/distro/target/apache-atlas-1.2.0-server/apache-atlas-1.2.0/hook/hive
启动 Atlas 服务:
Renderer报错是因为缺少某些 Jackson 包,建议手动获取并部署:```bashscp -r hive root@node02:/export/servers/apache-atlas-sources-1.2.0/distro/target/apache-atlas-1.2.0-server/apache-atlas-1.2.0/hook/scp
重启 Hive 后,导入历史数据:
./import-hive.sh
验证服务状态,确保 HBase 和 Solr 正常运行。
Atlas通过监听 Hive 的 DDL、DML 事件,构建实体间的血缘关系。
修改 hive-site.xml,添加自定义 Hook 插件,确保路径正确。
输入默认账户密码,完成数据导入后,访问 Atlas WebUI 查看数据。
通过 UI 查看实体间的血缘关系和操作历史,定位数据来源和流向。
通过以上步骤,您可以成功搭建并集成 Apache Atlas 1.2.0 与 Hive,实现元数据管理与数据资产价值提升。
转载地址:http://amvpz.baihongyu.com/