Hi, I'm completely new to OMV and I'm trying to install it on a 16GB USB drive and use a hard drive as storage. I just want to stream my media from plex. Are the above configurations enough for me?
Beiträge von ImethG
-
-
Using a flash memory drive can be fine. Or it can be a serious problem. Which depends on you.
The reason is that flash memory has a limited life. It survives only a certain number of writes. This means that thumbdrives and SD cards can be expected to die quickly if you are writing to them a lot. SSDs have a similar problem, but they are designed to withstand many more writes. However it is possible to destroy a SSD as well by writing to it too much. But then you have to make an effort...
Many SBCs use SD cards to boot. For other systems, using a USB thumbdrive to boot frees up SATA ports for data. In a normal OMV install the boot and root filesystem only takes up a few GB, making the size of a SD card or a USB thumbdrive an ideal fit. Also OMV can be configured to write very little to the root filesystem, using the flash memory plugin.
All is fine. A thumb drive or a SD card used like this can be expected to survive for many years, if not decades.
BUT... Then someone decides to do something more with their OMV install. Use it not only as a simple NAS but also run some server applications on it. Perhaps with metadata databases and caches and other very frequently written data. Perhaps install plex or emby. Or run dockers. And this can break OMV...
Typically /var/lib is used by the new applications to store caches and databases. Dockers by default use /var/lib/docker for storage. This can be Bad™. Using the normal partitioning /var/lib is part of the root filesystem. And if this is on a SD card or on a thumbdrive, then that SD card or thumbdrive can be expected to die or show errors soon.
Another problem is that the application data will quickly fill the root filesystem. Causing a spectacular crash when it is full. In addition it will make backups of the OMV server configuration difficult. Typically the root filesystem is just a few GB and easy and fast to clone. But add application data and caches and the root filesystem can grow quickly to many hundreds of GB.
There are (at least) five ways to handle this.
1. Partition the filesystem so that /var/lib is on a drive that can handle a lot of writes.
2. Put the root filesystem on a drive that can handle a lot of writes. SSD or HDD.
3. Configure the software to store data in a folder located on a drive that can handle a lot of writes.
4. Buy super high quality flash memory. A SSD in a thumbdrive or SD card form factor.
5. Buy thumbdrives and SD cards in bulk and replace often.If you use docker then you can change the docker base path to a shared folder on a HDD or a SSD. That is #3 above. And it works great. The root filesystem will keep small and can be stored on a 16 GB SD card or thumbdrive without any problems. Easy to clone for backups. And using the flash memory plugin it can be expected to last for many years.
Another trick to further improve the life of a SD card or thumbdrive is to overprovision. Decent quality SD cards or USB thumbdrives use simple wear leveling. You can use a 32GB or 64GB card/drive and only partition 8GB. The extra "unused" storage will be used for wear leveling, spreading out the wear from writes to many more memory cells. This can be expected to significantly increase the life of the drive.