What is NAS (Network Attached Storage) and how do I recover it?

Learn what a NAS (network attached storage) is, how it stores data, the signs it is about to fail and how to recover NAS data safely.

Network attached storage (NAS) is a powerful network storage solution. It is designed to make collaboration and data sharing easier at home and in business, mainly through file-level storage, although many models also offer block and object storage over the network.

A NAS lets you centralize and manage data efficiently, giving client devices secure, remote access to it.

A NAS is made up of physical storage drives, a central processing unit (CPU), an operating system and a network interface. It uses communication protocols such as SMB/CIFS (Server Message Block/Common Internet File System), NFS (Network File System) and iSCSI (Internet Small Computer System Interface), as well as RESTful APIs (application programming interfaces) for object storage.

Although a NAS is a great way to improve data availability and performance, it can still fail.

In this article, you’ll learn more about network attached storage: how it works, its storage principles, its components and what they do, the signs that it is about to fail and how to recover your data if something goes wrong.

What is NAS (network attached storage)?

NAS (Network Attached Storage) is a dedicated data storage solution that allows multiple devices to access and share files over a local area network (LAN) or the internet.

It is an efficient way to centralize data storage and make it accessible to multiple devices, such as computers, laptops, smartphones, tablets and other devices connected to the same network.

A NAS device is usually a dedicated storage server with one or more hard drives or solid-state drives (SSDs), often configured in one or more RAID (redundant array of independent disks) arrays for better fault tolerance and performance.

What is the basic storage principle of NAS devices?

The basic storage principle of NAS devices is to provide a centralized, shared location for storing and managing data on a local network or over the internet.

This is done with a dedicated storage server, the NAS itself, which is connected to the network and offers storage that various client devices can access.

A NAS is built around one or more hard drives or SSDs, which store the data.

These drives are usually organized in one or more RAID arrays, which offer different levels of fault tolerance and performance.

RAID combines multiple drives to improve data availability and, in some cases, access speed. Bear in mind, though, that RAID is not a backup.

A NAS has its own operating system, usually based on Linux, which manages the storage and provides network services to client devices.

It can be configured to provide different levels of access to data, such as read-only, read/write or restricted access to specific folders, according to users’ needs and security policies.

Client devices, such as computers, laptops, smartphones and tablets, access the NAS over the network using standard protocols. These include NFS for Unix-like systems and SMB/CIFS for Windows.

These protocols let client devices browse the NAS’s shared folders, open files, edit data and save information to the NAS as if they were working on a local drive.

In addition, many modern NAS devices offer extra features such as automatic backup, data encryption, remote access over the internet, media streaming and cloud integration. This makes them versatile and efficient storage solutions for homes and businesses.

1. File storage

File storage on a NAS relies on a file system that organizes the data stored on the NAS’s hard drives or SSDs and controls access to it.

Here are the main aspects of how file storage works on a NAS device:

  • File system: in a nutshell, it structures the data stored on the drives, organizing it into a hierarchy of folders and files. Common file systems on NAS devices include ext4 and Btrfs (common on Linux-based systems) and NTFS (New Technology File System, used by Windows).
  • Storage space: when you add drives to a NAS, they are usually grouped into a storage pool or RAID array (a process that erases whatever was on them), and one or more volumes are then created and formatted with a file system. From then on, that space is available for storing files.
  • Shares: the NAS lets you create shares, which are folders that client devices can access over the network. Each share can have its own permissions, such as read-only, read/write or restricted access.
  • Access from client devices: computers, laptops or smartphones connect to the NAS over the network using file sharing protocols such as SMB/CIFS (used by Windows) or NFS (used by Unix-like systems). These protocols let client devices access the NAS shares as if they were folders on their own local drives.
  • File browsing and management: once connected to the NAS, a client device can browse the folders and files in the shares. Users can copy, move, edit or delete files directly on the NAS, just as they would on their own hard drive.
  • Redundancy and protection: most NAS devices let you set up RAID arrays in which the drives are organized to provide redundancy. With redundant levels such as RAID 1, 5 or 6, the data stays accessible even if a drive fails, because it is mirrored or spread across several drives with parity. RAID 0 offers no redundancy, and no RAID level replaces a backup.
  • Remote access and additional services: many modern NAS devices offer extra features such as remote access over the internet, cloud sync, automatic backup, media streaming and much more, making them advanced and versatile storage solutions.

