码农知识堂 - 1000bd
  •   Python
  •   PHP
  •   JS/TS
  •   JAVA
  •   C/C++
  •   C#
  •   GO
  •   Kotlin
  •   Swift
  • presto安装部署教程


    1.下载安装包

    https://repo1.maven.org/maven2/com/facebook/presto/presto-server/0.273.3/presto-server-0.273.3.tar.gz

    并解压到安装目录 ,进入安装目录,创建配置etc目录

    2.配置config.properties

    进入安装目录,增加配置文件config.properties

    1. vi config.properties
    2. coordinator=true
    3. node-scheduler.include-coordinator=true
    4. http-server.http.port=8080
    5. query.max-memory=1GB
    6. query.max-memory-per-node=512MB
    7. query.max-total-memory-per-node=512MB
    8. discovery-server.enabled=true
    9. discovery.uri=http://localhost:8080

     

    3.配置 jvm.config 

    1. vi jvm.config
    2. -server
    3. -Xmx8G
    4. -XX:+UseG1GC
    5. -XX:G1HeapRegionSize=32M
    6. -XX:+UseGCOverheadLimit
    7. -XX:+ExplicitGCInvokesConcurrent
    8. -XX:+HeapDumpOnOutOfMemoryError
    9. -XX:+ExitOnOutOfMemoryError

    4.配置node.properties

    1. vi node.properties
    2. node.environment=production
    3. node.id=ffffffff-ffff-ffff-ffff-ffffffffffff
    4. node.data-dir=/var/presto/data

    创建数据目录/var/presto/data并赋权 

    5.连接hive 在etc下创建配置目录catalog,增加hive.properties 配置

    mkdir etc/catalog
    1. cat catalog/hive.properties
    2. connector.name=hive-hadoop2
    3. hive.metastore.uri=thrift://hive-master:9083
    4. hive.config.resources=/etc/hadoop/conf/core-site.xml,/etc/hadoop/conf/hdfs-site.xml,/etc/hadoop/conf/mapred-site.xml
    5. hive.allow-add-column=true
    6. hive.allow-drop-column=true
    7. hive.allow-drop-table=true
    8. hive.allow-rename-table=true
    9. hive.allow-rename-column=true
    10. hive.parquet.use-column-names=true

     presto安装问题(java.net.UnknownHostException)

    解决方案:在hive.properties 增加如下配置

    hive.config.resources=/etc/hadoop/hdfs-site.xml,/etc/hadoop/core-site.xml

    注意:路径是hadoop配置文件hdfs-site.xml和core-site.xml的路径

    6.启动 

    1. ./bin/launcher run 可以控制台直接查看日志
    2. ./bin/launcher start 后台启动

    7.连接查询

    下载启动client包,https://repo1.maven.org/maven2/com/facebook/presto/presto-cli/0.273.3/presto-cli-0.273.3-executable.jar 

    重命名并赋权

    1. mv presto-cli-0.273.3-executable.jar presto
    2. chmod 755 presto

     presto连接hive查询

    ./presto --server localhost:8080 --catalog hive --schema default

     

     

    参照文档:

    Deploying Presto — Presto 0.273.3 Documentation 

  • 相关阅读:
    AI绘画:SD绘画实操过程-云龙-高瑶制作教程(附资料及变现)
    Apache DolphinScheduler在中国信通院“2023 OSCAR开源尖峰案例”评选中荣获「尖峰开源项目奖」!
    Linux系统编程系列之进程间通信-信号量组
    2022大厂高频面试题之Vue篇
    Oracle的立场:官网更换首页与以色列站在一起
    成为数字游民,他们为何「All in Web3」?
    SpringSecurity Oauth2实战 - 08 SpEL权限表达式源码分析及两种权限控制方式原理
    林浩然与杨凌芸的Java List大冒险
    opencv python debug记录
    初识OpenGL (-)多级渐远纹理(Mipmap)
  • 原文地址:https://blog.csdn.net/ZYC88888/article/details/125996192
  • 最新文章
  • 攻防演习之三天拿下官网站群
    数据安全治理学习——前期安全规划和安全管理体系建设
    企业安全 | 企业内一次钓鱼演练准备过程
    内网渗透测试 | Kerberos协议及其部分攻击手法
    0day的产生 | 不懂代码的"代码审计"
    安装scrcpy-client模块av模块异常,环境问题解决方案
    leetcode hot100【LeetCode 279. 完全平方数】java实现
    OpenWrt下安装Mosquitto
    AnatoMask论文汇总
    【AI日记】24.11.01 LangChain、openai api和github copilot
  • 热门文章
  • 十款代码表白小特效 一个比一个浪漫 赶紧收藏起来吧!!!
    奉劝各位学弟学妹们,该打造你的技术影响力了!
    五年了,我在 CSDN 的两个一百万。
    Java俄罗斯方块,老程序员花了一个周末,连接中学年代!
    面试官都震惊,你这网络基础可以啊!
    你真的会用百度吗?我不信 — 那些不为人知的搜索引擎语法
    心情不好的时候,用 Python 画棵樱花树送给自己吧
    通宵一晚做出来的一款类似CS的第一人称射击游戏Demo!原来做游戏也不是很难,连憨憨学妹都学会了!
    13 万字 C 语言从入门到精通保姆级教程2021 年版
    10行代码集2000张美女图,Python爬虫120例,再上征途
Copyright © 2022 侵权请联系2656653265@qq.com    京ICP备2022015340号-1
正则表达式工具 cron表达式工具 密码生成工具

京公网安备 11010502049817号