sshpass: Failed to set controlling terminal in child (TIOCSCTTY)

206 views
Skip to first unread message

Polonius

unread,
Aug 19, 2022, 6:14:48 AM8/19/22
to AWX Project
I'm getting somewhat frustrated with this, I've all of a sudden started getting the below error on several servers, other servers do not have the issue (they are all running the same package versions/kernel).

sshpass: Failed to set controlling terminal in child (TIOCSCTTY)

I raised a ticket for Ansible:


In which it was suggested that the issue was with sshpass (although my execution environment has not updated in over 2 months).

I've tried switching to paramiko, and now I get:

Failed to authenticate: Bad authentication type; allowed types: ['publickey', 'gssapi-keyex', 'gssapi-with-mic']"

Which seems to me that paramiko is not using public key authentication (password authentication is disabled on the servers).

So I can't use ssh, and I can't use paramiko. I can't find any documentation to disable sshpass (I assume this is not actually needed as I'm only using public key authentication).

So what do I do? My AWX instance has been rendered useless overnight.

AWX Project

unread,
Aug 19, 2022, 1:07:48 PM8/19/22
to AWX Project
Hello Polonius,
Your question seems to be about using Ansible, not about AWX. https://groups.google.com/g/ansible-project is the best place to visit for user questions about Ansible. Thanks!

-AWX Team 

Matt Page

unread,
Aug 19, 2022, 3:39:44 PM8/19/22
to awx-p...@googlegroups.com
Hello

Thanks for your reply. The original error was related to ansible, however this has now crossed over to AWX.

Is it possible for paramiko to use private keys stored in AWX as a credential? I get 'Bad authentication type' from the server when using paramiko as the connection type. This suggests to me that paramiko has not found the SSH key within AWX and fallen back to password auth.

Thanks

On 19 Aug 2022, at 18:07, AWX Project <awx-p...@googlegroups.com> wrote:

Hello Polonius,
--
You received this message because you are subscribed to a topic in the Google Groups "AWX Project" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/awx-project/sF0BPxs8eWk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to awx-project...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/awx-project/6b57409b-90fd-4dd4-9ba4-320c9f1c2ae2n%40googlegroups.com.

Polonius

unread,
Aug 23, 2022, 4:36:42 AM8/23/22
to AWX Project
Hello

Any tips? I would like to either use paramiko, or disabled sshpass (I can't find a way to disable use of sshpass).

Using paramiko, with an AWX public key credential results in 'Bad authentication type'.

Thanks

AWX Project

unread,
Aug 25, 2022, 9:43:29 AM8/25/22
to AWX Project
Hi Polonius,

Could you please supply a more detailed stack trace of the Paramiko error? You should be able to see the allowed connection types to paramiko-ssh and this might help us trace down the error.

Thanks,
AWX Team

Reply all
Reply to author
Forward
0 new messages