2. Block storage

Block storage on a NAS works quite differently from the traditional file storage we have just looked at.

While file storage gives access to individual files and folders through file sharing protocols, block storage presents storage space on the NAS directly to client systems as block devices.

Here are the main points of how block storage works on a NAS:

  • Block devices: instead of exposing individual files, the NAS presents part of its storage as “block devices” (often called LUNs) to connected client systems, which usually see them as additional local hard drives.
  • Protocols: block storage generally uses protocols such as iSCSI to provide access to these block devices over the network. iSCSI lets you create targets on the NAS, which are essentially block devices shared over the network.
  • Formatting and mounting: when a client device connects to an iSCSI target on the NAS, it sees the target as an unformatted local hard drive. The client can then format it with whatever file system it wants and mount it in its operating system, and from then on use that space as if it were a local drive.
  • Flexibility: block storage gives client systems more flexibility and control, because they can use the space for any purpose, such as creating their own file systems or running applications that need low-level access to storage.
  • Management: NAS devices that provide block storage usually offer advanced management features, such as storage quotas, snapshots and access control for these block devices.

3. Object storage

Object storage on NAS devices is also different from traditional file and block storage.

In object storage, data is organized into individual “objects”, each containing the data itself, metadata (information about the object) and a unique identifier known as a “key”.

Here is a closer look at how object storage works on a NAS:

  • Object structure: unlike file storage, which organizes data into a hierarchy of folders and files, object storage treats each file or piece of data as a separate, independent object. Each object has a unique key that makes it easy to retrieve.
  • Data and metadata: each object contains its own data, which can be a file, part of a file or any other type of information. Each object also has metadata describing it, such as its size, creation date, content type and other relevant properties.
  • Distributed storage: object storage is usually implemented as a distributed system, in which objects are spread across several hard drives or SSDs in a cluster of servers. This approach provides scalability, performance and high data availability.
  • API access: object storage is usually accessed through RESTful APIs, which let applications and services store, retrieve, delete and search for objects in the storage system.
  • Scalability and redundancy: because objects are spread across multiple drives and servers, object storage is highly scalable, so capacity can easily grow with demand. Replicating objects on different servers also provides redundancy, making object storage resilient to hardware failures.
  • Use in modern applications: object storage is widely used in modern applications, especially in cloud services and scalable web applications. It has become the basis for many public cloud storage services, such as Amazon S3 and Google Cloud Storage.
  • Unstructured storage: object storage doesn’t need a hierarchical file system. This flexibility makes it suitable for a wide range of uses, especially when a traditional folder-and-file structure isn’t the best approach.

4. File storage vs. block storage vs. object storage

As we’ve seen, NAS can offer different types of storage, each with its own distinct characteristics:

File storage

  • Works as a centralized file server on the network
  • Data is organized in a hierarchy of folders and files
  • Client devices access files through file sharing protocols such as SMB/CIFS (Windows) or NFS (Unix-like systems)
  • Ideal for file sharing and collaboration in home and business environments
  • Offers granular access to individual files and share permissions.

Block storage

  • Presents storage space on hard drives or SSDs to client systems as block devices
  • Uses block storage protocols such as iSCSI to provide network access
  • Client devices format and mount the storage space as a local disk drive
  • Ideal for environments that need high performance, granular control and low-level access to storage, such as virtual servers and databases.

Object storage

  • Organizes data into individual objects, each with its own data, metadata and unique key
  • Uses a distributed system and is accessed via RESTful APIs
  • Scalable and resilient, with objects replicated across several servers.
  • Widely used in modern applications and cloud services for storing unstructured data, such as images, videos and documents.
  • Each type of NAS storage has specific advantages and is suitable for different scenarios.

