The hub protection service might be worth it. It sure would save a bunch of time.
If you don't want to do that, and do things manually, you basically do a backup on your old hub, and restore that backup to the new hub. Zigbee devices will need to be discovered, but should pop right back into place. Zwave can be fixed by doing the steps below. Hub protect would eliminate the Zwave migration process outlined below.