Yikes ssh login error

May, 19 -- Categories: Linux

When I tried to log in I got this:

ERROR
PTY allocation request failed on channel 0

The only way I could get in was to log in like this:
ssh myusername@myhost “/bin/bash -i”;

After a bit of Googling this was the fix I found that there is a device ptmx that might be missing with this error message. SO:

# /sbin/MAKEDEV -d /dev ptmx

restart ssh

/etc/init.d/sshd restart (reload would work to I would think)