Mass NAS: Typical data organization and peculiarities of data recovery

The modern computer market provides an ample supply of NAS units, which, depending on the retailer, may slightly differ in firmware, settings, specifics of data layout and other features. Yet, on the whole, most of them have a similar principle of data organization: a NAS box typically consists of from one to several drives that may be combined into a certain type of RAID system. Consequently, the primary data recovery techniques applied to NAS devices are usually based on the principles of data recovery from RAID. This article gives helpful information about the structure of common NAS systems and data retrieval from them. Several NAS solutions, like Buffalo, TeraStation, Iomega and Synology are used as an example.


Data organization

NAS devices primarily serve as shared storages providing access to data over a local network. In general, most of them have common storage structure and data organization. The actual data layout, however, depends on the NAS vendor and embedded configuration.

Storage structure

The data on each drive belonging to NAS is typically arranged on the following disk partitions:

  • Firmware-reserved partition. This partition contains technical information used by the embedded NAS firmware. On 1 TB TeraStation, for example, this partition is 0.6 GB in size, identified as 'Linux native' and formatted with the SGI XFS file system. It is available on the 1st and the 2nd NAS drives
  • Swap partition. This partition contains swap for the NAS firmware.
  • Data partition. This partition stores user data. On 1 TB TeraStation, for example, it is a 232 GB partition identified as 'Linux native'. Its actual size depends on the NAS settings.
  • Padding partition. This partition is used to unify the size of the data partition regardless of the actual number of disks. Its size depends on the model of the drive. On 1 TB TeraStation it is identified as 'Linux native' but contains no file system.

Disk partitioning style is a standard DOS-style (MBR-based) and is readable by any software.

RAID configuration and data organization

Depending on the configuration, the RAID technology offers several possible methods of data organization on Data partitions:

  • RAID 5. The most widely-used configuration. In the RAID 5 mode user data is located across Data partitions of all the four disks. The usual type of parity distribution is backward-dynamic (left-symmetric). The stripe size depends on the settings (usually it is 64 KB). The order of drives in RAID is consequent: the 1st disk of NAS is the 1st disk of RAID, etc. The Data partition on TeraStation, for example, is formatted as SGI XFS while on Synology – as Ext3.
  • RAID 0. User data is usually arranged as a single full-capacity storage or a pair of RAID 0 stripe sets with two independent partitions (different 'share' virtual folders on NAS). Both contain the same file system type but different data.
  • RAID 10 or RAID 0+1. The mirror of two RAID 0 stripe sets or a stripe set of two mirrors. User data is arranged the same way as in RAID 0 but only one 'share' and both stripe sets contain the same information.
  • JBOD. Data partitions are concatenated to yield maximum storage capacity. User data is-*3 spanned across all the Data partitions.
  • Specific RAID-based technology. Some manufacturers present their own RAID implementations that use proprietary algorithms and often bear a resemblance to logical volume managers:
    • Drobo BeyondRAID employed by Drobo requires two or more drives, possibly of different The array is constructed from many RAID sets with a size of 64 KB each. The offset for the constituents, the level of RAID and the size of the stripe is established dynamically by the system. Moreover, all the storage space is divided into blocks of 4 KB to enable thin provisioning. The scheme of blocks allocation is reflected in a special map. Instead of the Data partition, a Drobo BeyondRAID partition holds the data on each Drobo drive. The most frequently applied file system is Ext4.
    • Synology Hybrid RAID (SHR) supported by Synology NAS is created on two or more drives that can have diverse An allocation unit is generated on each drive based on the size of the smallest drive and these units are then arranged into one of the conventional RAID types (levels 1, 5 or 6, depending on the number of drives and the selected level of redundancy). The remaining "tails" of the drives whose capacities exceed the size of the smallest one are then organized into another RAID set, which is then spanned with the first RAID using Linux LVM to build a single virtual storage. The Data partitions on Synology are usually formatted with the Ext4 file system.
    • RAID-Z can be found in custom NAS solutions running TrueNAS (FreeNAS). The system is set up on a storage pool with ZFS that includes at least three drives. The techniques used for data distribution are analogous to the standard RAID 5, yet, the stripe size gets chosen by the system based on the current needs and this information is written to the metadata.
  • Individual drives. In NAS drives that are not organized in RAID each data partition relies on an independent file system.
  • Encryption. Some NAS manufacturers, like Synology, QNAP, Buffalo, Western Digital and others, deliver integrated options for volume encryption so that data could be protected from unauthorized access with the help of a certain encryption technologies, mainly Linux LUKS.

Before starting data recovery from NAS, it is necessary to identify the actual configuration of the storage. For more information about RAID systems, please, refer to the article explaining the peculiarities of data organization on RAID. To learn more about particular NAS technologies, like Drobo BeyondRAID and Synology Hybrid RAID, please refer to the corresponding article.

When is recovery required?

