1834906 Members
2567 Online
110071 Solutions
New Discussion

Re: Rlogin problems

 
Mike_305
Super Advisor

Rlogin problems

Hi,

I have two SUN systems and I am trying to rlogin from one system to another system. I already checked the .rhosts file on second system and looks fine, has the correct entry. Every time I try to login it is asking for passwd. What I am missing.

Thanks in Advance.

Mike
If there is problem then don't think as problem, think as opportunity.
21 REPLIES 21
pap
Respected Contributor

Re: Rlogin problems

Hi ,

1. If you want to log on to Server A from B then put entry for Server B in /.rhosts file of A.

So, /.rhosts file for Server A will be like this

ServerB root

2. Check for following entry in /etc/indetd.conf file

login stream tcp nowait root /usr/lbin/rlogind rlogind

if it is commented, then make it uncommented.

Hope this will works for you.

Thanks,
-Piyush.
"Winners don't do different things , they do things differently"
S.K. Chan
Honored Contributor

Re: Rlogin problems

In the .rhosts file you can either put the fully qualified hostname or alias (short name). You need to first find out from nslookup what is the primary hostname it returns and use that exact hostname in your .rhosts file.

NOTTIN Emmanuel
New Member

Re: Rlogin problems

Hi,

could you also check the entry in the /etc/hosts.equiv file on each systems. There should be the same.

Hope this help,

Manx
SHABU KHAN
Trusted Contributor

Re: Rlogin problems

Hi,

host_a
host_b

If you want to login from host_a to host_b and not be prompted for a password, then the .rhosts file on host_b on the first line should read:

host_a.fully.qualified.hostname username

.rhosts file on host_b should have the fully qualified name of host_a space username (that you are logging in as)

Do you have these set up but still prompting for password ?

-Shabu

Anthony khan
Frequent Advisor

Re: Rlogin problems

Hi, If .rhosts is having a problem then you can create hosts.equiv file in /etc on remote host and add hostname username in hosts.equiv and also check nslookup.

Hope this will help
Mike_305
Super Advisor

Re: Rlogin problems

Hi,

Looked at the inetd.conf file and login entry is not commented. Any ideas.

Mike
If there is problem then don't think as problem, think as opportunity.
Uday_S_Ankolekar
Honored Contributor

Re: Rlogin problems

Try replacing hostnames with corresponding IP-Address .rhosts file.


-USA..
Good Luck..
Mark Ellzey
Valued Contributor

Re: Rlogin problems

You should also check the ownership of the .rhosts file. The file must be owned by the user trying to log in, and must be in that users $HOME directory.
Mike_305
Super Advisor

Re: Rlogin problems

Hi All,

Thanks for quick reply. I also want every one to know this is Sun systems.

I have looked in /.rhosts and I am using fully qualified name with user name.

We are using DNS and I nslookup is fine and still I can login without passwd.

Mike

If there is problem then don't think as problem, think as opportunity.
S.K. Chan
Honored Contributor

Re: Rlogin problems

SHABU KHAN
Trusted Contributor

Re: Rlogin problems


Hi Mike,

I tried it on my SUN SYSTEMS works for me...

Did you try putting in the IP address instead of the hostname as Uday mentioned...?

-Shabu
Darrell Allen
Honored Contributor

Re: Rlogin problems

Hi Mike,

Is .rhosts owned by the correct user? Perms set to 600?

Are you using rlogin -l loginid? The HPUX man page says that .rhosts are not used with the -l option unless the user is a superuser.

An easy way to verify what hostname / IP address to put in the .rhosts file:
rlogin (using the password)
tty
who -u (looking for your tty)
the last field in the who output for your tty is what needs to be in .rhosts

Darrell
"What, Me Worry?" - Alfred E. Neuman (Mad Magazine)
SHABU KHAN
Trusted Contributor

Re: Rlogin problems


Try logging in like this:


rlogin -l

-Shabu


Mike_305
Super Advisor

Re: Rlogin problems

Hi,

I have tried with IP address and still doesn't work. That's why I like HP and HP forms. I posted the question on Sun site and no luck. I have setup rlogin on many system and never ran into this kind of problems.

Thanks,

Mike
If there is problem then don't think as problem, think as opportunity.
Darrell Allen
Honored Contributor

Re: Rlogin problems

Is there a matching entry for the host and user from which you are logging in? hosts.equiv is checked first. Hopefully there is not a "negative" entry for your host and userid.

Is the remote account root? hosts.equiv doesn't apply for root. Only .rhosts.

Darrell
"What, Me Worry?" - Alfred E. Neuman (Mad Magazine)
SHABU KHAN
Trusted Contributor

Re: Rlogin problems

Hi Mike,

Let me tell you what I did on my sun systems:

hostA
hostB
USER1 on both systems

Logging in from hostA to hostB as USER1

hostB>cat ~USER1/.rhosts
hostA.qualified.host.name USER1

hostA>rlogin hostB.qualified.host.name -l USER1
Last login: Tue Mar 12 10:17:01 from hostA.qualified.host.name
Sun Microsystems Inc. SunOS 5.8 Generic February 2000
You have mail.
hostB>/export/home/USER1#333>


-Shabu
Darrell Allen
Honored Contributor

Re: Rlogin problems

Upon further reading of the Sun man page for rlogin, I don't see anything stating that root doesn't utilize hosts.equiv.

I can't test that (HPUX only here) and I don't remember whether that's true from my Solaris days.

Darrell
"What, Me Worry?" - Alfred E. Neuman (Mad Magazine)
Helen French
Honored Contributor

Re: Rlogin problems

Hi Mike,

Not sure about the Sun, but in HP there is a file /var/adm/inetd.sec for rlogin security. Check this file for any allow/deny.

HTH,
Shiju
Life is a promise, fulfill it!
pap
Respected Contributor

Re: Rlogin problems

Hi Mike,
Make sure that the .rhosts file you are edition on the remote server is in user's home directory. if it is root then /.rhosts
if other user then $USER HOME/.rhosts

One thing can be happen if the local user is not existing on remote machine.
"Winners don't do different things , they do things differently"
Mike_305
Super Advisor

Re: Rlogin problems

Hi,

Thanks for you help and quick response.

I am logging in as root. .rhosts entry is correct. I did verify using who -u command. Also, tried using IP address. No luck. I will see if I can get some answer from Sun support.

Thanks,

Mike
If there is problem then don't think as problem, think as opportunity.
Mike_305
Super Advisor

Re: Rlogin problems

Hi Guys,

Permission was not set correctly. Every thing was o.k.

Thanks,

Mike
If there is problem then don't think as problem, think as opportunity.