In short, file storage is ideal for sharing and collaborating on files, block storage is better suited to performance and granular control, and object storage is scalable and highly flexible for storing large volumes of unstructured data.

The right type of storage depends on the specific needs of the environment and the requirements of the applications.

How does NAS storage work?

NAS storage relies on two groups of protocols: communication protocols and file sharing protocols.

Here’s how each of them works:

Communication protocols

NAS communication protocols are what allow client devices to connect to and access centralized storage. Here’s how they work:

SMB/CIFS (Server Message Block/Common Internet File System)

SMB is the protocol Windows uses to share files and printers over a network.

CIFS is an early dialect of SMB (SMB 1.0) and has since been superseded by SMB 2 and SMB 3, which are faster and more secure. The protocol works by exchanging messages between the client and the NAS for authentication, browsing and file operations.

It allows Windows devices, as well as macOS and Linux devices, to access and share files on a NAS.

NFS (Network File System)

NFS is a protocol used mainly by Unix-like and Linux systems to share files over a network.

It allows client devices to access files on a NAS as if they were part of the client’s local file system.

The NFS client requests files from the NAS using file handles, unique identifiers that typically include the file’s inode number in the file system.

iSCSI (Internet Small Computer System Interface)

iSCSI is a block storage protocol that allows storage devices to be accessed over IP networks.

It allows a client device (the iSCSI initiator) to access and use block devices provided by the NAS (the iSCSI target).

The iSCSI target is presented to the client as a block device and can be formatted and mounted as a local drive.

RESTful APIs (Representational State Transfer)

RESTful APIs are used to access object storage systems on a NAS.

They allow applications and services to interact with the objects stored on the NAS, with operations such as creating, retrieving, deleting and searching for objects.

RESTful APIs use HTTP methods, such as GET, PUT, POST and DELETE, to handle stored objects.

Each NAS communication protocol has its own purpose and specific usage scenarios.

Besides these, there are other protocols, such as FTP (File Transfer Protocol) and AFP (Apple Filing Protocol), which are used in specific environments or for particular data sharing and access needs on NAS devices.

Which protocol to use depends on the network environment, the client devices and the access requirements for the NAS storage.

File sharing protocols

The computers on a network may run different operating systems, such as Windows, Linux or Unix.

Each of them expects to access the files on the NAS in its own native way.

That is why the NAS makes its data available on the network through file sharing protocols that each operating system understands natively.

The main file sharing protocols are:

  1. Network file systems (NFS)
    1. NFS (Network File System): the protocol used by Linux and Unix systems.
    2. It works regardless of the hardware, operating system or network architecture.
  2. Server message blocks (SMB)
    1. SMB (Server Message Block): used by computers running Microsoft Windows.

What are the components of a NAS device?

The components of a NAS work together to provide shared, accessible storage for client devices on a local network or over the internet. Here is what they are and what they do.

Physical storage drives

The physical storage drives are the core component of the NAS. They can be hard drives, SSDs or a combination of both.

They store the data and files that client devices connected to the NAS access and share.

It is also worth mentioning RAM, which provides temporary space for the data and information the processor needs quickly while the NAS is running.

Central processing unit (CPU)

The central processing unit (CPU) is the brain of the NAS, responsible for managing storage and responding to requests from client devices.

Operating system

The firmware or operating system is the software that controls and manages all NAS operations.

It provides the interface for managing and configuring the NAS and for accessing its storage.

Network interface

The network interface connects the NAS to the local area network (LAN) or the internet. It usually consists of one or more Ethernet ports for a wired connection.

Are there signs that a NAS is about to fail?

Yes, there are some warning signs. One is a sudden increase in error messages.

Another is a drop in performance, along with more hard drive activity than usual for no apparent reason.

Constant noise and high hard drive temperatures can also indicate imminent failure.

More error messages are a sign of trouble

An increase in error messages on a NAS indicates that it is having hardware, file system or connectivity problems, which may mean it is about to fail.

