Server refused to allocate pty - solved (sort of)
Jaime Buffery
nestu at espresso.foo-projects.org
Sun Feb 13 12:35:38 UTC 2005
On Sat, Feb 12, 2005 at 10:01:14PM -0700, Richard Pyne wrote:
> > Just running in debug didn't give a whole lot of useful
> > information, but the system log did show
> >
> > [sshd] error: openpty: No such file or directory
> >
> > Running under strace gave some somewhat helpful information, it
> > gave a whole series of errors like:
> >
> > open("/dev/ptya0", O_RDWR) = -1 ENXIO (No such device or
> > address)
> > .
> > .
> > .
> > open("/dev/ptyef", O_RDWR) = -1 ENXIO (No such device or
> > address)
> >
> > as it tried to open all 256 pty devices.
> >
> > The puzzling part is that they exist as links into /dev/pty/m0
> > through /dev/pty/m255 which are all device nodes of major 2
> > minor 0-255 with permissions crw-rw-rw-
> >
> > So now I see what is happening, but have no idea whay.
> >
> > Thanks for your help.
>
> The solution is (drum roll please) udev (with the default
> configuration) does not provide /dev/ptmx (major 5, minor 2).
> manually creating it solved the problem.
I'm running udev, and:
ls -l /dev/ptmx
crw-rw-rw- 1 root root 5, 2 2005-02-13 13:23 /dev/ptmx
In the permission file of 050 and before (that is generated from a patch file):
grep "ptmx" udev-defaults-3.patch
+ptmx:root:tty:0666
> Now, on to the next one......
>
> Is the 2.6 kernel with udev supposed to be using sysfs? I tried
> mounting it and then found that on a re-boot I get an "Unable to
> open initial console" and the boot hangs.
$ lvu DEPENDS udev
depends hotplug &&
depends sysfsutils
proc -> sysfs -> udev. That is the right order they should be mounted and that's
the order they are mounted in the mount script ( see /etc/init.d/mount ).
> The only way I have found (so far) to recover is to boot from
> the install cd, copy the /dev directory from the cd to the hard
> drive, disable sysfs in /etc/fstab and reboot.
>
> Any insights will be greatly appreciated.
Various things could have happened:
a ) Some ppl have suffered from problems with legacy pty's enabled in kernel
-not my case, but maybe yours.
b ) you have no hotplug in your kernel
c ) you have removed sysfsutils
d ) you haven't read the 2.6 howto or any related documentation on udev.
e ) you haven't read the The kernel commandline /dev params mini-HowTo.
> --Richard
HTH,
Jaime :)
More information about the Lunar
mailing list