Due to their evident advantages, NAS units have already become an essential part of everyday work for home users and SMBs. NAS vendors began to offer quite cost-efficient solutions which increased their availability on the market. Despite the enhanced reliability of these storages they are still exposed to failures resulting in storage inaccessibility or even data loss. The most common causes for data loss from them include:

  • Loss of a NAS link;
  • An offline array or 'four red lights';
  • Data corruption due to power outages;
  • Firmware crash or failed boot;
  • Disk(s) failure;
  • Controller failure;
  • Electrical or mechanical damage.

User errors causing data loss include:

  • Faulty firmware update resulting in the reset of embedded RAID settings;
  • Deletion of files;
  • Rebuilding embedded RAID configuration on live data resulting in disks re-formatting.

If you are absolutely certain that NAS drives didn't suffer any physical damage and remain intact, you may start data recovery from them by following the below given instructions. However, when the drives have any physical defects resulting from mechanic, thermal or electric damage, it's strongly recommended turning to a specialized data recovery center. 

For the purpose of self-made data recovery from NAS, SysDev Laboratories offers the UFS Explorer software: UFS Explorer RAID Recovery was designed specially for work with RAID sets of various configurations whereas UFS Explorer Professional Recovery deploys a professional approach to data recovery from a variety of complex storage systems. The programs support a wide range of RAID schemes, from standard types (RAID 0, RAID 1, RAID 1E, RAID 3, RAID 4, RAID 5, RAID 6) and nested levels (RAID 0+1, RAID 10, RAID 50, RAID 51, etc.) to specific RAID patterns (Drobo BeyondRAID, Synology Hybrid RAID, ZFS RAID-Z, Btrfs-RAID). Furthermore, the utilities handle a diversity of file systems utilized by modern NAS devices, including Ext2, Ext3, Ext4, XFS, UFS, ZFS, Btrfs, and different modern encryption technologies.

Hint: For detailed information concerning the supported technologies, please, refer to the technical specifications of the respective software product.

Getting started

As NAS devices don't provide low-level access to data, before you start data recovery, you have to disassemble the storage and connect its hard drives to a computer. To do this:

  • Remove the hard disk drives from the NAS box and mark their order;
  • Identify the interface type of the drives: modern NAS use SATA drives; very old storages may still use PATA/IDE drives;
  • Connect the drives to a personal computer.

Hint: Please refer to the article in order to choose an optimal OS for NAS recovery.

If the computer used for recovery doesn't provide sufficient number of disk adapter interfaces you can:

  • Install an additional PCI hard disk adapter;
  • Use USB hard disk adapters;
  • Attach the disks one by one and make full disk images. This solution is recommended provided that you have enough free disk space.

Warning: Turn off the computer and unplug the power cable before you install any PCI device or connect/disconnect SATA/PATA drives to avoid electric damage!

Hint: To learn how you can plug the drive into the motherboard of the computer or сonnect the drive externally using a USB to SATA/IDE adapter, please rely on the given video tutorials.

Having ensured access to the NAS data, you can start the data recovery process. Yet, make sure that you have prepared a storage with a capacity enough to place all the recovered files – any internal/external disk mounted in the OS or a network location.

Data recovery

The entire data recovery process with UFS Explorer RAID Recovery requires a few simple steps:

  1. Check the list of connected devices in the left pane of the software interface:

    • If the metadata of the embedded RAID configuration wasn’t seriously corrupted, you will be able to see the assembled array among the storage options. It can be recognized by a "complex storage" icon, RAID level or the number of the drives.

    • In case the RAID layout couldn’t be reconstructed, it is possible to assemble it manually from the member drives or their disk images:

      1. Press the "Build RAID" button and add each member of the array using the corresponding option in the storage context menu. Most NAS appliances require the largest Data partitions to be included rather than entire drives.

      2. If RAID operates in the degraded mode, insert a placeholder to indicate the missing component using the respective tool in the toolbar.

      3. Define the order of constituents using the arrow-like buttons and specify the accurate RAID configuration in the RAID parameters pane.

      4. Once you have finished, hit "Build this RAID".

  2. Select the volume mounted under your RAID in the list of connected storages and explore its content. If the files look damaged, this may indicate that RAID settings were defined incorrectly. In this case, right-click the RAID storage, choose "Edit RAID configuration" and try adjusting them. After that, press "Build this RAID" again.

    Note: If you don’t know which RAID configuration your NAS is based on, refer to the NAS documentation. You may make any number of reconstruction attempts, as the software operates in the read-only mode without modifying any information on the source disks.

  3. To recover deleted or lost files, scan this volume using the respective button or the storage context menu option.

  4. On completion of all the required operations you can browse your files and copy them to a safe location.

Final notes

In case of any physical damage it's strongly recommended to bring your NAS to a specialized data recovery laboratory in order to avoid data loss. Also, if you feel unsure about conducting data recovery operations from your NAS by yourself or not confident about RAID configuration in your NAS, you can contact SysDev Laboratories and request professional data recovery services

Last update: August 11, 2022

If you liked this article, you can share it on social media: