Manual Migration Process for Azure Deployments

This guide is for storage administrators and support personnel that have to manually migrate SoftNAS to a new marketplace version without an in-place upgrade.

Step-by-step guide for manual migration of a single SoftNAS instance with block device pools.

  1. Deploy the new instance that you will be migrating to from the marketplace:
    1. Deploy in the same VNET as the current SoftNAS.
    2. Deploy in the same Availability Set (if using Availability Sets) as the current SoftNAS.
    3. Deploy in the same subnet as the current SoftNAS.
    4. Assign the same Network Security Groups as the current SoftNAS.
    5. Have the Application Registration Client ID, Access Key, and Tenant ID available, or create a new one with the role of 'contributor'.
    6. In the NIC IP Configuration, Enable IP Forwarding
  2. Copy over the following config files from the current instance to the new instance.
    1. '/etc/exports'

    2. '/etc/samba/smb.conf'

      1. Only copy the shares sections of smb.conf if they exist, do not copy the '[global]' section.
    3. '/etc/target/saveconfig.json'

    4. '/var/www/softnas/config/snapshots.ini'

    5. If you are using tiered pools, copy the below files over:
      1. '/var/www/softnas/config/btier.json'

      2. '/var/www/softnas/config/btier_migrations_saved_sdtiera'
    6. Copy over any custom monitors you may have in '/etc/monit.d/' if they exist.
    7. Copy over /var/www/softnas/config/monitoring.ini
    8. Check in /var/www/softnas/keys for one or more files named with a UUID-like string, such as 'dbc7ab4f-b742-4ed6-8777-a41d321c7ef2'. The presence of these files indicates that LUKS encryption was used for some pools on the server. These files are used to store the passphrases to unlock the encryption keys for such pools. Copy any such files to the same directory /var/www/softnas/keys on the new server.
  3. Power off both instances to migrate the disk devices.
    1. Power off the current instance.
    2. Power off the instance you are migrating to.
  4. Migrate the disk devices from the current instance where they are attached to the new instance.
    1. Log into the Azure Portal.
    2. Make note of the device order of the current attached disk devices on the current instance.
    3. Detach them all.
    4. Re-attach the devices in the same order to the new instance. With SoftNAS 5, managed disk devices are attached starting with LUN1, rather than LUN0.
  5. Power on the new instance.
    1. At boot time the ZFS pools should be imported and mounted with no user interaction.
  6. If using Active Directory, join the new instance to Active Directory at this time.
    1. First remove the old computer object of the previous SoftNAS from Active Directory.
      1. Active Directory > Users and Computers > Delete the old object
    2. Now follow the instructions in the AD Wizard.
      1. Active Directory Configuration


Step-by-step guide for manual migration of a HA Pair SoftNAS instances with block device pools.

  1. Deploy the new instances that you will be migrating to from the marketplace:
    1. Deploy in the same VNET as the current SoftNAS instances.
    2. Deploy in the same Availability Set (if using Availability Sets) as the current SoftNAS.
    3. Deploy in the same subnet as the current SoftNAS instances.
    4. Assign the same Network Security Groups as the current SoftNAS instances.
    5. Have the Application Registration Client ID, Access Key, and Tenant ID available, or create a new one with the role of 'contributor'.
    6. In the NIC IP Configuration, Enable IP Forwarding.
  2. Set up replication and HA on the new nodes while there are no devices attached.
    1. 'Add Replication' from the Snapreplication menu.
    2. 'Add HA' from the Snapreplication menu.
  3. Deactivate replication on the current HA pair you are migrating from.
    1. 'Actions > Deactivate' from the Snapreplication menu.
  4. Deactivate replication on the new HA pair that you are migrating to.
    1. 'Actions > Deactivate' from the Snapreplication menu.
  5. Copy over the following config files from the current instances to the new instances (each node).
    1. '/etc/exports'

    2. '/etc/samba/smb.conf'

      1. Only copy the shares sections of smb.conf if they exist, do not copy the '[global]' section.
    3. '/etc/target/saveconfig.json'

    4. '/var/www/softnas/config/snapshots.ini'

    5. If you are using tiered pools, copy the below files over:
      1. '/var/www/softnas/config/btier.json'

      2. '/var/www/softnas/config/btier_migrations_saved_sdtiera'
    6. Copy over any custom monitors you may have in '/etc/monit.d/' if they exist.
    7. Copy over /var/www/softnas/config/monitoring.ini
    8. Check in /var/www/softnas/keys for one or more files named with a UUID-like string, such as 'dbc7ab4f-b742-4ed6-8777-a41d321c7ef2'. The presence of these files indicates that LUKS encryption was used for some pools on the server. These files are used to store the passphrases to unlock the encryption keys for such pools. Copy any such files to the same directory /var/www/softnas/keys on the corresponding new server, primary or secondary.
  6. Copy over these config files from current primary instance to the new primary instance for replication to work.
    1. Any snapvol configs in '/var/www/softnas/config/'.
      1. '/var/www/softnas/config/snapvol-*.ini'
    2. Copy over only the Relationship1-Tasks from '/var/www/softnas/config/snaprepstatus.ini'
      1. open '/var/www/softnas/config/snaprepstatus.ini' on the current instance in a text editor.
      2. Copy the section labeled '[Relationship1-Tasks]' at the bottom of the file into /var/www/softnas/config/snaprepstatus.ini' on the new primary instance.
      3. Each item mentioned in '[Relationship1-Tasks]' will have a corresponding 'snapvol-*.ini' file associated with it.
  7. Power off all instances to migrate the disk devices.
    1. Power off the current instances.
    2. Power off the instances you are migrating to.
  8. Migrate the disk devices from the current instances where they are attached to the new instances.
    1. Log into the Azure Portal.
    2. Make note of the device order of the current attached disk devices on the current instances.
    3. Detach them all.
    4. Re-attach the devices in the same order to the corresponding new instances. With SoftNAS 5, managed disk devices are attached starting with LUN1, rather than LUN0.
  9. Power on the new instances.
    1. At boot time the ZFS pools should be imported and mounted with no user interaction.
  10. If using Active Directory, join the new instance to Active Directory at this time.
    1. First remove the old computer object of the previous SoftNAS from Active Directory.
      1. Active Directory > Users and Computers > Delete the old object
    2. Now follow the instructions in the AD Wizard.
      1. Active Directory Configuration
  11. Reactivate replication and HA on the new instances
    1. Go to the Snapreplication menu on the new primary instance.
    2. You should see that the UI looks like its in a 'Snapreplicate Complete' state and is populated as it was on the old instances.
      1. If not, you may have missed a step.
    3. From the 'Actions' menu, select 'Reactivate'
      1. You should see a delta-sync operation then normal replication should pick up where it left off.