Tuesday, July 21, 2009

FIX : Unable to open pty: No such file or directory

While trying to SSH or enter into a VPS from the node, you may get the following error :

Unable to open pty: No such file or directory

or

root@tip~]# vzctl enter 900
enter into VE 900 failed
Unable to open pty: No such file or directory

There is a temporary and permenant fix for this issue.

Temporary Fix :-

Execute the following commands from the node

vzctl exec VEID /sbin/MAKEDEV pty

vzctl exec VEID /sbin/MAKEDEV tty

vzctl enter VEID

Where VEID is the VPS id.

Permanent Fix :-

First temporarly fix the issue and enter into the VPS.

1) vzctl enter VEID

2) Edit the file /etc/rc.sysinit of the VPS

vi /etc/rc.sysini

3) Search for the line /sbin/start_udev and comment it

#/sbin/start_udev

4) Add the following two lines under /sbin/start_udev

#/sbin/start_udev
/sbin/MAKEDEV tty
/sbin/MAKEDEV pty
Logout from your VPS (Ctrl d)

5) Reboot the VPS and you are done!

vzctl restart VEID

2 comments:

  1. Nice post. ӏ was chесκing cοnstantly this blog and I'm impressed! Extremely helpful information specifically the last part :) I care for such info a lot. I was looking for this certain information for a long time. Thank you and best of luck.

    Also visit my website: used bucket trucks for sale
    Also see my web page :: bucket trucks for sale

    ReplyDelete
  2. When I originally commented I сlicked
    the "Notify me when new comments are added" checkbox and now each time a comment is added I get four
    e-mails ωith the same comment. Is there аny
    wаy you can rеmoѵe mе from that ѕervice?
    Bless you!

    my web-ѕite; tens unit
    my website :: tens units for sale

    ReplyDelete