Australian cloud for business software — built and run in Sydney since 2002

NetLeverage
NetLeverage

Synology "The system found excessive and uncorrectable metadata errors": why it cannot be repaired and how to rebuild the volume

Technical article
Troubleshooting

About this article: This article is reviewed against the cited sources. This is source research, not lab validation. Check the stated versions and your own requirements before making changes.

A Synology NAS that reports "The system found excessive and uncorrectable metadata errors" on a Btrfs volume is telling you that the metadata on the volume, the information "such as file names, sizes, and locations", has errors Synology says cannot be corrected. Synology's page for this message is blunt about the outcome: the volume has to be removed and created again, and the data restored from somewhere else.

The sections below explain what the message means, which hardware faults Synology links it to, how to check them without changing anything, and the order in which to move data off, remove the volume and rebuild. Nothing before the Fix section changes anything.

What the error means

Synology's page gives the symptom as "The system found excessive and uncorrectable metadata errors on your Btrfs volume." It defines metadata this way: "Metadata stores information such as file names, sizes, and locations, which the file system uses to manage and locate files."

Btrfs, the file system on the volume, uses checksums on both data and metadata. Synology says Btrfs "can automatically detect silent data corruption and recover corrupted data through its file self-healing mechanism." The message says the errors on the volume are excessive and uncorrectable.

Synology states the consequence plainly: "You cannot fix metadata errors that resulted from the mentioned hardware issues, even if you replace the defective hardware or run commands." The only route on its page is to remove the volume, check and fix the hardware issues, and take steps to stop the errors coming back.

The page also lists what can happen if the corruption stays: the file system may be unable to do these things:

  • Run read-write functions properly.
  • Open packages properly.
  • Repair or expand a volume.
  • Change the RAID type of a storage pool.
  • Synchronise or back up data.

This message is different from a volume that has crashed or gone read-only. That state has its own guide: Synology volume crashed or read-only: what to do first.

Likely causes

Synology's page, which covers DSM 7.1 and above and DSM Enterprise (PAS), says the resulting data and metadata errors are likely to be uncorrectable when corruption arises from these hardware issues:

Cause Synology's pointer for checking it
Drive read/write errors (silent data corruption) A page on telling whether the NAS or the drive is at fault when drive errors occur
Memory failure or incompatible memory modules A page on running a memory test
Improper system shutdown A page on "Improper shutdown" notifications

Two more facts from Synology's pages shape the picture:

  • File self-healing, which can repair some corruption, is "only available for Btrfs volumes configured in the following RAID types: RAID 1, RAID 5, RAID 6, RAID 10, RAID F1, RAID TP, and Synology Hybrid RAID." A volume without one of these has no self-healing to fall back on.
  • Synology's page on preventing volume crashes lists three causes of file system errors: improper system shutdown, installation of non-Synology memory modules, and drive errors.

Prove the cause before changing anything

All of these steps only read. Close each screen without saving.

  1. Confirm the message and the volume. Find which volume the notice names. Do not assume it is the one holding the most data.

  2. Check the DSM version. Synology's page applies to DSM 7.1 and above and DSM Enterprise (PAS). Another version is outside what the page covers.

  3. Check the RAID type of the storage pool behind the volume in Storage Manager. If it is not in the list above, file self-healing does not apply.

  4. Check whether the affected shared folders have data checksums on. Synology's self-healing page says to go to Control Panel > Shared Folder, select a shared folder and click Edit > Advanced to see whether "Enable data checksum for advanced data integrity" has been ticked. It adds that this option can no longer be altered after the shared folder has been created, and that files stored on iSCSI LUNs created on a Btrfs volume are not protected by self-healing.

  5. Read the drive logs. Synology's drive-errors page says to go to Log Center > Logs and select Drives for the log type on DSM 7.2 or above (on DSM 7.1 or below, Storage Manager > HDD/SSD > Logs). Frequent "I/O errors, drive plugged in, or drive plugged out" logs without anyone touching the drives point at the drive or its slot.

  6. Look for "Improper shutdown" notifications. Synology's page lists power outages, improper power cord connection, a failing power supply and abnormal or non-original memory modules as the causes of those notices.

  7. Check the memory. Note whether any non-Synology memory modules are installed. Synology's page on preventing volume crashes says a non-Synology memory module could result in file system errors and lead to a volume crash.

Fix

Synology's page lists these actions: back up the data and package settings, remove the volume, create a new volume, restore, and rule out the hardware. The order below follows it: copy the data, back up the package settings, remove the volume, create the new volume, restore, then rule out the hardware. Each changing step has its own record, warning and undo.

Step 1: copy the data to another volume or device

Write down the time, the name of the affected volume, the names of its shared folders, the packages installed on it, the destination volume with its free space, and whether the shared folder you will create on the destination already exists.

Risk: the next steps read every file you copy from a volume that has uncorrectable metadata errors, and write the copies to another volume or device. The copy can fail or stop part-way if the damage blocks reads, and the destination needs enough free space for what you copy. Copying leaves the original in place.

Synology's page says to move the data to another storage device or volume. Its page on moving data lists File Station: create a shared folder on the destination volume (Control Panel > Shared Folder > Create > Create Shared Folder), open File Station, select the files or folders, right-click and select Copy to / Move to, choose Copy to, pick the folder you created and click OK. Choose Copy to rather than Move to, so the original stays where it was.

