Bug 5306 - busybox 1.19.4 telnetd won't allow logins.
Summary: busybox 1.19.4 telnetd won't allow logins.
Status: RESOLVED INVALID
Alias: None
Product: Busybox
Classification: Unclassified
Component: Networking (show other bugs)
Version: 1.19.x
Hardware: PC Linux
: P5 minor
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-06-13 22:00 UTC by Kirby Kuehl
Modified: 2012-06-22 11:59 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kirby Kuehl 2012-06-13 22:00:30 UTC
This is an intermittent bug, but this is what syslog shows when the system gets in this state:

Jun 13 15:35:02 sc143 telnetd[4381]: can't open '/dev/ttyp0': Input/output error 
Jun 13 15:36:24 sc143 telnetd[4585]: can't open '/dev/ttyp0': Input/output error 
Jun 13 15:36:40 sc143 telnetd[4631]: can't open '/dev/ttyp0': Input/output error 

root@sc143:/etc/init.d# which telnetd
/usr/sbin/telnetd
root@sc143:/etc/init.d# ls -la /usr/sbin/telnetd 
lrwxrwxrwx 1 root root 17 2012-06-08 14:43 /usr/sbin/telnetd -> ../../bin/busybox

root@sc143:/etc/init.d# busybox 
BusyBox v1.19.4 (2012-03-01 11:02:04 CST) multi-call binary.
Copyright (C) 1998-2011 Erik Andersen, Rob Landley, Denys Vlasenko
and others. Licensed under GPLv2.
See source distribution for full notice.

Usage: busybox [function] [arguments]...
   or: busybox --list[-full]
   or: function [arguments]...

        BusyBox is a multi-call binary that combines many common Unix
        utilities into a single executable.  Most people will create a
        link to busybox for each function they wish to use and BusyBox
        will act like whatever it was invoked as.

Currently defined functions:
        adjtimex, clear, cmp, dos2unix, eject, free, iostat, mesg, mktemp,
        mpstat, nc, nmeter, nslookup, pipe_progress, reset, run-parts,
        setconsole, start-stop-daemon, stat, strings, telnetd, time,
        traceroute, unix2dos, uudecode, uuencode, which

This is how busybox is configured.
# grep -i telnetd config
CONFIG_TELNETD=y
CONFIG_FEATURE_TELNETD_STANDALONE=y
# CONFIG_FEATURE_TELNETD_INETD_WAIT is not set


telnetd is started from /etc/init.d like so:


 /usr/sbin/telnetd -l /bin/login

Any ideas what could be the root cause of this? Googling turns up lots noise but  nothing that looks like this issue.
Comment 1 Denys Vlasenko 2012-06-14 15:35:44 UTC
Do you have FEATURE_DEVPTS enabled?

Does bug go away if you flip it and rebuild?


config FEATURE_DEVPTS
        bool "Use the devpts filesystem for Unix98 PTYs"
        default y
        help
          Enable if you want BusyBox to use Unix98 PTY support. If enabled,
          busybox will use /dev/ptmx for the master side of the pseudoterminal
          and /dev/pts/<number> for the slave side. Otherwise, BSD style
          /dev/ttyp<number> will be used. To use this option, you should have
          devpts mounted.
Comment 2 Kirby Kuehl 2012-06-14 16:07:14 UTC
(In reply to comment #1)
> Do you have FEATURE_DEVPTS enabled?
> 
> Does bug go away if you flip it and rebuild?
> 
> 
> config FEATURE_DEVPTS
>         bool "Use the devpts filesystem for Unix98 PTYs"
>         default y
>         help
>           Enable if you want BusyBox to use Unix98 PTY support. If enabled,
>           busybox will use /dev/ptmx for the master side of the pseudoterminal
>           and /dev/pts/<number> for the slave side. Otherwise, BSD style
>           /dev/ttyp<number> will be used. To use this option, you should have
>           devpts mounted.

I did have devpts mounted on /dev/pts type devpts (rw,relatime,gid=5,mode=620),
but I did not have this feature enabled. Giving it a try now, thanks.
Comment 3 Denys Vlasenko 2012-06-22 11:59:22 UTC
Seems like it wasn't a bug. Closing.