A drop in performance is a bad sign

If the NAS becomes noticeably slower than usual, this may point to failing drives or other hardware problems, and a failure may be just around the corner.

More hard drive activity for no obvious reason

Unexplained spikes in activity and logs filling up with errors may indicate that the NAS is at risk of failing.

Louder noises and/or higher hard drive temperatures

If the NAS starts making strange noises, such as clicking, popping or buzzing, the hard drives may have mechanical problems.

If the NAS overheats frequently, this may also point to problems with its cooling system. Both are clear signs of imminent failure.

Warnings from the NAS monitoring system

If the NAS shows error messages or warnings in its management interface or operating system, it’s important to look into the cause.

These warnings, such as a degraded RAID array or S.M.A.R.T. alerts on a drive, often come before a failure.

If you notice any of these signs, back up your most important data immediately and contact a specialist company such as Bot for help.

It is also a good idea to carry out regular preventive maintenance, such as updating the firmware and checking the health of the hard drives, to keep the NAS running properly and your data safe.

How to recover data from a NAS

If the NAS still works and you have lost files through accidental deletion or another logical problem, you can try recovering them with data recovery software. If the NAS doesn’t boot, the RAID is degraded or a drive is making noises, skip this method and contact a specialist. Here’s how the software method works.

Select the NAS and start the recovery

Download and install the NAS recovery software of your choice on your PC (never on the NAS). When you open it, select the “NAS Recovery” option.

The software will list the NAS devices it finds on the network. Choose your NAS and click “Scan”.

Enable SSH on the NAS

In the NAS management interface, go to “Control Panel > Terminal & SNMP” (the path varies by manufacturer) and select “Enable SSH service”. Note the port used for remote access. Then go back to the recovery software and click “Next”. Remember to disable SSH again when you are done.

Connect to the NAS remotely

The software will detect the IP address and port automatically. All you need to do is enter your NAS username and password.

If the IP address or port is wrong, you can correct them manually. Then click “Connect now”.

Recover lost or deleted NAS data

The software will then connect to your NAS and start scanning it. Wait for the scan to finish.

When the scan is complete, you will see the deleted, lost and existing files on your NAS.

You can use the “Filter” feature or the “Search files or folders” option to find the files you lost.

Select the files you want to recover and click “Recover”.

Finally, choose where to save them. Always save the recovered files to another drive, never to the NAS itself, so you don’t overwrite data that hasn’t been recovered yet.

How to recover a NAS without taking risks

Recovering data from a NAS is a delicate process, especially when important data is at stake.

The safest way to recover a NAS is to turn to specialists such as Bot.

Our highly specialized team recovers data from NAS devices with state-of-the-art tools and, when drives need to be opened, in a Class 100 (ISO 5) cleanroom with a particle-controlled environment.

We handle a wide range of cases, such as:

  • Lost NAS configuration
  • Burnt-out or corrupted NAS controller
  • Firmware corruption in internal RAID components
  • Data that cannot be transferred over the network
  • Human error
  • Accidentally formatted volumes or deleted data.
  • File system corruption on NAS volumes.

If you would still rather try it yourself (which we don’t recommend), here are some tips to do it as safely as possible:

  • Back up important data: before starting any recovery procedure, copy the data you can still access on the NAS to another device. This protects your data in case something goes wrong during the recovery. Don’t start a RAID rebuild or initialize anything before your data is safe.
  • Identify the cause of the failure: try to work out what caused the NAS failure before doing anything. Check the error messages, indicator lights and any other information that can help you find the source of the problem.
  • Avoid untested solutions: don’t use untested or unrecommended methods to recover the NAS. Unreliable software or procedures can make things worse and increase the risk of data loss.
  • Seek professional help: if you have no experience in NAS recovery, it is best to call in professionals. Companies specializing in NAS recovery are the best way to recover your data safely and minimize the risk of loss. Whenever you have doubts or run into difficulties, enlist the help of qualified professionals.

How to recover data from a faulty NAS

To recover data from a faulty NAS, you should also turn to a specialist service such as Bot.

