Azure / iotedgedev

The Azure IoT Edge Dev Tool greatly simplifies your Azure IoT Edge development process. It has everything you need to get started and helps with your day-to-day Edge development.
https://aka.ms/iotedgedev
Other
160 stars 71 forks source link

iotedgedev fails to obtain existing device connection string #491

Closed louisn closed 3 years ago

louisn commented 3 years ago

Steps to Reproduce:

  1. Run the Quickstart instructions
  2. Note the symptom on output
Retrieving 'iotedgedev-edgedevice' connection string...
ERROR: Could not locate the iotedgedev-edgedevice device in iotdevedge-hub IoT Hub in iotedgedev-rg.
  1. grep in /home/iotedgedev/.azure/commands/ log files for ERROR
CMD-LOG-LINE-BEGIN 445 | 2021-07-20 20:03:56,244 | INFO | az_command_data_logger | command args: iot hub device-identity {} --device-id {} --hub-name {} --resource-group {}
CMD-LOG-LINE-BEGIN 445 | 2021-07-20 20:03:56,471 | ERROR | az_command_data_logger | 'show-connection-string' is misspelled or not recognized by the system.
CMD-LOG-LINE-BEGIN 445 | 2021-07-20 20:03:56,498 | INFO | az_command_data_logger | exit code: 2

Correct syntax in iotedgedev/azurecli.py should be connection-string show as described in the az cli documentation.

konichi3 commented 3 years ago

Hi @louisn

Can you tell us which step in quick start that you encounter the error? Could you also try with the latest iotedgedev (ver 3.1.1)?

louisn commented 3 years ago

I'd like to try ver 3.1.1 however that version isn't found in MCR. Latest is 3.1.0.

marianan commented 3 years ago

We were able to get a repro of this issue, it happens during init. We will investigate and update the thread once we have more details. Do you have a work around to unblock your scenario?

cindydeng1998 commented 3 years ago

Hello @louisn! We have found the issue and published a new version of the container that should run iotedgedev 3.1.2. Please let us know if this solves your issue or if you have any questions. Thank you!