Linux: How To Identify Server ECC Memory Modules

See all GNU/Linux related FAQ
Let us see how to identify Linux server ECC memory modules from a shell prompt using various commands.

You need to count the chips on the module. If the memory module has nine chips per side, it is ECC memory (EDAC-protected memory). It may or may not be registered. If the memory module has eight chips per side, it is not an ECC memory module. You can get this information by visiting your BIOS setup menu. Another option is to use dmidecode command to dump bios memory information from a shell prompt.
Tutorial details
Difficulty level Easy
Root privileges Yes
Requirements Linux or Unix terminal
Category System Management
OS compatibility AIX AlmaLinux Alpine Amazon Linux Arch BSD CentOS Debian Fedora FreeBSD HP-UX Linux macOS Mint NetBSD OpenBSD openSUSE Pop!_OS RHEL Rocky Stream SUSE Ubuntu Unix WSL
Est. reading time 5 minutes

How To Identify Linux Server ECC Memory Modules

To check if ECC RAM is present or not on the Linux or Unix server or workstation-grade motherboard:

  1. Open Linux or Unix terminal application.
  2. Run the command to see detailed information about the memory modules installed on your system
    $ sudo dmidecode -t memory
  3. Enter your password when prompted by the sudo command
  4. You must look for the “Error Correction Type” field in the output. For example, If ECC RAM is installed, you should see “Error Correction Type: ECC” or “Error Correction Type: Single-bit ECC” or “Error Correction Type: Multi-bit ECC” for the corresponding memory module(s) installed in the system.
  5. You can also use the sudo dmesg | grep -i EDAC command to check ecc RAM on Linux.

Let us see Unix and Linux command examples in details.

By default, dmidecode command may not be installed on your system. Hence, use the apk command on Alpine Linux, dnf command/yum command on RHEL & co, apt command/apt-get command on Debian, Ubuntu & co, zypper command on SUSE/OpenSUSE, pacman command on Arch Linux to install the dmidecode.

Identifying Linux Server ECC Memory Modules Command

Open the terminal application. For remote server log into the Linux server using the ssh command as follows:
$ ssh user@serverA
$ ssh

Use the sudo command or su command to login as the root user. For instance:
$ sudo -i
$ su -
Next, type the following command on your Linux server:
# dmidecode --type 16
# dmidecode --type 16 | more

# dmidecode 2.11
SMBIOS 2.5 present.

Handle 0x0016, DMI type 16, 15 bytes
Physical Memory Array
	Location: System Board Or Motherboard
	Use: System Memory
	Error Correction Type: Single-bit ECC
	Maximum Capacity: 64 GB
	Error Information Handle: Not Provided
	Number Of Devices: 8

One can run the combination of the dmesg command and grep command as follows too:
$ sudo dmesg | grep -i EDAC

Getting all other memory ram details on your Linux server

To see memory speed and other information, enter:
# dmidecode --type memory
# dmidecode --type memory | less

Using ras-mc-ctl command on Linux to check ECC ram status and summary

As a Linux sysadmin, you may find rasdaemon useful. It’s a logging tool that helps ensure Reliability, Availability, and Serviceability (RAS). Specifically, it tracks memory errors using EDAC tracing events. EDAC drivers are part of the Linux kernel and detect ECC errors from memory controllers on x86 and ARM chipsets. The userspace component includes an init script (both SysV and Systemd) that loads EDAC drivers and DIMM labels during system startup and a utility for reporting current error counts from the EDAC sysfs files.

Installing rasdaemon

Debian or Ubuntu Linux user try the apt command or apt-get command as follows:
$ sudo apt install rasdaemon
Ensure that service is started if not already started by the APT using the systemctl command $ systemctl status rasdaemon.service
$ sudo systemctl start rasdaemon.service

Here is how to install rasdaemon on RHEL, Fedora, Rocky and Alma Linux using the dnf command. For example:
$ sudo dnf install rasdaemon
$ sudo rasdaemon --enable
$ sudo systemctl enable rasdaemon

Examples and usage

Next, register labels for platform:
$ sudo ras-mc-ctl --register-labels
First, print status of EDAC drivers:
# ras-mc-ctl --status

ras-mc-ctl: drivers are loaded.

Show the memory layout, type:
# ras-mc-ctl --layout
Finally, get a summary of the logged errors:
# ras-mc-ctl --summary
Type the help command to get help about all CLI option:
$ ras-mc-ctl --help

