Hadoop and HBase Optimization for Read Intensive Search Applications 이란 Intel의 포스트를 통해서 Bizosys라는 회사가 어떻게 Read Performance를 향상시킨 사례가 있어서  정리했다. 


1. SSD 사용

2. hadoop,hbase에서 사용하는 zlib 을 Intel 병렬 프로세스에 최적화할 수 있도록 소스 컴파일하여 preview 부분과 index 압축을 최적화함

3. hadoop & hbase 설정 변경


Configuration FilePropertyDescriptionValue
hdfs-site.xmldfs.block.sizeLower value offers parallelism.33554432
dfs.datanode.handler.countNumber of handlers dedicated to serve data block requests in hadoop DataNodes.100
core-site.xmlio.file.buffer.sizeThis is the read and write buffer size. By setting limit to 16KB it allows continuous streaming.16384
hbase-site.xmlhbase.regionserver.handler.countRPC Server instances spun up on HBase RegionServers100
hfile.min.blocksize.sizeSmall size increases the index but reduces the lesser fetch on a random access.65536
default.xmlSCAN_IPC_CACHE_LIMITNumber of rows cached in Bizosys search engine for each scanner next call over the wire. It reduces the network round trip by 300 times caching 300 rows in each trip.300
LOCAL_JOB_HANDLER_COUNTNumber of parallel queries executed at one go. Query requests above than this limit gets queued up.100


4. jvm옵션
1) heap : 4G
2) gc : "-server -XX:+UseParallelGC -XX:ParallelGCThreads=4 -XX:+AggressiveHeap -XX:+HeapDumpOnOutOfMemoryError" 

5. Hbase에 customized index 사용하여 효과를 얻음

<얻은 효과>
1.  IPC 최적화는 33% 성능을 좋아졌다.
2. IPC 최적화 적용상태에서 JVM GC 튜닝은 16% 좋아졌다.
3. GC 튜닝후, Custom index를 적용했더니 62.5% 좋아졌다. 
4. Custom Index 적용후, SSD 적용했더니 66% 좋아졌다.

cache eviction를 위해서 Block Cache는 전체 Heap (4G)의 20% (800M)로 지정. 


Posted by '김용환'
,