My host OS is CentOS 4.1 and I have configured a VPS of CentOS 4.1 via vztmpl-centos-4 and added the simfs fix from this forum. I have had a recurring problem of the error "Server refused to allocate pty" when trying to SSH to this CentOS VPS. It seems that after the host is restarted the error occurs. As best I can remember I performed the following. Created the VPS and was able to SSH into the VPS. I vzyum'ed to add YUM to the VPS and restarted the VPS. All was fine so I rebooted the host. SSH still worked. I then "yum update" from inside the VPS. I then restarted the VPS and and all was fine, I rebooted the host and received the pty error. I'm including some things which I have received which amount to errors. # vzctl start 101 Starting VPS ... vzquota : (error) Quota off syscall for id 101: Device or resource busy vzquota setlimit -f failed [3] vzquota : (warning) Quota is running for id 101 already VPS is mounted Adding IP address(es): 72.36.180.xxx Setting CPU units: 1000 Set hostname: devnu11.servebeer.com File resolv.conf was modified VPS start in progress... # # vzctl enter 101 Unable to open pty: No such file or directory enter failed From VPS 101 /var/log/messages Oct 5 00:40:51 devnu11 shutdown: shutting down for system halt Oct 5 00:40:51 devnu11 init: Switching to runlevel: 0 Oct 5 00:40:51 devnu11 httpd: httpd shutdown succeeded Oct 5 00:40:51 devnu11 sshd: sshd -TERM succeeded Oct 5 00:40:51 devnu11 sendmail: sendmail shutdown succeeded Oct 5 00:40:51 devnu11 sendmail: sm-client shutdown succeeded Oct 5 00:40:51 devnu11 xinetd[15870]: Exiting... Oct 5 00:40:51 devnu11 xinetd: xinetd shutdown succeeded Oct 5 00:40:51 devnu11 exiting on signal 15 Oct 5 00:46:03 devnu11 syslogd 1.4.1: restart. Oct 5 00:46:03 devnu11 syslog: syslogd startup succeeded Oct 5 00:46:03 devnu11 syslog: klogd succeeded Oct 5 00:46:03 devnu11 sshd: succeeded Oct 5 00:46:03 devnu11 xinetd: xinetd startup succeeded Oct 5 00:46:03 devnu11 xinetd[19556]: xinetd Version 2.3.13 started with libwrap loadavg options compiled in. Oct 5 00:46:03 devnu11 xinetd[19556]: Started working: 0 available services Oct 5 00:46:03 devnu11 sendmail: sendmail startup succeeded Oct 5 00:46:03 devnu11 sendmail: sm-client startup succeeded Oct 5 00:46:03 devnu11 httpd: httpd startup succeeded Oct 5 00:46:03 devnu11 init: no more processes left in this runlevel Oct 5 00:46:02 devnu11 rc.sysinit: -e Oct 5 00:46:02 devnu11 sysctl: net.ipv4.ip_forward = 0 Oct 5 00:46:02 devnu11 sysctl: error: unknown error 1 setting key 'net.ipv4.conf.default.rp_filter' Oct 5 00:46:02 devnu11 sysctl: error: unknown error 1 setting key 'net.ipv4.conf.default.accept_source_route' Oct 5 00:46:02 devnu11 sysctl: error: unknown error 1 setting key 'kernel.sysrq' Oct 5 00:46:02 devnu11 sysctl: error: unknown error 1 setting key 'kernel.core_uses_pid' Oct 5 00:46:02 devnu11 rc.sysinit: Configuring kernel parameters: failed Oct 5 00:46:02 devnu11 date: Wed Oct 5 00:46:02 EDT 2005 Oct 5 00:46:02 devnu11 rc.sysinit: Setting clock : Wed Oct 5 00:46:02 EDT 2005 succeeded Oct 5 00:46:02 devnu11 rc.sysinit: Setting hostname devnu11.servebeer.com: succeeded Oct 5 00:46:02 devnu11 mount: mount: none already mounted or /dev/pts busy Oct 5 00:46:02 devnu11 mount: mount: according to mtab, devpts is already mounted on /dev/pts Oct 5 00:46:02 devnu11 rc.sysinit: Mounting local filesystems: failed Oct 5 00:46:02 devnu11 rc.sysinit: Enabling local filesystem quotas: succeeded Oct 5 00:46:02 devnu11 rc.sysinit: Enabling swap space: succeeded Oct 5 00:46:03 devnu11 init: Entering runlevel: 3 Oct 5 00:46:03 devnu11 iptables: succeeded Oct 5 00:46:03 devnu11 iptables: succeeded Oct 5 00:46:03 devnu11 sysctl: net.ipv4.ip_forward = 0 Oct 5 00:46:03 devnu11 sysctl: error: unknown error 1 setting key 'net.ipv4.conf.default.rp_filter' Oct 5 00:46:03 devnu11 sysctl: error: unknown error 1 setting key 'net.ipv4.conf.default.accept_source_route' Oct 5 00:46:03 devnu11 sysctl: error: unknown error 1 setting key 'kernel.sysrq' Oct 5 00:46:03 devnu11 sysctl: error: unknown error 1 setting key 'kernel.core_uses_pid' Oct 5 00:46:03 devnu11 network: Setting network parameters: failed Oct 5 00:46:03 devnu11 network: Bringing up loopback interface: succeeded Oct 5 00:46:03 devnu11 ifup: SIOCADDRT: Network is unreachable Oct 5 00:46:03 devnu11 network: Bringing up interface venet0: succeeded Oct 5 00:46:36 devnu11 sshd(pam_unix)[19612]: session opened for user admin by (uid=0) Oct 5 01:29:28 devnu11 sshd(pam_unix)[19612]: session closed for user admin From Host /var/log/messages on reboot Oct 4 17:52:15 schizoid smartd: smartd startup succeeded Oct 4 17:51:29 schizoid date: Tue Oct 4 17:51:29 EDT 2005 Oct 4 17:51:29 schizoid rc.sysinit: Setting clock (localtime): Tue Oct 4 17:51:29 EDT 2005 succeeded Oct 4 17:51:29 schizoid rc.sysinit: Loading default keymap succeeded Oct 4 17:51:29 schizoid rc.sysinit: Setting hostname schizoid.iconch.com: succeeded Oct 4 17:51:29 schizoid fsck: /: clean, 66825/393216 files, 481071/785176 blocks Oct 4 17:52:15 schizoid sshd: succeeded Oct 4 17:51:29 schizoid rc.sysinit: Checking root filesystem succeeded Oct 4 17:51:29 schizoid rc.sysinit: Remounting root filesystem in read-write mode: succeeded Oct 4 17:51:29 schizoid lvm.static: Oct 4 17:51:29 schizoid lvm.static: No volume groups found Oct 4 17:51:29 schizoid rc.sysinit: Setting up Logical Volume Management: succeeded Oct 4 17:51:29 schizoid fsck: /boot: clean, 44/38152 files, 21792/152584 blocks Oct 4 17:51:29 schizoid fsck: /vz: clean, 45953/9388032 files, 832278/18755879 blocks Oct 4 17:52:15 schizoid xinetd: xinetd startup succeeded Oct 4 17:51:29 schizoid rc.sysinit: Checking filesystems succeeded Oct 4 17:51:29 schizoid rc.sysinit: Mounting local filesystems: succeeded Oct 4 17:51:29 schizoid rc.sysinit: Enabling local filesystem quotas: succeeded Oct 4 17:51:30 schizoid rc.sysinit: Enabling swap space: succeeded Oct 4 17:51:30 schizoid init: Entering runlevel: 3 Oct 4 17:52:09 schizoid kudzu: failed Oct 4 17:52:09 schizoid kudzu: Hardware configuration timed out. Oct 4 17:52:09 schizoid kudzu: Run '/usr/sbin/kudzu' from the command line to re-detect. Oct 4 17:52:09 schizoid sysctl: net.ipv4.ip_forward = 1 Oct 4 17:52:09 schizoid sysctl: net.ipv4.conf.default.proxy_arp = 0 Oct 4 17:52:09 schizoid sysctl: net.ipv4.conf.all.rp_filter = 1 Oct 4 17:52:09 schizoid sysctl: net.ipv4.conf.default.send_redirects = 1 Oct 4 17:52:09 schizoid sysctl: net.ipv4.conf.all.send_redirects = 0 Oct 4 17:52:09 schizoid sysctl: net.ipv4.conf.default.rp_filter = 1 Oct 4 17:52:09 schizoid sysctl: net.ipv4.conf.default.accept_source_route = 0 Oct 4 17:52:09 schizoid sysctl: kernel.sysrq = 1 Oct 4 17:52:09 schizoid sysctl: kernel.core_uses_pid = 1 Oct 4 17:52:09 schizoid network: Setting network parameters: succeeded Oct 4 17:52:10 schizoid network: Bringing up loopback interface: succeeded Oct 4 17:52:12 schizoid network: Bringing up interface eth0: succeeded Oct 4 17:52:12 schizoid ifup: Bringing up interface venet0: Oct 4 17:52:12 schizoid ifup-venet: Bringing up interface venet0: succeeded Oct 4 17:52:12 schizoid ifup: ^[[60G Oct 4 17:52:12 schizoid ifup: Oct 4 17:52:12 schizoid ifup: Configuring interface venet0: Oct 4 17:52:12 schizoid sysctl: net.ipv4.conf.venet0.send_redirects = 0 Oct 4 17:52:12 schizoid ifup-venet: Configuring interface venet0: succeeded Oct 4 17:52:12 schizoid ifup: ^[[60G Oct 4 17:52:12 schizoid ifup: Oct 4 17:52:12 schizoid network: Bringing up interface venet0: succeeded Oct 4 17:52:16 schizoid xinetd[801]: xinetd Version 2.3.13 started with libwrap loadavg options compiled in. Oct 4 17:52:16 schizoid xinetd[801]: Started working: 0 available services Oct 4 17:52:24 schizoid ntpdate[812]: step time server 204.17.42.199 offset -0.548425 sec Oct 4 17:52:24 schizoid ntpd: succeeded Oct 4 17:52:24 schizoid ntpd[820]: ntpd 4.2.0a@1.1190-r Mon Feb 21 17:54:52 GMT 2005 (1) Oct 4 17:52:24 schizoid ntpd: ntpd startup succeeded Oct 4 17:52:24 schizoid ntpd[820]: precision = 1.000 usec Oct 4 17:52:24 schizoid ntpd[820]: Listening on interface wildcard, 0.0.0.0#123 Oct 4 17:52:24 schizoid ntpd[820]: Listening on interface lo, 127.0.0.1#123 Oct 4 17:52:24 schizoid ntpd[820]: Listening on interface eth0, 72.36.180.226#123 Oct 4 17:52:24 schizoid ntpd[820]: kernel time sync status 0040 Oct 4 17:52:24 schizoid ntpd[820]: frequency initialized 106.572 PPM from /var/lib/ntp/drift Oct 4 17:52:25 schizoid sendmail: sendmail startup succeeded Oct 4 17:52:25 schizoid sendmail: sm-client startup succeeded Oct 4 17:52:25 schizoid crond: crond startup succeeded Oct 4 17:52:25 schizoid anacron: anacron startup succeeded Oct 4 17:52:25 schizoid atd: atd startup succeeded Oct 4 17:52:25 schizoid kernel: NET: Unregistered protocol family 17 Oct 4 17:52:25 schizoid kernel: NET: Registered protocol family 17 Oct 4 17:52:25 schizoid vz: loading OpenVZ modules succeeded Oct 4 17:52:25 schizoid kernel: VPS: 101: started Oct 4 17:52:27 schizoid vz: succeeded Oct 4 17:52:27 schizoid kernel: VPS: 102: started Oct 4 17:52:29 schizoid vz: succeeded Oct 4 17:52:30 schizoid messagebus: messagebus startup succeeded Oct 4 17:52:30 schizoid haldaemon: haldaemon startup succeeded Oct 4 17:52:31 schizoid fstab-sync[2418]: removed all generated mount points Oct 4 17:52:33 schizoid webmin(pam_unix)[2409]: authentication failure; logname= uid=0 euid=0 tty= ruser= rhost= user=root Oct 4 17:52:35 schizoid rc: Starting webmin: succeeded Oct 4 17:55:40 schizoid ntpd[820]: synchronized to LOCAL(0), stratum 10 Oct 4 17:55:40 schizoid ntpd[820]: kernel time sync disabled 0041 Oct 4 17:56:45 schizoid ntpd[820]: synchronized to 204.17.42.199, stratum 2 # uname -a Linux xxx.xxx.com 2.6.8-022stab038.1 #1 Thu Sep 22 16:01:35 MSD 2005 i686 athlon i386 GNU/Linux I guess that's all the info I have to offer. As I said this has been a recurring problem and it has happened in fedora core 3 and 4 also. As a note I have VPS 102 which is Fedora 4 which seems to be fine right now.
Swdev was kind enough to assist me in #openvz and I was able to correct the problem. I am adding what I did as a reference for someone else. vzctl exec 101 /sbin/MAKEDEV tty then vzctl exec 101 /sbin/MAKEDEV pty This solved the problem and I can log in as before. I believe udev was updated from a "yum update" and caused the problem. Thanks again swdev
Most probably the right way is to run vzctl exec <VPSID> /sbin/MAKEDEV ptyp
i have a similar error : -> vzctl enter 133 entered into VE 133 mesg: error: tty device is not owned by group `tty' i have tested thsi command : vzctl exec 133 /sbin/MAKEDEV ptyp and vzctl exec 133 /dev/MAKEDEV tty and vzctl exec 133 /dev/MAKEDEV pty but nothing work best regards
This works for me but when I restart the VE the problem occurs again. What is a good way to solve this problem permanently?
I guess you should disable udev inside a VE, and disable mounting /dev on tmpfs. After that, create devices and they will be there permanently.
vzctl exec $VPSID /sbin/MAKEDEV tty Please Try this command worked.
Hi, I do following: vzctl exec 133 /sbin/MAKEDEV ptyp and vzctl exec 133 /dev/MAKEDEV tty and vzctl exec 133 /dev/MAKEDEV pty And problem resolved, but issue come back when i restart customer vps. How can fix this too?
Hi, is there udev inside that VPS?
Hi, No, I've meant something else. I asked you about "udev" package that helps us dynamically "create" appropriate devices (and we can find them inside /dev directory). If you have rpm-based VPS you can check that by typing "rpm -qa | grep udev" command.
youp, There is a wiki article about the issue, maybe it will answer all your questions: http://wiki.openvz.org/Container_enter_failed
maratrus wrote on Wed, 04 June 2008 10:42 Hi, No, I've meant something else. I asked you about "udev" package that helps us dynamically "create" appropriate devices (and we can find them inside /dev directory). If you have rpm-based VPS you can check that by typing "rpm -qa | grep udev" command. [root@datamedia dev]# rpm -qa | grep udev udev-095-14.9.el5 What can i must do now?
Hello, Kir suggests wonderful link. I think it describes your problem totally. But if you have any questions please ask.
I have following error when run "vzctl exec 270 /dev/MAKEDEV tty" and customer vps going down and must be reboot for back online. MAKEDEV: error making /dev/ttyEQ664: Cannot allocate memory Where is problem and how can fix this?
youp wrote on Tue, 06 February 2007 11:50 i have a similar error : -> vzctl enter 133 entered into VE 133 mesg: error: tty device is not owned by group `tty' This is about bad group ownership of files. I guess you have to do something like: vzctl exec 133 'chgrp tty /dev/ttyp* /dev/ptyp*'
I had exactly same problem after a yum update on centos 5.0, followed the same proceedure from the host with vzctl exec 101 /sbin/MAKEDEV tty and vzctl exec 101 /sbin/MAKEDEV pty And it's good again. Thanks!