Usage: ras-mc-ctl [OPTIONS...]
 --quiet            Quiet operation.
 --mainboard        Print mainboard vendor and model for this hardware.
 --status           Print status of EDAC drivers.
 --print-labels     Print Motherboard DIMM labels to stdout.
 --guess-labels     Print DMI labels, when bank locator is available.
 --register-labels  Load Motherboard DIMM labels into EDAC driver.
 --delay=N          Delay N seconds before writing DIMM labels.
 --labeldb=DB       Load label database from file DB.
 --layout           Display the memory layout.
 --summary          Presents a summary of the logged errors.
 --errors           Shows the errors stored at the error database.
 --error-count      Shows the corrected and uncorrected error counts using sysfs.
 --help             This help message.

See rasdemon source code and help pages on Github.

Summing up

How To Identify Server ECC Memory Modules on Linux
That is all. This quick tip helps Linux sysadmins, hardware engineers, and developers to identify ECC ram. This type of memory monitors data for errors, which helps protect your system from potential threats. ECC memory works by adding a ninth computer chip to the Linux server RAM, exclusively responsible for checking for errors and correcting them. Hence, most servers come with ECC ram instead of standard RAM. Read the following manual page using the man command or help command:
$ man dmidecode
$ dmidecode --help | grep -- 'option'

Usage: dmidecode [OPTIONS]
Options are:
 -d, --dev-mem FILE     Read memory from device FILE (default: /dev/mem)
 -h, --help             Display this help text and exit
 -q, --quiet            Less verbose output
 -s, --string KEYWORD   Only display the value of the given DMI string
 -t, --type TYPE        Only display the entries of given type
 -H, --handle HANDLE    Only display the entry of given handle
 -u, --dump             Do not decode the entries
     --dump-bin FILE    Dump the DMI data to a binary file
     --from-dump FILE   Read the DMI data from a binary file
     --no-sysfs         Do not attempt to read DMI data from sysfs files
     --oem-string N     Only display the value of the given OEM string
 -V, --version          Display the version and exit

See also

What to do when dmesg and system log indicate problems with ECC RAM errors?

If you notice ECC errors appearing frequently in your Linux system log, it indicates that one or more of your DIMMs are failing. To prevent further damage to your data, it is crucial to replace the RAM as soon as possible, as this hardware failure is currently in progress.

🥺 Was this helpful? Please add a comment to show your appreciation or feedback.

nixCrat Tux Pixel Penguin
Hi! 🤠
I'm Vivek Gite, and I write about Linux, macOS, Unix, IT, programming, infosec, and open source. Subscribe to my RSS feed or email newsletter for updates.

4 comments… add one
  • Thomas Mar 28, 2008 @ 8:50

    You can run the command dmidecode (e.g. to be found in package kernel-utils on RedHat based distibutions), and it will give you a bunch of BIOS related information including your installed memory.

  • bahur Jun 1, 2012 @ 4:24

    Have you ever tried it? :D

    Handle 0x0013, DMI type 17, 27 bytes
    Memory Device
    Array Handle: 0x0012
    Error Information Handle: No Error
    Total Width: 40968 bits
    Data Width: 41024 bits
    Size: 1024 MB
    Form Factor: DIMM
    Set: 1
    Locator: J6G1
    Bank Locator: DIMM 0
    Type: DDR2
    Type Detail: Synchronous
    Speed: 800 MHz
    Manufacturer: Kingston
    Serial Number: 690CFA80
    Asset Tag: 0000072D
    Part Number: 4B544331472D5544494D4D00000000000000

    Could you please show me which is the chip-count here? :)

  • Thorsten Brüning Feb 4, 2015 @ 20:07

    For me it works nice:

    # dmidecode 2.12
    SMBIOS 2.5 present.

    Handle 0x0026, DMI type 16, 15 bytes
    Physical Memory Array
    Location: System Board Or Motherboard
    Use: System Memory
    Error Correction Type: Single-bit ECC
    Maximum Capacity: 16 GB
    Error Information Handle: Not Provided
    Number Of Devices: 2

  • Luigi May 26, 2023 @ 9:26

    Great, thanks!

Leave a Reply

Your email address will not be published. Required fields are marked *

Use HTML <pre>...</pre> for code samples. Your comment will appear only after approval by the site admin.