LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-26-2008, 12:38 PM   #16
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15

Yes I am starting telnet as root.

telnetd --help has nothing listed. Bash also says there is no telnetd command. zsh thinks I meant telnet and tried to correct it to that. Also when I look up the manual for telnetd, it brings up the manual for in.telnetd.

Last edited by jhilton; 06-26-2008 at 12:38 PM. Reason: Typos.
 
Old 06-26-2008, 12:44 PM   #17
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,529

Rep: Reputation: 63
Use the telnet command, of course, that is correct for your system. The point is, I'm trying to understand your telnetd's command line options.

Please don't interpret the results for me. Instead, copy and paste the command and its output.

Run your telnetd program, whatever its name, with the --help option.
 
Old 06-26-2008, 12:45 PM   #18
jlm01801
LQ Newbie
 
Registered: Jun 2008
Location: Massachusetts USA
Distribution: Mandriva Corporate 4
Posts: 12

Rep: Reputation: 0
"No, telnet is running. Telnet output the messages:"
Mr C - you are right - I thought of that after my post - my apologies to all.
That's why I veered off to a security related issue.
-Jim
 
Old 06-26-2008, 01:03 PM   #19
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15
Alright well, after running a which telnetd I've found nothing so I'm back to using /usr/sbin/in.telnetd

in.telnetd has no --help. But in its man the options are

Code:
in.telnetd [-Uhlkn46] [-D debugmode][-I initid][-S tos] [-X authtype] [-rlowpty-highpty][-u len][-L /bin/login][-debug [port]]
telnet --help brings up
Code:
telnet [-8][-E][-L][-S tos][-a][-c][-d][-e char][-l user [-n tracefile][-b hostalias ] [-r]
[host-name [port]]
Sorry if this is beginning to get frustrating. I'm beginning to move into unfamiliar areas so I'll be mostly if not wholly, clueless.
 
Old 06-26-2008, 01:06 PM   #20
jlm01801
LQ Newbie
 
Registered: Jun 2008
Location: Massachusetts USA
Distribution: Mandriva Corporate 4
Posts: 12

Rep: Reputation: 0
lets see how telnetd is started..
more /etc/xinetd.d/telnet
 
Old 06-26-2008, 01:11 PM   #21
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15
Code:
service telnet
{
    flags         = REUSE
    socket_type   = stream
    wait          = no
    user          = root
    server        = /usr/sbin/in.telnetd
    log_on_failure += USERID
    disable       = yes
}
 
Old 06-26-2008, 01:13 PM   #22
jlm01801
LQ Newbie
 
Registered: Jun 2008
Location: Massachusetts USA
Distribution: Mandriva Corporate 4
Posts: 12

Rep: Reputation: 0
change disable to no
 
Old 06-26-2008, 01:16 PM   #23
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15
I did before, it was disabled in an earlier post in order to try to start telnetd manually through the console. Changing disable = no and restarted xinetd brings me back to the original problem.
 
Old 06-26-2008, 01:32 PM   #24
jlm01801
LQ Newbie
 
Registered: Jun 2008
Location: Massachusetts USA
Distribution: Mandriva Corporate 4
Posts: 12

Rep: Reputation: 0
check /etc/services and make sure port 23 specifies telnet.
start in.telnetd -D report
...and see what happens when telneting.
you might also try capturing traffic for review
on host running telnetd try - tcpdump port 23 - before telnet attempt.
 
Old 06-26-2008, 01:44 PM   #25
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,529

Rep: Reputation: 63
lkm01801 - we've already verify that telnet was running and responding - the data is there in the previous threads.

What we are trying to do now is find out why the telnetd is *closing the connection* already made. This is an access control issue, not a telnet not started issue.

jhilton - with telnet DISABLED in xinetd, try the following on a command line:

/usr/sbin/in.telnetd -D netdata -debug 9999

Does this startup telnet to where you can connect to telnet on another session as:

telnet localhost 9999

btw. don't use which as the definitive answer to where your commands might be - it only looks in your directories specified in your PATH, so commands that live in directories you normally won't have in your PATH won't be search (eg: in.telnetd). Use locate instead

locate telnetd
 
Old 06-26-2008, 02:02 PM   #26
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15
jlm01801 - start in.telnetd -D report does nothing as far as I can tell. in.telnetd -D start brings me right back to the console but there was no output.

in /etc/services telnet is listed as port 23.

This is the TCP dump I got from telneting, with it continuing for about 8 or so lines.
Code:
listening on eth0, link-type EN10MB (Ethernet), capture size 96 bytes
IP 10.128.9.63.32982 > 10.128.9.64.telnet : S 2502673302:2502673302(0) ack 2502673303 win 24820 <nop,nop,sackOK,mss 1460>
Mr. C - I just disabled telnet through xinetd and restarted xinetd again.

Yes, /usr/sbin/in.telnetd -D netdata -debug 9999 does start telnetd and it prompted me to the login screen! I just tried to login and it booted me off for not incorrect passwords... as well as a timeout.

Thanks for the advice on locate. Its one reason that I started this topic in the newbie forums as I am a newbie.
 
Old 06-26-2008, 02:09 PM   #27
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,529

Rep: Reputation: 63
Excellent - you're on your way to debugging. Ignore the timeouts and password requests. We don't need to actually log in yet, as we're debugging just the ability of a local vs. remote connection.

Now, keep that manually-started telnet running, and from one of your *remote* (Solaris) machines, attempt to telnet as you did locally:

telnet remote_ip_here 9999

You are trying to see what happens remotely vs. locally.
 
Old 06-26-2008, 02:13 PM   #28
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15
It took me into the login screen on the solaris machine upon telnet as it did when I tried to do it locally. with the same results of not trying to be able to login. It also timed out after I left it alone for awhile.

Last edited by jhilton; 06-26-2008 at 02:15 PM. Reason: Clarity.
 
Old 06-26-2008, 02:42 PM   #29
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,529

Rep: Reputation: 63
Are you saying "on the Solaris machine, when I ran the telnet to the remote linux machine at port 9999, you received no request for a password" (different that when you tried locally on the linux box?

All this confusion would be eliminated if you just showed exactly the commands you try and their output (copy / paste), and then add your commentary.
 
Old 06-26-2008, 02:47 PM   #30
jhilton
LQ Newbie
 
Registered: Jun 2008
Posts: 29

Original Poster
Rep: Reputation: 15
Oh woops sorry.

On the linux machine I did /usr/sbin/in.telnetd -D netdata -debug 9999

Then on the solaris machine I entered telnet *linux ip address* 9999

On the solaris machine was able to connect to the linux machine through telnet and I was prompted for a username and a password.

The Linux machine closed the connection after being idle for a short time.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
telnet - connection closed by foreign host rbumann Linux - General 11 01-05-2012 08:43 AM
SSH issue ""Server unexpectedly closed network connection" Errsta_Fonzarelli Linux - Software 12 05-24-2010 02:35 PM
Telnet error "Connection closed by foreign host" without prompting login. jhilton Linux - Newbie 1 06-25-2008 06:36 PM
outlook users having "your imap server has closed the connection" problems fedora_user Linux - Server 16 12-17-2007 04:43 AM
FTP problem "connection closed by remote host" with RHEL4 and Windows 2003 hooijack Linux - Enterprise 0 03-23-2006 09:29 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 09:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration