performance
谁动了我的 CPU 频率 —— CPU 性能之迷 Part 2
· ☕ 20 åˆ†é’Ÿ
很多人知道 CPU 频率会影响 CPU 性能,也知道频率会动态变化,且知道 Linux 有 performance/powersave 两种频率控制策略。但很少人知道背后的软件原理,更少人知道如何调优策略,和监控实际 CPU 频率。

被误解的CPU利用率、超线程、动态调频 —— CPU 性能之迷 Part 1
· ☕ 17 åˆ†é’Ÿ
CPU利用率,这个再常用,且看似简单不过的指标,在超线程、动态调频等技术影响下,其准确性、估算参考价值,均出现了大问题。

Java 容器化的历史坑(史坑) - 资源限制篇
· ☕ 5 åˆ†é’Ÿ
由来 时间回到 2017 年,老东家要上 Kubernetes 了,有幸参与和学习(主要是学习)。当时遇到的一了所有 Java 容器化者都遇到的坑:JDK8 不为容器化设计综合症。最简单

你的 Istio Mesh 性能及格吗?
· ☕ 4 åˆ†é’Ÿ
前言 话说,一年前项目响应时代的号召,引入了 Istio,从此如刘备得卧龙、凤雏,走上了 Service Mesh 的光辉大道。现到准备益州之战(上线)之时。上线前,还

Benchmark Tools
· ☕ 1 åˆ†é’Ÿ
CPU Benchmark The SysBench system benchmark suite has a simple CPU benchmark tool that calculates prime numbers. For example: # sysbench --num-threads=8 --test=cpu --cpu-max-prime=100000 run sysbench 0.4.12: multi-threaded system evaluation benchmark Running the test with following options: Number of threads: 8 Doing CPU performance benchmark Threads started! Done. Maximum prime number checked in CPU test: 100000 Test execution summary: total time: 30.4125s total number of events: 10000 total time taken by event execution: 243.

Awesome load test tools
· ☕ 1 åˆ†é’Ÿ
k6 https://github.com/k6io/k6 Locust https://docs.locust.io/en/stable/what-is-locust.html gatling https://gatling.io/docs/current/http/http_request/ artillery https://artillery.io/docs/guides/overview/welcome.html wrk https://github.com/wg/wrk

· ☕ 1 åˆ†é’Ÿ
Base cgroup files tasks: list of tasks (by PID) attached to that cgroup. This list is not guaranteed to be sorted. Writing a thread ID into this file moves the thread into this cgroup. cgroup.procs: list of thread group IDs in the cgroup. This list is not guaranteed to be sorted or free of duplicate TGIDs, and userspace should sort/uniquify the list if this property is required. Writing a thread group ID into this file moves all threads in that group into this cgroup.

· ☕ 4 åˆ†é’Ÿ
What are cpusets ? Cpusets provide a mechanism for assigning a set of CPUs and Memory Nodes to a set of tasks. In this document “Memory Node” refers to an on-line node that contains memory. Cpusets constrain the CPU and Memory placement of tasks to only the resources within a task’s current cpuset. They form

· ☕ 1 åˆ†é’Ÿ
Monitor https://www.kernel.org/doc/html/latest/admin-guide/numastat.html /sys/devices/system/node/node*/numastat In more detail: numa_hit A process wanted to allocate memory from this node, and succeeded. numa_miss A process wanted to allocate memory from another node, but ended up with memory from this node. numa_foreign A process wanted to allocate on this node, but ended up with memory from another node. local_node A process ran on this node’s CPU, and got memory from this node. other_node A process ran on a different node’s CPU and got memory from this node.

CPU 负载测量误差
· ☕ 1 åˆ†é’Ÿ
CPU 负载测量误差 CPU load Linux exports various bits of information via /proc/stat and /proc/uptime that userland tools, such as top(1), use to calculate the average time system spent in a particular state, for example: $ iostat Linux 2.6.18.3-exp (linmac) 02/20/2007 avg-cpu: %user %nice %system %iowait %steal %idle 10.01 0.00 2.92 5.44 0.00 81.63 ... Here the system thinks that over the default sampling period the