Unable to open pty: No such file or directory

Unable to access the VPS via SSH? Are you getting the following error?

# vzctl enter 1022
enter into VE 1022 failed
Unable to open pty: No such file or directory

Fix:

# vzctl exec 1022 /sbin/MAKEDEV pty
# vzctl exec 1022 /sbin/MAKEDEV tty
# vzctl enter 1022

To Fix this issue permanently,

1. Edit the file /etc/rc.sysinit of the VPS server (Here VEID of the VPS server is 1022)

2. Comment the line
#/sbin/start_udev

3. Add the following lines after /sbin/start_udev:

/sbin/MAKEDEV tty
/sbin/MAKEDEV pty

4. Reboot your VPS
vzctl restart 1022

Note: Do ensure that this is checked when you run yum/up2date on server.

Also check the following posts

2 Responses

  1. Thomas Says:

    this fix worked out great for me…thanks for the help.

  2. Mikado Says:

    Glad it helped me out :-)

    http://www.eukhost.com/forums/f29/vps-unable-open-pty-no-such-file-directory-2666/#post44314

Leave a Comment

Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.