Collect system artifacts
Now we are collecting system information that can be useful for analysis after running tests.
-
uname -a
: This command provides general information about the system, including the kernel name, its version, as well as information about the machine and operating system. -
lscpu
: This command outputs detailed information about the CPU, including its architecture, number of cores, threads, frequency, and more. -
cat /proc/meminfo
: Provides detailed information about the system's memory, including total volume, free and used memory, as well as cache and buffers. -
lsblk
: Displays information about all available block devices (such as hard drives and their partitions). -
df -h
: Shows information about disk space usage in a readable format (using units like GB, MB). -
sysctl -a
: Outputs all current system kernel parameters. -
sysctl -p
: Displays kernel parameters that have been changed relative to default values. This can be useful for identifying any settings that have been configured to optimize PostgreSQL performance. -
cat /sys/kernel/mm/transparent_hugepage/enabled
: Shows the current state of transparent huge pages, which is important for database performance optimization. -
ps -auxf
: Provides a snapshot of all current processes in the system in a tree format. -
Observation of system resources using
sar
-
start_sar_observation()
andstop_sar_observation()
functions.
-
-
Observation of processes using
pidstat
-
start_pidstat_observation()
andstop_pidstat_observation()
functions.
-
ls -l /tmp/ARTIFACTS/2023-12-25-2023_wal_compression_ON/ | grep .txt
-rw-r--r-- 1 root root 2663 Dec 25 20:23 cpu_info.txt
-rw-r--r-- 1 root root 465 Dec 25 20:23 disk_info.txt
-rw-r--r-- 1 root root 371 Dec 25 20:23 disk_space_info.txt
-rw-r--r-- 1 root root 38515 Dec 25 20:23 kernel_parameters.txt
-rw-r--r-- 1 root root 476 Dec 25 20:23 kernel_parameters_non_default.txt
-rw-r--r-- 1 root root 1503 Dec 25 20:23 mem_info.txt
-rw-r--r-- 1 root root 17 Dec 25 20:23 pgbouncer_version.txt
-rw-r--r-- 1 root root 14160 Dec 25 20:23 processes_snapshot.txt
-rw-r--r-- 1 root root 136 Dec 25 20:23 system_info.txt
-rw-r--r-- 1 root root 23 Dec 25 20:23 transparent_hugepage_info.txt
ls -l /tmp/ARTIFACTS/2023-12-26-2054_wal_compression_OFF/ | grep sar
-rw-r--r-- 1 root root 25371 Dec 26 20:54 sar_all_cpu_usage.txt
-rw-r--r-- 1 root root 5126 Dec 26 20:54 sar_cpu_usage.txt
-rw-r--r-- 1 root root 31808 Dec 26 20:54 sar_disk_usage.txt
-rw-r--r-- 1 root root 7772 Dec 26 20:54 sar_memory_usage.txt
-rw-r--r-- 1 root root 12836 Dec 26 20:54 sar_network_usage.txt
ls -l /tmp/ARTIFACTS/2023-12-26-2048_wal_compression_OFF/ | grep pidstat
-rw-r--r-- 1 root root 100292 Dec 26 20:48 pidstat_cpu_usage.txt
-rw-r--r-- 1 root root 90112 Dec 26 20:48 pidstat_disk_usage.txt
-rw-r--r-- 1 root root 97616 Dec 26 20:48 pidstat_memory_usage.txt
Additionally:
- PgBouncer version (if installed)
- Remove
PGBENCH_SCALE_FACTOR
variable - Add
PGBENCH_INIT_COMMAND
variable - Add 'info' function and improve formatting
- Add 'prefixes' function (alias for ts)
- Add '_PSQL' function (alias for psql)
- Code refactoring.