Re: [SLUG] I am beginning to lose my hair

From: Scott Piper (piper@ij.net)
Date: Mon Feb 03 2003 - 17:37:28 EST


It could be that you are using inetd instead of daemons to run
services. That way they are only called when needed. Check
/etc/inetd.conf to make sure that telnet is a service provided, and that
the program called when there is port traffic is installed. From my
/etc/inetd.conf file (Debian), I have included the line for telnet,
which I have disabled on my system by commenting it out.

# <service_name> <sock_type> <proto> <flags> <user> <server_path> <args>

#:STANDARD: These are standard services.
#telnet stream tcp nowait telnetd.telnetd /usr/sbin/tcpd
/usr/sbin/in.telnetd

here, inetd listens to port 23 and calls /usr/sbin/in.telnetd for a
telnet connection

you can change the file and then (in Debian at least) restart inetd as in

/etc/init.d/inetd restart

then telnet localhost or check with netstat to see if the port is being
listened to

as above, if I try

telnet localhost

I receive the response

Trying 127.0.0.1...
telnet: Unable to connect to remote host: Connection refused

uncommented and with inetd restarted, I receive the login prompt

scott

Rock wrote:

>I can now take the time to revisit this issue after having been
>distracted by my boss for a few days. If you recall, I cannot telnet,
>ssh or rsh into this redhat 8.0 install. rsh will not go out either.
>Matt suggested the following:
>
>2) Run nmap and/or netstat to determine if a box is listening on port 23
>for telnet and port 22 for ssh:
> # This will show what ports are listening and which applications
> have the ports open (run as root).
> $ netstat -pnl | egrep "22|23"
> # From a remote host:
> $ nmap -p 22-23 hostname
>
>*** neither port is listening at this point!!
>
>3) Run ps to see if telnet/ssh is running:
>
>*** neither is running
>
> $ ps axf | egrep "ssh|telnet"
>4) Search for sshd/telnetd to see if you have a variation of the
>ssh/telnet daemon(s) installed:
> $ find /usr -name "*telnet*"
> $ find /usr -name "*ssh*"
>
>*** I have removed and re installed telnet from redhat rpm's.
>
>5) If some variation of sshd/telnetd is found, manually run the command
>as root:
> $ /usr/sbin/telnetd
> OR
> $ /usr/sbin/sshd
>
>*** I have nothing that resembles a daemon process to execute at all.
>
>
>6) See if you can ssh/telnet to the host from a remote host after
>manually running the command.
> user@remotehost$ ssh <hostname or ip_address>
> user@remotehost$ telnet <hostname or ip_address>
>
>*** Nope, nothing
>
>I have the same problem with rsh. Nothing happens when I execute the
>command.
>
>What the heck as I missing here?? I installed the same OS on a
>workstation and viola, everything works. It is as if the install
>screwed up somewhere.
>
>Michael C. Rock
>
>
>



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 14:54:58 EDT