I'm Using a Virtual Machine.
Running in debug mode, providing the Device Connection String, I'm getting this error.
Error: Could not start container: {id} : 500 Server Error: Internal Server Error ("driver failed programming external connectivity on endpoint edgeHubDev ({id}): Bind for 0.0.0.0:8883 failed: port is already allocated")
After checking which proccess is using the port, the result is:
Image Name PID Session Name Session# Mem Usage
========================= ======== ================
vpnkit.exe 5436 RDP-Tcp#1 2 28,520 K
maybe it's something about the virtual machine.
How can fix this and be abble to debug ?
⚠Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
Thanks for the feedback! We are currently investigating and will update you shortly.
@shizn do we have a way to change the debugger port? Thanks.
Hey @nkolchakov. It seems your 8883 port has been occupied by other process in your VM. Could you check which process is using 8883, then kill that one and restart the IoT Edge solution? The 8883 port is reserved by EdgeHub if you are using MQTT and currently cannot be changed.
BTW, if you are using AMQP protocol. You don't necessarily need the 8883 port if you don't want to talk to leaf devices (I assume no because you are running everything in a VM). Another way to make the debug work is to remove the 8883 port from your EdgeHub createOption to avoid the conflict.
@nkolchakov we will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and we will reopen the issue.
Most helpful comment
BTW, if you are using AMQP protocol. You don't necessarily need the 8883 port if you don't want to talk to leaf devices (I assume no because you are running everything in a VM). Another way to make the debug work is to remove the 8883 port from your EdgeHub createOption to avoid the conflict.