当前位置:网站首页>解决小文件处过多
解决小文件处过多
2022-07-06 09:01:00 【棱镜7】
1. 使用hive自带的concatenate命令,自动合并小文件
使用方法:
2. 调整参数减少map数量
在执行map前进行小文件合并,在 mapper 中将多个文件合成一个 split 作为输入。调整split 的至少大小
3. 减少Reduce的数量
reduce 的个数决定了输出的文件的个数,所以可以调整 reduce 的个数控制 hive表的文件数量。
4. HAR归档
使用hadoop的archive将小文件归档,能够将多个小文件打包成一个har文件
5. jvm重用
Hadoop的默认配置通常是使用派生JVM来执行map和Reduce任务的。这时JVM的启动过程可能会造成相当大的开销,尤其是执行的job包含有成百上千task任务的情况。JVM重用可以使得JVM实例在同一个job中重新使用N次。
这个功能的缺点是,开启JVM重用将一直占用使用到的task插槽,以便进行重用,直到任务完成后才能释放。
边栏推荐
- leetcode-14. Longest common prefix JS longitudinal scanning method
- Kratos战神微服务框架(一)
- Selenium+pytest automated test framework practice (Part 2)
- Global and Chinese markets for hardware based encryption 2022-2028: Research Report on technology, participants, trends, market size and share
- LeetCode41——First Missing Positive——hashing in place & swap
- Intel distiller Toolkit - Quantitative implementation 3
- Implement window blocking on QWidget
- Global and Chinese market of AVR series microcontrollers 2022-2028: Research Report on technology, participants, trends, market size and share
- Redis之主从复制
- [oc]- < getting started with UI> -- common controls uibutton
猜你喜欢
The five basic data structures of redis are in-depth and application scenarios
Pytest参数化你不知道的一些使用技巧 /你不知道的pytest
postman之参数化详解
LeetCode41——First Missing Positive——hashing in place & swap
Servlet learning diary 8 - servlet life cycle and thread safety
Redis之哨兵模式
Improved deep embedded clustering with local structure preservation (Idec)
An article takes you to understand the working principle of selenium in detail
Redis之主从复制
Solve the problem of inconsistency between database field name and entity class attribute name (resultmap result set mapping)
随机推荐
CUDA realizes focal_ loss
QML control type: menu
Publish and subscribe to redis
KDD 2022论文合集(持续更新中)
Implement window blocking on QWidget
Blue Bridge Cup_ Single chip microcomputer_ PWM output
Pytest参数化你不知道的一些使用技巧 /你不知道的pytest
Redis' bitmap
Advanced Computer Network Review(3)——BBR
【shell脚本】使用菜单命令构建在集群内创建文件夹的脚本
基于B/S的影视创作论坛的设计与实现(附:源码 论文 sql文件 项目部署教程)
What is MySQL? What is the learning path of MySQL
使用标签模板解决用户恶意输入的问题
什么是MySQL?MySql的学习之路是怎样的
Digital people anchor 618 sign language with goods, convenient for 27.8 million people with hearing impairment
Mysql database recovery (using mysqlbinlog command)
Kratos战神微服务框架(二)
Redis分布式锁实现Redisson 15问
Go redis initialization connection
Le modèle sentinelle de redis