OpenVZ Forum


Home » General » Support » *SOLVED* Server refused to allocate pty
icon2.gif  *SOLVED* Server refused to allocate pty [message #190] Wed, 05 October 2005 05:52 Go to next message
devnu11 is currently offline  devnu11
Messages: 64
Registered: September 2005
Location: USA
Member

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]:
...



Just Because You Have One, Doesn't Mean You Have To Be One!

[Updated on: Fri, 20 July 2007 08:54] by Moderator

Report message to a moderator

Re: Server refused to allocate pty [message #191 is a reply to message #190] Wed, 05 October 2005 06:30 Go to previous messageGo to next message
devnu11 is currently offline  devnu11
Messages: 64
Registered: September 2005
Location: USA
Member

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
Cool


Just Because You Have One, Doesn't Mean You Have To Be One!
Re: Server refused to allocate pty [message #192 is a reply to message #191] Wed, 05 October 2005 12:11 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

Most probably the right way is to run
vzctl exec <VPSID> /sbin/MAKEDEV ptyp


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Server refused to allocate pty [message #10038 is a reply to message #190] Tue, 06 February 2007 08:50 Go to previous messageGo to next message
youp is currently offline  youp
Messages: 82
Registered: September 2005
Location: Belgium
Member

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
Re: Server refused to allocate pty [message #14948 is a reply to message #191] Sat, 14 July 2007 02:46 Go to previous messageGo to next message
alevchuk is currently offline  alevchuk
Messages: 22
Registered: February 2007
Location: University of California,...
Junior Member
This works for me but when I restart the VE the problem occurs again.

What is a good way to solve this problem permanently?
Re: Server refused to allocate pty [message #14951 is a reply to message #14948] Sat, 14 July 2007 03:11 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

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.

Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Server refused to allocate pty [message #14953 is a reply to message #14951] Sat, 14 July 2007 05:06 Go to previous messageGo to next message
alevchuk is currently offline  alevchuk
Messages: 22
Registered: February 2007
Location: University of California,...
Junior Member
Thank you Kir.
Re: Server refused to allocate pty [message #27127 is a reply to message #10038] Sun, 10 February 2008 12:24 Go to previous messageGo to next message
istdizayn is currently offline  istdizayn
Messages: 1
Registered: February 2008
Junior Member
vzctl exec $VPSID /sbin/MAKEDEV tty


Please Try this command worked.


Istanbul Web Dizayn / Infra Hosting Network Solutions
Re: Server refused to allocate pty [message #30704 is a reply to message #27127] Wed, 04 June 2008 11:19 Go to previous messageGo to next message
gozargah is currently offline  gozargah
Messages: 32
Registered: June 2008
Member
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?
Re: Server refused to allocate pty [message #30706 is a reply to message #30704] Wed, 04 June 2008 11:21 Go to previous messageGo to next message
maratrus is currently offline  maratrus
Messages: 1495
Registered: August 2007
Location: Moscow
Senior Member
Hi,

is there udev inside that VPS?
Re: Server refused to allocate pty [message #30708 is a reply to message #30706] Wed, 04 June 2008 14:28 Go to previous messageGo to next message
gozargah is currently offline  gozargah
Messages: 32
Registered: June 2008
Member
Yes, we have "dev" in vps.
Re: Server refused to allocate pty [message #30709 is a reply to message #30708] Wed, 04 June 2008 14:42 Go to previous messageGo to next message
maratrus is currently offline  maratrus
Messages: 1495
Registered: August 2007
Location: Moscow
Senior Member
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.
Re: Server refused to allocate pty [message #30711 is a reply to message #10038] Wed, 04 June 2008 14:46 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

youp,

There is a wiki article about the issue, maybe it will answer all your questions: http://wiki.openvz.org/Container_enter_failed


Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Server refused to allocate pty [message #30712 is a reply to message #30709] Wed, 04 June 2008 14:52 Go to previous messageGo to next message
gozargah is currently offline  gozargah
Messages: 32
Registered: June 2008
Member
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?
Re: Server refused to allocate pty [message #30713 is a reply to message #30712] Wed, 04 June 2008 14:55 Go to previous messageGo to next message
maratrus is currently offline  maratrus
Messages: 1495
Registered: August 2007
Location: Moscow
Senior Member
Hello,

Kir suggests wonderful link. I think it describes your problem totally. But if you have any questions please ask.
Re: Server refused to allocate pty [message #31158 is a reply to message #30708] Thu, 19 June 2008 18:15 Go to previous messageGo to next message
gozargah is currently offline  gozargah
Messages: 32
Registered: June 2008
Member
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?
Re: Server refused to allocate pty [message #31172 is a reply to message #10038] Fri, 20 June 2008 08:14 Go to previous messageGo to next message
kir is currently offline  kir
Messages: 1645
Registered: August 2005
Location: Moscow, Russia
Senior Member

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*'



Kir Kolyshkin
http://static.openvz.org/userbars/openvz-developer.png
Re: Server refused to allocate pty [message #33432 is a reply to message #191] Tue, 14 October 2008 14:21 Go to previous message
rduval is currently offline  rduval
Messages: 4
Registered: July 2008
Location: Toronto, Ontario, Canada
Junior Member
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!
Previous Topic: ~# ip route add 192.168.177.n dev vzbr0
Next Topic: zaptel compile in container
Goto Forum:
  


Current Time: Sat Nov 16 23:16:40 GMT 2024

Total time taken to generate the page: 0.03029 seconds