September 28, 2020 Releases, Announcement

Unraid OS 6.9.0-Beta29 is Now Available

6 9 1

Back in the Saddle

Sorry for the long delay in publishing this release. Aside from including some delicate coding, this release was delayed due to several team members, chiefly myself, having to deal with various non-work-related challenges which have greatly slowed the pace of development. That said, there is quite a bit in this release, LimeTech is growing, and we have many exciting features coming down the pipe - more on that in the weeks to come. Thanks to everyone for their help and patience during this time.
Tom Mortensen
Lime Technology CEO
IMPORTANT: This is Beta software. 
We recommend running on test servers only!

THE PRIMARY FOCUS of this release is to put tools in place to help users migrate data off SSD-based pools so that those devices may be re-partitioned if necessary, and then migrate the data back.

What are we talking about? For several years now, storage devices managed by Unraid OS are formatted with an "Unraid Standard Partition Layout". This layout has partition 1 starting at offset 32KiB from the start of the device, and extending to the end of the device. (For devices with 512-byte sectors, partition 1 starts in sector 64; for 4096-byte sector size devices, partition 1 starts in sector 8.) This layout achieves maximum storage efficiency and ensures partition 1 starts on a 4096-byte boundary.

Excessive SSD Writes

Through user reports and extensive testing, however, we have noted that many modern SSD devices, in particular Samsung EVO, do not perform most efficiently using this partition layout, and the devices seem to write far more than one would expect, and with SSD, one wants to minimize writes to SSD as much as possible.

The solution to the "excessive SSD write" issue is to position partition 1 at offset 1MiB from the start of the device instead of at 32KiB. Doing this will both increase performance and decrease writes with affected devices. Do you absolutely need to re-partition your SSD's? Probably not depending on what devices you have. Click on a device from Main, scroll down to Attributes, and take a look at Data units written. If this is increasing very rapidly then you probably would benefit from re-partitioning.

Note: if you have already (re)Formatted using previous 6.9-beta release, for SSD smaller than 2TiB the proper partition layout will appear like this on the Device Information page:

Partition format: MBR: 1MiB-aligned

For SSD larger than 2TiB:

Partition format: GPT: 1MiB-aligned

Here's what's in this release to help facilitate re-partitioning of SSD devices:

An Erase button now appears in the Device Information page.

The Erase button may be used to erase (delete) content from a volume. A volume is either the content of an Unraid array data disk or the content of a pool. In the case of an Unraid disk, only that device is erased; in the case of a multiple-device pool, ALL devices of the pool are erased.

The extent of Erase varies depending on whether the array is Stopped, or Started in Maintenance mode (if started in Normal mode, all volume Erase buttons are disabled).

  • Started/Maintenance mode: in this case, the LUKS header (if any) and any file system within partition 1 is erased. The MBR (master boot record) is not erased.
  • Stopped - in this case, Unraid array disk volumes and pool volumes are treated a little differently:
    1. Unraid array disk volumes - if Parity and/or Parity2 is valid, then operation proceeds exactly as above, that is, the content of only partition 1 is erased but the MBR (master boot record) is left as-is; If there is no valid parity, then the MBR is also erased.
    2. Pool volumes - partition 1 of all devices within the pool are erased, and then the MBR is also erased.

The purpose of erasing the MBR is to permit the re-partitioning of the device if required. Upon format, Unraid OS will position partition 1 at 32KiB for HDD devices and at 1MiB for SSD devices.

Note that erase does not overwrite the storage content of a device, it simply clears the LUKS header if present (which effectively makes the device unreadable), and file system and MBR signatures. A future Unraid OS release may include the option of overwriting the data.


Additional "Mover" Capabilities

Since SSD pools are commonly used to store vdisk images, shfs/mover is now aware of:

  • sparse files - when a sparse file is moved from one volume to another, it's sparseness is preserved
  • NoCOW attribute - when a file or directory in a btrfs volume has the NoCOW attribute set, the attribute is preserved when the file or directory is moved to another btrfs volume.

Note that btrfs subvolumes are not preserved. A future Unraid OS release may include the preservation of btrfs subvolumes.

Ok, how do I re-partition my SSD pools?

The idea is to use the Mover to copy all data from the pool to a target device in the Unraid array. Then erase all devices of the pool, and reformat. Finally, use the Mover to copy all the data back.

If you have absolutely critical data in the pool we strongly recommend making an independent backup first (you are already doing this right?).

This procedure presumes a multi-device btrfs pool containing one or more cache-only or cache-prefer shares.

1. With the array Started, stop any VM's and/or Docker applications that may be accessing the pool you wish to re-partition. Make sure no other external I/O is targeting this pool.

2. For each share on the pool, go to the Share Settings page and make some adjustments:

  • change from cache-only (or cache-prefer) to cache-yes
  • assign an array disk or disks via Include mask to receive the data. These disks should be formatted with btrfs and of course, have enough free space to receive the data.

3. Now go back to Main and click the Move button. This will move the data of each share to the target array disk(s).

4. Verify no data is left on the pool, Stop array, click on the pool, and then click the Erase button.

5. Start the array and the pool should appear Unformatted - go ahead and Format the pool (this is what will re-write the partition layout).

6. Go back to the Share Settings page; for each above share:

  • change from cache-yes to cache-prefer

7. On the Main page click the Move button. This will move the data of each share back to the pool.

8. Finally, go back to the Share Settings page; for each share:

  • change from cache-prefer back to cache-only if desired

What if I don't care about preserving data in the pool?

In this case, Stop the array, click on the pool, and then click Erase. Start the array and Format the pool - done.

Useful to know: when Linux creates a file system in an SSD device, it will first perform a "blkdiscard" on the entire partition. Similarly, "blkdisard" is initiated on partition 1 on a new device added to an existing btrfs pool.

What about Array Devices?

If you have SSD devices in the Unraid array, the only way to safely re-partition those devices is to either remove them from the array or remove parity devices from the array. This is because re-partitioning will invalidate parity. Note also the volume size will be slightly smaller.

Known Issues

With this release, we have moved to the latest Linux 5.8 stable kernel. However, we have discovered that a regression has been introduced in the mtp3sas driver used by many LSI chipsets, e.g., LSI 9201-16e. This typically looks like this on the System Devices page:

Serial Attached SCSI controller: Broadcom / LSI SAS2116 PCI-Express Fusion-MPT SAS-2 [Meteor] (rev 02)

The problem is that devices are no longer recognized. There are already bug reports pertaining to this issue:

We have reached out to the maintainer to see if a fix can be expedited, however, we feel that we can neither revert back to 5.7 kernel nor hold the release due to this issue. We are monitoring and will publish a release with a fix asap.

ANOTHER known issue: we have added additional btrfs balance options:

  • raid1c3
  • raid1c4
  • and modified the raid6 balance operation to set meta-data to raid1c3 (previously was raid1).

However, we have noticed that applying one of these balance filters to a completely empty volume leaves some data extents with the previous profile. The solution is to simply run the same balance again. We consider this to be a btrfs bug and if no solution is forthcoming we'll add the second balance to the code by default. For now, it's left as-is.

For the full release notes...

Please see the full forum post for additional details and info.