Operating System - HP-UX
1833873 Members
1962 Online
110063 Solutions
New Discussion

Re: Unable to connect to remote host

 
SOLVED
Go to solution
Danny Crisp
Frequent Advisor

Unable to connect to remote host

I have configured a c3600 (HP-UX 11.11) to act as a NIS+ server now for reasons beyond me, telnet, remsh and ftp are all disallowed to the server.

I.E.

# telnet
Trying...
telnet: Unable to connect to remote host: Connection refused
20 REPLIES 20
A. Clay Stephenson
Acclaimed Contributor

Re: Unable to connect to remote host

First thing to check is if the services are actually running on the remote end. Take a look at /etc/inetd.conf and comfirm that the services are not commented out.
If it ain't broke, I can fix that.
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

Thanks for the swift response. I can confirm that telnet, ftp etc... are all un-commented.
Vijaya Kumar_3
Respected Contributor

Re: Unable to connect to remote host

Can you do you local connect in the same box?

telnet localhost
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
Alex Lavrov.
Honored Contributor

Re: Unable to connect to remote host

Btw, soon HP will stop maintain and support NIS+. Maybe it's a good idea not to use it, since it's not a big success anyway.

Alex.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

I can from the NIS+ server telnet etc... to any other host on the network. However, If i console log in on the NIS+ server and attempt a telnet to itself, I get the same telnet: Unable to connect to remote host: Connection refused message.

I.E.
# telnet 0
telnet: Unable to connect to remote host: Connection refused
Alex Lavrov.
Honored Contributor

Re: Unable to connect to remote host

is your "indetd" running?

netstat -in

Alex.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
Vijaya Kumar_3
Respected Contributor

Re: Unable to connect to remote host

that means telnet etc services are not running in NIS+ box. try to restart it.

1.
/etc/inetd -l
- Will reconfigure inetd daemon.

2.
Then, try to login to the same box again.

telnet locahost
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
Vijaya Kumar_3
Respected Contributor

Re: Unable to connect to remote host

In deed, Alex has a point. Try and check whether inetd running.
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

I ran inetd -l & telnet localhost, still the same error pursits. inetd is running: -

# netstat -in

Name Mtu Network Address Ipkts Ierrs Opkts Oerrs Coll
lan0 1500 10.30.28.0 10.30.28.142 813541138 0 292034286 0 0
lo0 4136 127.0.0.0 127.0.0.1 519 0 519 0 0
Vijaya Kumar_3
Respected Contributor

Re: Unable to connect to remote host

Very interesting.

1. Do you check the log files under /var. you need to check syslog and try to find where the system sends the errors to...

2. what is your content of /usr/adm/inetd.sec ? this is inetd security file.
Known is a drop, unknown is ocean - visit me at http://vijay.theunixplace.com
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

I dont have an inetd.sec file. It doesnt exist. Interestingly enough though, the syslog file does not list any inetd services being started!!

I.E.

Sep 16 19:30:04 mmsrv01 inetd[591]: Reading configuration
Sep 16 19:30:04 mmsrv01 inetd[591]: ftp/tcp: Added service, server /usr/lbin/ftpd
Sep 16 19:30:04 mmsrv01 inetd[591]: telnet/tcp: Added service, server /usr/lbin/telnetd
Sep 16 19:30:04 mmsrv01 inetd[591]: bootps/udp: Added service, server /usr/lbin/bootpd
Sep 16 19:30:04 mmsrv01 inetd[591]: login/tcp: Added service, server /usr/lbin/rlogind

There is no record that inetd even attempted to start else services.
Alex Lavrov.
Honored Contributor

Re: Unable to connect to remote host

Did you try to stop NIS+ server and check if you can telnet or not?

Alex.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

Yes. Once I had dropped NIS+. Normal service was resumed.
Alex Lavrov.
Honored Contributor

Re: Unable to connect to remote host

Please post here the content of your /etc/nsswitch.conf file.

Alex.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

I have tried a number of combinations and resorted to this most basic format.
A. Clay Stephenson
Acclaimed Contributor

Re: Unable to connect to remote host

Now that more data are available, I strongly suspect that you have a problem with your services table. Do a niscat of the services table. I suspect that is is empty or extremely abridged.
If it ain't broke, I can fix that.
Alex Lavrov.
Honored Contributor

Re: Unable to connect to remote host

What do you have in /etc/nsswitch.conf on "services" line?

try to modify it to:
"services: files"
or
"services: files nisplus"

It should work, since as Clay said, probably your services table is empty and your inetd is going to it.


Alex.
I don't give a damn for a man that can only spell a word one way. (M. Twain)
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

services table looks fine. I even removed the contents of the services table and re-populated using the /usr/newconfig/etc/services file.
Sheriff Andy
Trusted Contributor
Solution

Re: Unable to connect to remote host

I remember one time when I couldn't telnet in to my server. I ended up having to run insf -e at the command line. That reinitializes telnet.

Andy
Danny Crisp
Frequent Advisor

Re: Unable to connect to remote host

I have found a solution to this question