1833877 Members
2312 Online
110063 Solutions
New Discussion

telnet error

 
SOLVED
Go to solution
Ganesh Babu
Honored Contributor

telnet error

if i do a telnet

ex., telnet 80

from a Hp-UX box.. i get an error as "Parameter Not Set" why is it?? same thing runs from other hp-ux box.

Ganesh
19 REPLIES 19
Jeff Schussele
Honored Contributor

Re: telnet error

HI Ganesh,

Run the following on the system to which you were telneting

netstat -an | grep 80

Is there anything listening on port 80 like a webserver or something? I suspect you tried to telnet to a port in use & got that response from whatever was listening.

HTH,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
MarkSyder
Honored Contributor

Re: telnet error

What happens if you telnet to the ip address?

Mark Syder (like the drink but spelt different)
The triumph of evil requires only that good men do nothing
Ganesh Babu
Honored Contributor

Re: telnet error

Hi Jeff,
Yes there is a webserver running in the destination server on port 80. Also the same command works from other 2 machines..

Mark,
Same result for ip address also..

Ganesh
Steven E. Protter
Exalted Contributor

Re: telnet error

Okay,

The web server should be downing an error in the error_log file

if its apache that's the name.

It would appear to be web server configuration or permissions on the html doc. You should get a message like this.

Attaching a sample run.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Helen French
Honored Contributor

Re: telnet error

On the target system, run this command:

# cat /etc/services | grep telnet

Find out the port where telnet is running (default port is 23) and try again on that port number. As you said, port 80 is used by a web server.

# telnet system_name 23

OR

# telnet system_name
Life is a promise, fulfill it!
Ganesh Babu
Honored Contributor

Re: telnet error

Hi SEP,
This is a server which we don't own.. so we cannot see the log files.. the message attached were seen when i tried the same command from other machines which were working..

Wilson,
When i try it in the default port
telnet

i get the following error

Trying...
Unable to connect to a server: Error 0
telnet: Unable to connect to remote host: Error 0

Ganesh
Helen French
Honored Contributor

Re: telnet error

Did you find out which port telnet daemon is listening to? Find out the port number from /etc/services and do:

# netstat -an | grep port_number

If the daemon is not running, you won't be able to connect through telnet.

Are you able to connect to the same target system from other servers? If yes, check if any telnet restriction is set.
Life is a promise, fulfill it!
Ganesh Babu
Honored Contributor

Re: telnet error

hi Wilson,
Yes the telnet is running in port 23.. i was able to connect from other servers.. i am checking the permissions now..

Ganesh
Paul Cross_1
Respected Contributor

Re: telnet error

telnetd does not have to be running in order to telnet to a port not controlled by telnetd. telnet port 80 should work if:

-there is something listening on port 80
-there is no network magic to prevent you from doing so (firewall, etc.)
RAC_1
Honored Contributor

Re: telnet error

Do just telnet. On telnet prompt do toggle options and try to open connection.
open hostname/ip address.

Post results.

Anil
There is no substitute to HARDWORK
Ganesh Babu
Honored Contributor

Re: telnet error

Hi Anil,

$ telnet
_telnet[6]: 3: parameter not set

another server

$telnet
telnet> open
Trying...
Unable to connect to a server: Error 0
telnet: Unable to connect to remote host: Error 0

Ganesh
Kenneth Platz
Esteemed Contributor
Solution

Re: telnet error

Try using /usr/bin/telnet instead. It looks like the telnet you are using is actually a shell script which is in turn spitting the "Parameter not set" error.
I think, therefore I am... I think!
RAC_1
Honored Contributor

Re: telnet error

type telnet.

What it returns? It should return /usr/bin/telnet. Seems that it is some script through which you are running telnet.

Anil
There is no substitute to HARDWORK
Ganesh Babu
Honored Contributor

Re: telnet error

yes..

when i did

/usr/bin/telnet 80

i got the connection made and got the message from the webserver..

thanks Guys..

Now how will I change it like, if i run telnet it should user /usr/bin/telnet


Ganesh
Sridhar Bhaskarla
Honored Contributor

Re: telnet error

Hi Ganesh,

I have never seen this error while using telnet.

Do a 'which telnet' and compare the binary against another server. If this is really a binary, run it with 'tusc' and see if you get any hints.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Sridhar Bhaskarla
Honored Contributor

Re: telnet error

Wow!!.. as you can see I almost posted at the same time as your response.

-Sri

PS: no points for either posts.
You may be disappointed if you fail, but you are doomed if you don't try
Ganesh Babu
Honored Contributor

Re: telnet error

Hi All,
Thanks for all your inputs..

actually when i ran
$type telnet or
$which telnet

i got the path as
/opt/socks/bin/telnet

i think it is the socksified telnet and that is the reason it was not working..

Now how do i change this to /usr/bin/telnet??

Ganesh
RAC_1
Honored Contributor

Re: telnet error

echo $PATH.

Your /opt/socks/xxx path is first. Correct your path. put /usr/bin before /opt stuff

Anil
There is no substitute to HARDWORK
Ganesh Babu
Honored Contributor

Re: telnet error

Thanks Anil & all of the guys who had helped me out...

It worked.

Ganesh