Retrieve CPU and Memory Information on FreeBSD
Server running slow and how to check CPU/Processor and RAM/Memory info on FreeBSD? There are couple of ways to retrieve the information, by dmesg or sysctl.
Check CPU/Processor Speed on FreeBSD
Get CPU info by sysctl;
1 2 3 4 5 6 7 8 9 10 11 12 |
shell> sysctl -a | egrep -i 'machine|model|ncpu' hw.machine: i386 hw.model: Intel(R) Pentium(R) D CPU 3.00GHz hw.ncpu: 2 hw.machine_arch: i386 |
Get CPU info by dmesg boot message;
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
shell> egrep -i cpu /var/run/dmesg.boot CPU: Intel(R) Pentium(R) D CPU 3.00GHz (2998.50-MHz 686-class CPU) FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs cpu0 (BSP): APIC ID: 0 cpu1 (AP): APIC ID: 1 cpu0: <ACPI CPU> on acpi0 acpi_perf0: <ACPI CPU Frequency Control> on cpu0 acpi_perf0: <ACPI CPU Frequency Control> on cpu0 cpu1: <ACPI CPU> on acpi0 acpi_perf1: <ACPI CPU Frequency Control> on cpu1 acpi_perf1: <ACPI CPU Frequency Control> on cpu1 SMP: AP CPU #1 Launched! |
Check Total Memory/RAM on FreeBSD
Get Memory/RAM information from dmesg boot message;
1 2 3 4 5 6 7 8 9 |
shell> grep -i 'memory' /var/run/dmesg.boot real memory = 1072107520 (1022 MB) avail memory = 1039966208 (991 MB) |