QtCreator and Linux Device: SSH Connection Failure
-
wrote on 18 Jul 2018, 10:27 last edited by
Hi,
I'm trying to solve a problem when attempting to
test
the connection between my Debian host and a Linux-based device.When clicking the test button, the following error is reported by QtCreator and I can't figure out how to resolve it:
SSH connection failure: SSH Protocol error: Server sent unexpected SSH_MSG_USERAUTH_PK_OK packet.
The connection between QtCreator and the target is set to use a password (the device login is just
root
with no password) and this used to work on older versions of QtCreator.Any suggestions please?
I've attempted to use a
Key
for authentication but when I attempt to copy the key file across to the target via the terminal (usingssh-copy-id
), I get a warning saying that keys already exist on the target but this does not seem to be the case. -
Hi,
I'm trying to solve a problem when attempting to
test
the connection between my Debian host and a Linux-based device.When clicking the test button, the following error is reported by QtCreator and I can't figure out how to resolve it:
SSH connection failure: SSH Protocol error: Server sent unexpected SSH_MSG_USERAUTH_PK_OK packet.
The connection between QtCreator and the target is set to use a password (the device login is just
root
with no password) and this used to work on older versions of QtCreator.Any suggestions please?
I've attempted to use a
Key
for authentication but when I attempt to copy the key file across to the target via the terminal (usingssh-copy-id
), I get a warning saying that keys already exist on the target but this does not seem to be the case.@webzoid said in QtCreator and Linux Device: SSH Connection Failure:
I get a warning saying that keys already exist on the target
You can try to remove it like shown here https://askubuntu.com/questions/317619/how-to-undo-an-ssh-copy-id
-
@webzoid said in QtCreator and Linux Device: SSH Connection Failure:
I get a warning saying that keys already exist on the target
You can try to remove it like shown here https://askubuntu.com/questions/317619/how-to-undo-an-ssh-copy-id
wrote on 18 Jul 2018, 10:32 last edited by@jsulm Thanks for your quick reply.
Where would the key live? I've looked in
/home/user/.ssh/
but the directory doesn't exist.I've also tried clicking the "Deploy Public Key" button in the Devices window but the
server rejected key
message just appears. -
@jsulm Thanks for your quick reply.
Where would the key live? I've looked in
/home/user/.ssh/
but the directory doesn't exist.I've also tried clicking the "Deploy Public Key" button in the Devices window but the
server rejected key
message just appears.@webzoid It does not exist? Did you ever log-in via SSH as this user?
-
wrote on 18 Jul 2018, 10:34 last edited by webzoid
@jsulm
Yes, I can log in viassh
into the system via the USB RNDIS adapter (and also ethernet but the former is more accessible in this device) and it works fineUPDATE
If I wind QtCreator back to version 4.3.0 then everything works just fine - it would appear that this is a new feature in later versions?ANOTHER UPDATE
If I attempt tossh
into the target usingssh -l root 192.168.11.1
then as soon as the connection is made, it is closed again with the following:ERROR: Connection to 192.168.11.1 closed by the remote host.
Having done some more searching, there is mention of an
ssh-agent
however this does not exist on the target.@jsulm Is this required at all?
-
@jsulm
Yes, I can log in viassh
into the system via the USB RNDIS adapter (and also ethernet but the former is more accessible in this device) and it works fineUPDATE
If I wind QtCreator back to version 4.3.0 then everything works just fine - it would appear that this is a new feature in later versions?ANOTHER UPDATE
If I attempt tossh
into the target usingssh -l root 192.168.11.1
then as soon as the connection is made, it is closed again with the following:ERROR: Connection to 192.168.11.1 closed by the remote host.
Having done some more searching, there is mention of an
ssh-agent
however this does not exist on the target.@jsulm Is this required at all?
I had ssh connection problems with some version combinations of ssh client and server. especially root logins are default disabled in newer ssh servers and must be enabled first. password logins were disabled in some cases too.
you will need to investigate deeper...
-
Hi,
There's a bug report related to that message.
-
I had ssh connection problems with some version combinations of ssh client and server. especially root logins are default disabled in newer ssh servers and must be enabled first. password logins were disabled in some cases too.
you will need to investigate deeper...
wrote on 19 Jul 2018, 06:50 last edited by@aha_1980 My investigations continue. There is some bizarre behaviour going on with the Angstrom target - a lot of
ssh
features or commands don't seem to be present - even though I canssh
into the thing. For examplessh-agent
,ssh-add
, etc are not present. I think when time allows, I'll push over to using Ubuntu on the target and forget about the current deployment.@SGaist Already spotted the bug report which was closed a while back. However, no work around had been suggested for it.
-
@aha_1980 My investigations continue. There is some bizarre behaviour going on with the Angstrom target - a lot of
ssh
features or commands don't seem to be present - even though I canssh
into the thing. For examplessh-agent
,ssh-add
, etc are not present. I think when time allows, I'll push over to using Ubuntu on the target and forget about the current deployment.@SGaist Already spotted the bug report which was closed a while back. However, no work around had been suggested for it.
@webzoid said in QtCreator and Linux Device: SSH Connection Failure:
@SGaist Already spotted the bug report which was closed a while back. However, no work around had been suggested for it.
As the bug is fixed, you don't need a workaround :)
For example ssh-agent, ssh-add, etc are not present. I think when time allows, I'll push over to using Ubuntu on the target and forget about the current deployment. We use Angstrom on our Apalis iMX6 too, and deploying from Creator work - we just can't debug on target, but that's another story ;)
Ok, but they are not needed everyday - maybe they are just missing to save flash space.
even though I can ssh into the thing
So connecting by command line works? Even with public key? I just don't work from Creator?
-
wrote on 20 Jul 2018, 16:16 last edited by
-
wrote on 1 Dec 2020, 20:29 last edited by
@Cleiton-Bueno ,
I tried to install Qt Creator trying to connect with my target Linux board as target device,
I made static IP for target device and tried in terminal with this command a you suggested. I have attached snapshot of error it is showing. Please help me with this.
Thanks
Gokul.
-
@Cleiton-Bueno ,
I tried to install Qt Creator trying to connect with my target Linux board as target device,
I made static IP for target device and tried in terminal with this command a you suggested. I have attached snapshot of error it is showing. Please help me with this.
Thanks
Gokul.
Hi @Gokulnath,
- how is your target connected to your computer?
- which IP address does your Linux machine have?
- it seems your Linux runs inside VirtualBox, how is the virtual network configured (bridged, NAT, ...)?
Regards