Re: [Vserver] sshd and ptys

From: Matthieu <m.racine_at_free.fr>
Date: Thu 06 Oct 2005 - 07:56:29 BST
Message-ID: <4344CA9D.3030900@free.fr>

Hello,

I had the same problem :
Is /dev/pts mounted in the vserver ?

If not, you have to add to /etc/vserver/<vserver name>/fstab the line :
devpts /dev/pts devpts rw,gid=5,mode=620 0 0

Hope that helps.

Matthieu

Jim Wight a écrit :

>I'm returning to VServer after being away from it for over a year. One
>thing that worked previously and isn't working for me now is remotely
>logging in via ssh. I see the following in /var/log/messages:
>
>sshd[11932]: error: openpty: Permission denied
>sshd[11932]: error: session_pty_req: session 0 alloc failed
>
>I can reproduce the problem with a simple program that calls openpty.
>The output from strace'ing it contains:
>
>open("/dev/ptmx", O_RDWR) = 3
>statfs("/dev/pts", {f_type="DEVPTS_SUPER_MAGIC", f_bsize=4096, f_blocks=0, f_bfree=0, f_bavail=0, f_files=0, f_ffree=0, f_fsid={0, 0}, f_namelen=255, f_frsize=4096}) = 0
>ioctl(3, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
>ioctl(3, TIOCGPTN, [1]) = 0
>stat64("/dev/pts/1", {st_mode=S_IFCHR|0600, st_rdev=makedev(136, 1), ...}) = 0
>statfs("/dev/pts/1", {f_type="DEVPTS_SUPER_MAGIC", f_bsize=4096, f_blocks=0, f_bfree=0, f_bavail=0, f_files=0, f_ffree=0, f_fsid={0, 0}, f_namelen=255, f_frsize=4096}) = 0
>ioctl(3, TIOCSPTLCK, [0]) = 0
>ioctl(3, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
>ioctl(3, TIOCGPTN, [1]) = 0
>stat64("/dev/pts/1", {st_mode=S_IFCHR|0600, st_rdev=makedev(136, 1), ...}) = 0
>open("/dev/pts/1", O_RDWR|O_NOCTTY) = -1 EACCES (Permission denied)
>
>Inside the vserver, /dev looks like this:
>
># ls -l /dev
>total 0
>crw-rw-rw- 1 root root 1, 7 Oct 3 08:15 full
>srw-rw-rw- 1 root root 0 Oct 5 11:52 log
>crw-rw-rw- 1 root root 1, 3 Oct 3 08:15 null
>crw-rw-rw- 1 root root 5, 2 Oct 3 08:16 ptmx
>drwxr-xr-x 2 root root 0 Oct 3 15:36 pts
>crw-r--r-- 1 root root 1, 8 Oct 3 08:16 random
>crw-rw-rw- 1 root root 5, 0 Oct 3 08:16 tty
>crw-r--r-- 1 root root 1, 9 Oct 3 08:16 urandom
>crw-rw-rw- 1 root root 1, 5 Oct 3 08:17 zero
>
>What have I missed?
>
>I am using kernel 2.6.12.5 with patch-2.6.12.4-vs2.0 and
>util-server-0.30.208. The host's filesystem is Fedora Core 2 and the
>vserver's FC4.
>
>Jim
>
>
>_______________________________________________
>Vserver mailing list
>Vserver@list.linux-vserver.org
>http://list.linux-vserver.org/mailman/listinfo/vserver
>
>
>
>

_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Thu Oct 6 07:56:45 2005

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Thu 06 Oct 2005 - 07:56:48 BST by hypermail 2.1.8