Closed mitkodev closed 5 years ago
Same issue on ubuntu 18.04 and 16.04
Azure IoT Edge is now GA So, what you are running into - is the EdgeHub is from the GA bits (version 1.0), while the EdgeAgent is still using the preview bits (1.0-preview) - which is not a compatible deployment option. So what I suggest you do, is go through these steps to deploy the 1.0 bits of the Edge runtime - https://docs.microsoft.com/en-us/azure/iot-edge/quickstart-linux
If you wish to continue to run the preview bits for the time being, you can do so by manually changing the EdgeHub version when deploying to microsoft/azureiotedge-hub:1.0-preview. Then that will work with the preview version of the EdgeAgent.
In case you want to use the 1.0 bits with iotedgectl, then you will have to set a couple of environment variables that are not being set anymore. To do that, set the following in the EdgeHub CreateOptions during the deployment - {\"HostConfig\":{\"PortBindings\":{\"8883/tcp\":[{\"HostPort\":\"8883\"}],\"443/tcp\":[{\"HostPort\":\"443\"}],\"5671/tcp\":[{\"HostPort\":\"5671\"}]}},\"Env\":[\"SSL_CERTIFICATE_PATH=/mnt/edgehub\",\"SSL_CERTIFICATE_NAME=edge-hub-server.cert.pfx\"]}
This will set environment variables for the path that the EdgeHub should use. In case you have provided your own certificate (Gateway scenario), then use that certificate name instead.
We are fixing the Edge runtime so that this should not be needed, but that will not be available till the next release. So this is a workaround till then. Note: This workaround is not needed for 1.0-preview bits.
The workaround @varunpuranik mentioned above should no longer be needed because of commit Azure/iotedge@cc7e142. Closing.
I think there is a discrepancy between the edgeHub and edgeAgen at the moment. When I install the iotedgectl on a linux machine, the edgeAgent is still from a preview image, while when I check the create options in the Azure portal, the image for the edgeAgent is the official one ( no preview in the name). It seems that the edgeHub image and the edgeAgent image are from different repositories also:
The result is that, when the edgeHub tries to start, I'm getting this error:
I'm working on a Ubuntu 16.04, reinstalled the runtime and all dependencies and still get this issue. Tried the same thing on several devices.