Operating System - HP-UX
1819974 Members
3378 Online
109607 Solutions
New Discussion юеВ

Address resolution problem

 
Joe Haines
Occasional Contributor

Address resolution problem

When trying to remote login from my HPUX server to an HPUX server on another domain, the remote server is asking for a password. I have (as far as I know) setup the ~/.rhosts file on the remote server properly. Here is the scenario.

The names have been changed to protect the innocent...

Local server
IP = 146.11.11.11
Hostname = myserver.mydomain.com

Remote server
IP = 146.22.22.22
Hostname = remserver.remdomain.com

I have added all of the followint to the remote .rhosts file

146.11.11.11
myserver
myserver.mydomain.com

When I try to remote login to - it asks for a password (which I give).

When I enter the "who -a" command, I fond that the remote server resolves my server as

cc011011.corpdomain.com

where 011011 are the last 2 fields of my IP address and corpdomain.com is our corporate domain.

Any ideas?

Thank you

Joe
6 REPLIES 6
Patrick Wallek
Honored Contributor

Re: Address resolution problem

Are you using DNS? If so, what do you get if you do an 'nslookup 146.11.11.11'? What does the name resolv as? On the remote server, in what order are host names looked up (check /etc/nsswitch.conf)? If files is listed first, then try putting an entry in the remote servers /etc/hosts for myserver. You could also try adding an alias to your DNS so that cc011011.cordomain.com also resolves to myserver.mydomain.com.

G. Vrijhoeven
Honored Contributor

Re: Address resolution problem

Hi Joe,

Cam you give us the nslookup output from source server ( myserver )on the traget server ( remserver).

1.Can there be aliases configured in DNS.
2. Is /etc/hosts wrong
3. /etc/nsswitch.conf hosts line ( DNS files ?)
4. /etc/resolv.conf search or domain string?

Gideon
Sridhar Bhaskarla
Honored Contributor

Re: Address resolution problem

Hi Joe,

If you simply say "nslookup 146.11.11.11" on that server, it should print out the information from where it is picking up the hostname like

Using /etc/hosts on: blablabla

looking up FILES <---
Trying DNS <---
Name: cc011011.corpdomain.com
Address: 146.11.11.11

The above output is dependent on what you have in /etc/nsswitch.conf. You can find out if the DNS server is returing the above address.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Rita C Workman
Honored Contributor

Re: Address resolution problem

My .rhosts files are simple....IP and login.

Server B .rhosts file example:

111.222.333.444 rworkman

Since I'm on server A logged in as rworkman I can now rlogin to Server B.

On both servers follow the advise above to ensure you can nslookup properly both servers from both servers.
Then make sure there is nothing stopping you like inetd.sec refusing rlogin ... or some firewall issue saying that subnet ~333.x can not access subnet ~xxx.x (serverA).

Just a thought,
Rita
Joe Haines
Occasional Contributor

Re: Address resolution problem

All of our IP addresses begin 146.47. The last 2 fields of the IP address are
assigned at the local site. Our corporate DNS policy is to resolve and 146.47
address to ccXXXYYY.corpdomain.com if it doesn't resolve to something else
first.

We are using DNS. Our DNS servers are Windows boxes (I don't know what
type). Our HPUX config consists of only the resolv.conf and nsswitch.conf
files. Our files look like the following...

resolv.conf
search mydomain.com remdomain.com corpdomain.com
nameserver 146.47.XXX.YYY
nameserver 146.47.XXX.ZZZ

nsswitch.conf
hosts: files [...] DNS [...]

We include only local workstations/servers in our /etc/hosts file, so DNS
should resolve any remote addresses.

When I do a nslookup on my local server, everything works as expected.

When I do a nslookup on the remote server, I get the following ...


nslookup myserver
*** Can't find server name for address 146.47.XXX.YYY: Non-existent domain
*** Can't find server name for address 146.47.XXX.ZZZ: Non-existent domain
*** Default servers are not available
Using /etc/hosts on: remserver

looking up FILES
Trying DNS
*** can't find myserver: No response from server


These ARE the correct DNS server IP's

From my server, if I do a nslookup 146.47.XXX.YYY, I receive
ccXXXYYY.corpdomain.com. If I do a nslookup remdns.remdomain.com, I
receive the correct 146.47.XXX.YYY address. Is it that the DNS server
(remdns) cannot reverse lookup its own IP?

Strange the "who -a" will resolve the IP to cc######.corpdomain.com and
nslookup fails completely.

I am the admin for the local HPUX workstations (no access to DNS server admin).
I am in Pennsylvania.

The remote systems are in Brazil, where I have no admin authority, so it's
difficult for me to try a bunch of ideas.

My inetd.conf file in all locations has the "-s" option in the shell (remshd)
and login (rlogind) statements. Will removing the -s from the Brazil HPUX
servers help this?

Ultimately I would like the Brazil servers to respond with either
myserver.mydomain.com or 146.47.11.11. I do not want cc011011.corpdomain.com.


Thank you,

Joe

John Dvorchak
Honored Contributor

Re: Address resolution problem

When I have this problem the first thing I do is to telnet to the box instead of rlogin. Then I run who -mT to get the name that box thinks I am logging in from. That will tell you what it really thinks you name/IP address resolves to. Don't forget with a M$WindoZ as your DNS there is no guarantee that it does a proper reverse look up.
If it has wheels or a skirt, you can't afford it.