RocketMQ into the 500,000-TPS Message Club

Image for post
Image for post

Foreword

Explore RocketMQ High-performance Optimization

Java

JVM Pauses

Image for post
Image for post
-XX:+LogVMOutput -XX:LogFile=/dev/shm/vm.log 
-XX:+PrintGCApplicationStoppedTime -XX:+PrintSafepointStatistics
-XX:PrintSafepointStatisticsCount=1 -XX:+PrintGCApplicationConcurrentTime

GC

-server -Xms8g -Xmx8g -Xmn4g
-XX:+UseG1GC -XX:G1HeapRegionSize=16m -XX:G1ReservePercent=25
-XX:InitiatingHeapOccupancyPercent=30 -XX:SoftRefLRUPolicyMSPerMB=0
-XX:SurvivorRatio=8 -XX:+DisableExplicitGC
-verbose:gc -Xloggc:/dev/shm/mq_gc_%p.log -XX:+PrintGCDetails
-XX:+PrintGCDateStamps -XX:+PrintGCApplicationStoppedTime
-XX:+PrintAdaptiveSizePolicy
-XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=30m

Thread Pool

Image for post
Image for post

CPU

CPU Affinity

Image for post
Image for post
Image for post
Image for post

NUMA

Image for post
Image for post
vi /boot/grub/grub.conf
Add the boot parameter: numa=on
numactl --hardware
If you see more than one node, it indicates that it supports NUMA.

Memory

Image for post
Image for post

Page Error

1. ps -o min_flt,maj_flt <PID>
2. sar –B
Image for post
Image for post
Image for post
Image for post
echo '* hard memlock unlimited' >> /etc/security/limits.conf
echo '* soft memlock unlimited' >> /etc/security/limits.conf

Huge Page

NIC

Network Card Interruption

Interruption Aggregation

Summary

Image for post
Image for post
Image for post
Image for post

Follow me to keep abreast with the latest technology news, industry insights, and developer trends.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store