Our experts work to recover lost data from any system, using the best tools and techniques available.

This applies to all types of NAS and RAID levels, all RAID controllers, all configurations (whether with hard drives or SSDs) and all manufacturers.

Some guides suggest recovering data from a faulty NAS by removing its drives and using the Windows Command Prompt. Before trying it, you should know its limitations.

We don’t recommend this method. Removing the drives incorrectly can damage them or the RAID array, and NAS drives usually use RAID and Linux file systems (such as ext4 or Btrfs), which Windows can’t read; if Windows offers to initialize or format the drive, never accept, because that erases its contents. In addition, the command below only unhides files; it doesn’t recover deleted data.

If you still want to try, here’s how:

  1. Shut down the NAS properly and stop using it: this prevents new data from overwriting the data you want to recover.
  2. Remove the drive from the NAS: the recovery tools can’t run on a live NAS, so you need to take out the drive that held the lost data. To do this, open the NAS enclosure or drive bays with the device switched off. Label each drive with the number of the bay it came from and never change their order. If the NAS uses RAID across several drives, a single drive won’t contain usable files on its own; in that case, or if you find this step difficult, call in a specialist.
  3. Don’t put the NAS back online without the drive: running a RAID array with a missing drive leaves it degraded, and reinserting the drive later can trigger a rebuild that overwrites data.
    Connect the drive to your computer: connect the drive you removed to a fully working PC, which will be used only for the recovery. You can connect it with SATA cables or a USB adapter, depending on the type of drive. Once it is connected, you can run the command from the Command Prompt.
  4. Open the Command Prompt: with the NAS drive connected to your computer, press the Windows and R keys at the same time.
  5. Type “cmd” in the Run window to open the Command Prompt.
  6. Run the command: type the command below and press Enter, replacing “X” with the drive letter Windows assigned to the NAS drive. This only works if Windows can read the drive’s file system (for example, NTFS), and it will show files that were hidden, not files that were deleted.

attrib -h -r -s /s /d X:\*.*

If the files were only hidden, they will appear again. If they don’t, or if Windows can’t read the drive, stop there and contact a specialist before doing anything else to the drive.

Conclusion

Bot offers data recovery for NAS (network attached storage) systems from a wide range of manufacturers, operating systems and configurations.

Our specialist team has the expertise to diagnose NAS failures efficiently and recover the data.

This applies to all types of NAS and RAID levels, all RAID controllers, all configurations (whether with hard drives or SSDs) and all manufacturers.

From the oldest to the latest models on the market.

Our services cover NAS recovery in situations such as:

  • Lost NAS configuration
  • NAS controller failure or corruption
  • Firmware corruption in internal RAID components
  • Problems accessing the NAS over the network
  • Human errors
  • Accidentally formatted volumes or deleted data
  • File system corruption on NAS volumes, and much more.

With the most advanced tools and techniques in the world, our experts work to recover your lost data quickly and effectively, whatever system you use.

We also deliver your data securely, via secure transfer or on an encrypted external hard drive.

What’s more, all our labs operate under strict confidentiality and with fully restricted access.

Trust a company with a long track record and excellence in data recovery: start recovering your NAS with us now!

With RAID and NAS, a rebuild or an initialization without a diagnosis can reduce the chances of recovery. Before touching anything, see Bot’s RAID and NAS data recovery, which starts with a free diagnosis.

About the author
Paulo BragaEspecialista em recuperação de dados · Laboratório Bot · Desenvolvimento e inovação

Paulo Braga is a data recovery specialist. He works where most cases are decided: hard drive mechanics, SSD electronics and firmware, using tools such as the PC-3000. At Bot, he splits his time between the lab, building solutions and innovation. On the blog, he writes about what he sees on the bench. Outside work, he is drawn to the meaning of things and enjoys time with family, friends and a good beer.

All articles by Paulo Braga →

Need to recover your files?

The diagnosis identifies the fault and whether recovery is technically viable. You receive a quote before any work begins.

Start diagnosis
Share