IoT Platform provides the over-the-air (OTA) update and management feature. To update devices, make sure that your devices support the OTA service. Then, you can upload an update package to the IoT Platform console and specify devices to be updated. IoT Platform pushes OTA update notifications to the devices. The devices can download the OTA update package and perform OTA updates. This article describes the limits and procedure of OTA updates.
- Each Alibaba Cloud account can have a maximum of 500 update packages.
- The maximum size of an update package file is 2,000 MB. The file format can be only
- Take note of the following limits of update batches:
Update batches: IoT Platform shows created update tasks as different update batches. You can go to the Update Package Details page and view the update batch of the update package on the Batch Management tab.
- You can use an update package to create one or more update batches for different firmware versions to be updated.
- You can use an update package to create only one dynamic update batch for a firmware version to be updated.
- Each device in a dynamic update batch can be updated up to 10 times.
- You can use multiple update packages to create multiple update batches for the same firmware version. In this case, only the latest dynamic update batch takes effect.
- Each module of a device can have only one ongoing update batch at the same time. A device that has an ongoing update batch is in the To Be Pushed, Pushed, or In Upgrade state.
- Only devices that are connected to IoT Platform by using the Message Queuing Telemetry Transport (MQTT) protocol support the OTA update feature.
- If devices are online, these devices can immediately receive update notifications. If devices are offline, IoT Platform pushes update notifications when the devices go online.
- After a device is distributed to the destination instance, you can perform OTA updates on the device.
- Add an update package: Add an OTA module and update package to a product.
- Verify an update package (Optional): Verify the package.
- If you set the Verify Update Package parameter to No when you add the update package, skip this step.
- After tested devices are updated and the status of the update package is displayed as Verified, you can perform a batch update.
- Initiate a batch update task: IoT Platform sends the information about the update package to specified devices. The information includes the URL, version, and size of the update package. The devices must use the URL to download the update package for OTA updates.
Note The URL of an update package is valid for 24 hours. A device can download the update package within the specified period. If the update package is not downloaded within 24 hours, a device can obtain the update package information from IoT Platform and then download the package. For more information, see the following scenarios.
- A device immediately downloads the update package and complete an OTA update. For more information, see Step 5 that is described in the Message formats section of the Perform OTA updates topic.
- A device does not immediately download the update package. Instead, the device obtains the update package information from IoT Platform during off-peak business hours and then performs an OTA update. For more information, see Step 4 that is described in the Message formats section of the Perform OTA updates topic.
- View update status: View the update status of the devices and the information about the update package.
- View statistics on update package versions and success rates: View the statistics on version distribution and success rate distribution after the update. You can also identify the causes of update failures to improve the success rate.