How to easily migrate a Synology EXT4 volume to Btrfs without data loss

Today I switched from a Synology DS215play to a DS918+. Perfect time to change the file system - the DS215play didn't support Btrfs. The migration also works with only one device. So I wrote down both ways.

Steps if you haven't changed your DiskStation

  • Backup your data! If you switch to a device with new drives like me, you still have a copy of your data, but if you migrate without new drives, you don't have a copy! In germany we say: No backup - no pity.
  • Shut down the DS, remove drive 2.
  • Format drive 2 with your computer.
  • Insert drive 2.
  • Turn the DS back on and DO NOT repair the fault volume.
  • Create a new volume (SHR and Btrfs) in the Storage Manager on drive 2.
  • For each shared folder, change the location to the new volume. You can only do this for one shared folder at a time and the move may need several hours depending on the size of your shared folders.
  • When you have moved all the shared folders, shut down your DS and remove drive 1.
  • Format drive 1 with your computer.
  • Turn on your DS and go to the Package Center. Repair all apps.
  • Expand your new volume to drive 1 and wait until RAID Resync is complete. You're done.

Steps if you are switching to a new DiskStation with new drives (my situation)

  • Turn off your old DS, remove drive 2.
  • In the new DS, place the new drives in slot 1 and 2. Place the (old) drive 2 in slot 3.
  • Turn on the new DS. Open your browser and navigate to the new DiskStation. In my case, the DS got a new IP address. I looked them up in my router DHCP table.
  • Follow the Migration Wizard and wait until the DS restarts.
  • Create a new volume (SHA and Btrfs) in the Storage Manager on drive 1 and 2. It is now recommended to change the RAID Resync speed to Fast and wait until RAID synchronization is complete.
  • Now for each shared folder, change the location to the new volume. You can only do this for one shared folder at a time and may need several hours depending on the size of your shared folders.
  • When you have moved all shared folders, shut down your DS and remove drive 3.
  • Turn on your DS and go to the Package Center. Repair all apps. You're Done.

8 thoughts on “How to easily migrate a Synology EXT4 volume to Btrfs without data loss”

  1. Great guide, thanks.

    One thing I noticed is you don’t mention to re-insert drive 2 between steps 2 and 3 in “Steps if you haven’t changed your DiskStation.” Seems obvious, of course, but helpful if it’s explictly stated.

    Thanks for providing this.

  2. TLDR: Useful guide if you have nothing of importance on your NAS, but no substitute for restoring the volume from backup to a clean install.

    I discovered, to my cost, that most package settings are lost using this method. If you use Synology Drive, for example – all shares configuration and files history will be lost.

    “Repair all apps” worked for about 3 out of 10 installed apps too; the rest had to either be restored from backup, or removed and installed as new (again, without any settings being preserved). Although as you say, “no backup, no pity” so attempting this without a full backup is at your own risk…

    I therefore can’t recommend this method unless losing a load of configuration and data is acceptable to you. An interesting project, but next time I’d go for clean install using BTRFS then restore from full backup instead.

    1. Thank u for the feedback. I don’t remember that i had any problems with lost package/app settings. Maybe something has changed with newer DSM versions since i done this in October 2019.

  3. Thanks fot the guide. Actually I was able to migrate without removing and formatting the drive on the PC.
    Remove one disk and reboot the NAS => storage pool is degraded. Power off, plug back the drive and Deactivat the crashed disk. It will be removed from the storage pool. I didn’t try but I think you don’t need a reboot, just go and Deactivate the Drive.
    Re-add the disk, it will appear as Not initialized and create the new Storage pool with the btrfs volume.
    Migrate the shared folders and remove the Storage pool 1 so the first disk will become available for the new pool with the btrfs volume on it. Add and sync.

    I might have missed some details but it should be doable like that too.
    –Adrian

  4. very helpful! I just purchased a new diskstation and wondering hot to do the migrate and upgrade from ext4 to btrfs altogether, thanks a lot!

    K

  5. Thanks for this guide! Helped me get up to speed.

    Meantime, do you mean “(SHR and Btrfs)”, not “(SHA and Btrfs)”? There’s no SHA setting, but there is SHR (Synology Hybrid Raid).

    Also, it seems just “moving” the shared folders from ext4 to btrfs doesn’t enable the advanced Btrfs options such as checksums, compression, etc. Have to create new shared-folder on Btrfs, and then probably manually copy/move data back into it.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.