Sunday, 5 January 2025

Building a home NAS on a Raspberry Pi: RAID versus Rsync



The Pi 5 consumes about 4W under normal conditions. With a spinning 2.5" SATA drive it consumes about 6 Watts.

You can connect USB drives, but OpenMedia will not allow a RAID across USB drives. This is because they can be troublesome as they power down under energy saving conditions. They can also be disconnected leading to data loss.

Another option is to use a Pi Compute Module with a Compute IO board and a SATA adapter. However currently you can only use the PCI-E SATA adapter with the Compute Module 4 and the IO board only supports USB 2.

The Compute 5 IO board supports USB 3 but doesn't provide the PCI-E interface for SATA.

Use RAID or not?

There are opinions that RAID 1 provides a false sense of security. 

Delete a file, and it is deleted on both drives.

You could use a single drive, and periodic Rsync to another connected drive.

It allows disks of different sizes.

You could use addititve Rsync, so that only new files are added. If you accidentally delete a file, it may still exist on the destination drive.

You could plug in different destination drives for taking them offsite.


Power consumption

This article says that an SSD will draw 0.2A to 0.3A. A good option is a lower power option is to have a primary SSD for always-on reads and a 3.5" powered & spinning SATA for backup.

Running 8W will cost approximately 6p a day, (at 30p/kWh), or £21 per year. Far cheaper than cloud solutions.


No comments:

Post a Comment