If you are replacing a device and would like the new device to have the same identity and history as the original device, Remote.It can support you by using a restore code when installing Remote.It on the replacement device. This is useful when you are replacing hardware or a bad SD card. The restore code can also be retrieved via the graphQL API as well.
NOTE: Do not delete the device in Remote.It even though it is offline.
Device Package (not CLI or Desktop)
The process is simple to get a restore code from the Remote.It. You should make sure that the new device has all of the software and configurations needed to support the registered services. For example, if you have a web server, you should have the web server software installed and have the service running on the configured port. Then follow these simple steps.
NOTE: The original device should be offline before you use the restore code and the original device should not go back online once the restore code is used.
- Navigate to the Device Page of the device you would like to restore
- Click on the 3 dots in the upper right corner of the page and select "Restore Device". This will copy the one-line installation code.
- Paste the code into the command line of the new device and run it.
- This will install Remote.It and restore all of the original services.
CLI or Desktop Devices
For CLI or Desktop Devices, you will need to create a file on the device with the registration code first and then install the CLI or Desktop App.
- Navigate to the Device Page of the device you would like to restore
- Click on the 3 dots in the upper right corner of the page and select "Restore Device". This will copy the one-line installation code.
- Paste the code into a blank file and then keep only the R3_REGISTRATION_CODE value without the quote marks.
Save this file to /etc/remoteit/registration (no extension)
For example the copied code:
R3_REGISTRATION_CODE="77A0B60E-XXXX-52BE-XXXX-C17F8D5BXXXX" sh -c "$(curl -L https://downloads.remote.it/remoteit/install_agent.sh)"
Would be 77A0B60E-XXXX-52BE-XXXX-C17F8D5BXXXX - Install the CLI (https://link.remote.it/docs/cli/installation) or Desktop Application (https://link.remote.it/download/desktop).