[Lxc-users] ssh'ing in the container ( ioctl operation not permitted /dev/tty failed - no such device or address )
swair shah
swairshah at gmail.com
Mon Oct 22 10:26:55 UTC 2012
On Mon, Oct 22, 2012 at 3:49 PM, Fajar A. Nugraha <list at fajar.net> wrote:
> On Mon, Oct 22, 2012 at 5:11 PM, swair shah <swairshah at gmail.com> wrote:
> > I have a container running centos 6, on a host system also running
> centos 6.
> > I have allocated a different subnet for containers and I'm able to ping
> the
> > container.
> >
> > Now when I try to ssh into the container from another console, it
> prompts me
> > for password. This is the log on the host system.
> >
> > Oct 22 14:00:25 localhost sshd[264]: Accepted password for root from
> > 192.168.0.2 port 38355 ssh2
> > Oct 22 14:00:25 localhost sshd[264]: pam_unix(sshd:session): session
> opened
> > for user root by (uid=0)
> > Oct 22 14:00:25 localhost sshd[266]: error: ioctl(TIOCSCTTY): Operation
> not
> > permitted
> > Oct 22 14:00:25 localhost sshd[266]: error: open /dev/tty failed - could
> not
> > set controlling tty: No such device or address
>
> That's odd. My centos container has no /dev/tty and it works just
> fine. My host has one though.
>
> >
> > I should also mention that my host machine is a remote one and I have
> ssh'd
> > into that.
>
> It shouldn't matter.
> >
> > Do I need to make any specific changes to the tty conf in the container?
>
> Do you have /dev/pts directory inside the container? What files are in
> there?
>
/dev/pts has
crw--w---- 1 root tty 136, 0 Oct 22 15:54 0
crw--w---- 1 swair tty 136, 7 Oct 22 15:52 7
c--------- 1 root root 5, 2 Oct 22 15:25 ptmx
> Do you have /dev/tty inside the host?
>
Host has /dev/tty.
swair.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20121022/3d42be17/attachment.html>
More information about the lxc-users
mailing list