Debugging in Torizon IDE v2 fails when connecting with ssh

I’m attempting to follow the basic tutorial for Torizon IDE v2 on an ARMv8 architecture. However, I’m encountering issues when trying to connect via SSH for debugging with GDB.
In the console, I get this error msg:
Starting: "ssh" -T -q -p 2230 -i /home/hetech/FFTtest/.conf/id_rsa -o StrictHostKeyChecking=no -o "UserKnownHostsFile /dev/null" torizon@192.168.1.10 "/usr/bin/gdb --interpreter=mi" "ssh" exited with code 255 (0xFF).

I recall that in IDE v1, it was necessary to add certain parameters to the .json file for debugging purposes. However, the article on IDE v2 doesn’t mention anything about this.

Greetings @CaioGM,

It’s not immediately obvious to me yet what the issue here could be. First off some initial questions:

  • What is your host machine where you are running VSCode? (Windows, Linux?)
  • What kind of template/project are you attempting to debug here?
  • Is the device IP correct? (192.168.1.10)

As for the error itself exit code 255 is a pretty generic error for SSH that generally means the connection couldn’t be made. Do you have any network firewalls or restrictions that could interfere with the SSH connection being made here?

As you can see from the SSH command we use a non-standard port (2230) for SSH. Some users have ports locked down on their network/infrastructure and this could cause issues as well.

I recall that in IDE v1, it was necessary to add certain parameters to the .json file for debugging purposes.

What parameters are you referring to here exactly?

Best Regards,
Jeremias

Hi @jeremias.tx,

What is your host machine where you are running VSCode?

Linux Ubuntu 22.04

What kind of template/project are you attempting to debug here?

Template for C projects

Is the device IP correct?

It is correct.

What parameters are you referring to here exactly?

   "containerEnv": {       
                      "DEBUGINFOD_URLS": "https://debuginfod.debian.net"   
},

Regarding the firewall, since I’m using Linux, I don’t believe it could be the issue. Nonetheless, I’ll investigate it further.

Regarding the firewall, since I’m using Linux, I don’t believe it could be the issue. Nonetheless, I’ll investigate it further.

Could also be restriction on the network you’re using or something similar.

You could also try manually running the ssh command that is failing as seen in your error logs. Could run ssh with more verbose logging and see if something is wrong. Just make sure the debug container is running on your target device before trying to run this ssh command, since the command is targeting specifically the debug container and not the host.

Also I assume this issue is reproducible for you? Even if you start from scratch and re-add your device to the IDE extension?

Best Regards,
Jeremias

Hi @CaioGM ,

Were you able to solve this issue?

Please let me know if you have any doubts.

Best regards,
Daniel Morais