Risk: deleting the copies cannot be undone. Delete only the shared folder you created for this copy and nothing else on the destination.

To undo it: delete the shared folder you created on the destination for the copy, and nothing else. The volume you copied from is unchanged.

Step 2: back up the package settings with Hyper Backup

Write down the time and the packages installed on the volume.

Risk: the next step creates a Hyper Backup task and writes backup data to its destination. This cannot be undone here.

Back up package settings with Hyper Backup. Multi-version backups use .hbk format; use Hyper Backup, Hyper Backup Explorer or Hyper Backup Vault to access them.

To undo it: this step cannot be undone.

Step 3: remove the volume

Write down the volume's name, the storage pool it sits in, its RAID type and the shared folder and package list from the previous steps.

Risk: the next step removes the volume where the metadata errors occur. Treat everything on it as gone: Synology's page has you back up and restore around this step. A removal cannot be undone; the only way back is the backup you made. Synology adds that "Removing a volume only stops relevant services temporarily; it will not uninstall or erase the operating system. System-related data are not stored in volumes but in the system partition of installed drives."

Go to Storage Manager > Storage. For DSM, click the upper-right icon of the volume you want to remove. For DSM Enterprise (PAS), select the volume and click Action. Select Remove from the drop-down menu.

To undo it: removal cannot be reversed. Create a new volume (Step 4) and restore the data and package settings (Step 5) from the copies.

Step 4: create the new volume

Write down the time, the name and storage pool you want for the new volume, the free space in that pool, and the list of volumes that exist before you create it.

Risk: the next step creates a new volume and uses space in the storage pool.

Synology's page says to create a new volume on DSM or DSM Enterprise (PAS) and refers to its volume creation help article for the screens. Create the new volume in Storage Manager by following that help article for your DSM version.

Risk: removing the new volume cannot be undone. Do it only while the new volume holds nothing, and only for the volume you created in this step, not one from your saved list.

To undo it: remove the new volume with the same Storage Manager route used in Step 3. Nothing has been restored to it yet, so nothing is lost.

Step 5: restore the package settings and data

Write down the time and the names of the shared folders and packages you expect to see after the restore.

Risk: the next step writes data onto the new volume. Synology warns: "The files on your Synology NAS will be overwritten by the restored version if the two file paths conflict." An overwrite cannot be undone.

For Hyper Backup, Synology's restore page says to go to Hyper Backup, select Data in the left panel, select the backup task to restore, then the version of system configurations, the folders and version, and the packages to restore. Confirm the restoration summary and click Apply. The password or encryption key is required if the task is encrypted. Keep any separately copied files available until you have confirmed the restore.

To undo it: restoring cannot be reversed for files that were overwritten. Synology's overwrite warning applies when paths conflict, and a new volume that holds nothing has no conflicting paths.

Step 6: run a memory test to rule out the hardware

Synology's page says to rule out the possibility of hardware issues, memory failure or incompatible memory modules among them. Synology's memory test page recommends running the test three times. Write down the time, whether the Memory Test checkbox in Synology Assistant is already ticked, and tell people who use the NAS that it will be unavailable.

Disruptive step: the next step reboots the NAS and makes it unavailable while the test runs. Synology says to reserve 1 to 1.5 hours for models with 16 GB or less memory and 1.5 to 3 hours for models with 32 GB or more. At least one built-in LAN port must be connected to the network, and Synology Assistant must stay open.

Download and install Synology Assistant from the Download Center, launch it, click the upper-right icon and tick the Memory Test checkbox and click OK. Select the NAS, make sure its status is Ready, click the Memory Test button and follow the wizard. The status shows "Performing memory test (x%)" during the test. A pass returns the status to Ready. A failure shows "One or more errors have been found by the memory diagnostic test" on the screen, and Synology notes that the status will still show Ready even then.

To undo it: wait for the test to finish. If the Memory Test checkbox was not ticked before, untick it again in the same Synology Assistant settings.

Confirm the fix

  • Storage Manager lists the new volume without a warning, and the metadata errors notice does not return.
  • The shared folders and packages are back and open.
  • Log Center > Logs shows no repeated drive I/O errors or drive plugged in or out entries.
  • The memory test ended with the status Ready and without "One or more errors have been found by the memory diagnostic test".

What to watch afterwards

Synology's page on preventing volume crashes lists these measures:

  • Use drives from the Synology Products Compatibility List.
  • Run data scrubbing periodically; Synology recommends it twice a year, and its file system error page gives running it once every three months, off-peak, as an example.
  • Set up hot spare drives, so a storage pool can repair itself sooner.
  • Do not install non-Synology memory modules.
  • Enable UPS support, so the NAS keeps running briefly through a power failure.

Watch for new "Improper shutdown" notices and for checksum mismatch notices on the new volume. Synology's self-healing page says the data checksum option can be enabled when a shared folder is created and can no longer be altered afterwards.

Risks and limits

Synology says the severity of metadata corruption varies from case to case. The page's fix for this message is to remove the volume, so the data copy and the backups are the only protection for what is on it; if they cannot be completed, the data on the volume may not be recoverable by these steps. Synology's page applies to DSM 7.1 and above and DSM Enterprise (PAS). A volume on a NAS that does not support Btrfs, or a different message such as a crashed volume, needs a different page.

Sources