n0derunner

    Back to basics – gprof PT1 (generating a profile)

    Published: (Updated: ) in Linux, , , , by . Leave a Comment on Back to basics – gprof PT1 (generating a profile).

    A while ago at work we were discussing the pros and cons of the classic Linux profiler gprof… What are profiles useful for? The output of a profile run against a very simple program looks like the example below. It tells us that of the 5.82 seconds of profiled runtime It also tells us that […]

    Linux memory monitoring (allocations Vs usage)

    Published: (Updated: ) in Linux, , , , , by . Leave a Comment on Linux memory monitoring (allocations Vs usage).

    How to use some of Linux’s standard tools and how different types of memory usage shows up. Examples of using malloc and writing to memory with three use-cases for a simple process In each case we run the example with a 64MB allocation so that we can see the usage from standard linux tools. We […]

    Using iperf multi-stream may not work as expected

    Published: (Updated: ) in Linux, , , , by . 2 Comments on Using iperf multi-stream may not work as expected.

    Running iperf with parallel threads TL;DR – When running iperf with parallel threads/workers the -P option must be specified after the -c <target-IP> option. This is mentioned in the manpage but some options (-t for instance) work in any order, while others (specifically the -P for parallel threads) definitely does not, which is a bit […]

    mpstat has an option to show utilization per NUMA node

    Published: (Updated: ) in Linux, , by . Leave a Comment on mpstat has an option to show utilization per NUMA node.

    Not sure how long this has been a thing, but I recently discovered that mpstat takes a -N option for “NUMA Node” that works in the same way as -P for “Processor”. e.g. $ mpstat -N 0,1 1 will show stats for NUMA nodes 0 and 1 every 1 second. Just like mpstat -P ALL […]