LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-28-2010, 07:33 AM   #1
subbarai
LQ Newbie
 
Registered: Feb 2009
Posts: 2

Rep: Reputation: 0
Exclamation rsh and rlogin works but rcp doesn't work on my RHEL4 machine


hi,

I have installed RHEL4 on my desktop machine . Done all the setting in /etc/pam.d and finally my rsh and rlogin works from my machine(rsh the same machine)

[root@linux tmp]# rsh 10.121.113.92
Last login: Tue Sep 28 18:00:22 from BLE
You have new mail.
[root@linux ~]#


10.121.113.92 is the ip address of my linux(same) machine
but when I tried rcp ( in the same machine)

[root@linux tmp]# rcp /tmp/work 10.121.113.92:/home/
10.121.113.92: Connection refused
[root@linux tmp]#

my /root/.rhosts file ( with 644 permissions)
[root@linux tmp]# more /root/.rhosts
10.121.113.92 root


Can someone please help me with this.
Actually there is a script that use rcp and I need to use that as it is
 
Old 09-28-2010, 08:53 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
You really should move away from using r commands - the security for them is almost non-existent - almost anyone can pretend to be the host you're allowing in your .rhosts file. If you have a script rather than a binary that relies on these commands it would be very easy to convert from rsh/rlogin to ssh and from rcp to scp.

Of course you'll have to setup trusts to use ssh/scp but that isn't really difficult.

If you really want to use rcp have a look at the man page by typing "man rcp" - it tells you about authorization files needed.
 
Old 09-29-2010, 01:17 AM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,361

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Here's a good article http://www.informit.com/articles/art...p=169465&rll=1
 
Old 09-29-2010, 04:47 AM   #4
subbarai
LQ Newbie
 
Registered: Feb 2009
Posts: 2

Original Poster
Rep: Reputation: 0
thanks for the reply..

I have asked the developer to use SSH and SCP as of now.

Just want to know whether rcp needs ftp . in RHEL4 ftp does not come by default. I downladed the rpm , installed it and started the vsftd serverice.

I believe that rcp runs on port 514. Please let me know how to check whether my machine is listening on port 514 when i run rcp command.

I have disabled the iptables in my machine.
 
Old 09-29-2010, 04:59 AM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,361

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Try

netstat -tanp|more

as root
 
Old 09-29-2010, 08:18 AM   #6
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
Quote:
Originally Posted by subbarai View Post
Just want to know whether rcp needs ftp.
No - rcp and ftp use different protocols as does scp. You can have all 3 or any 2 or any 1 or none. rcp and ftp are very insecure so most Linux distros don't enable them by default but there is nothing preventing one from doing it. At least there has been some attempt to make ftp more secure with vsftp and rcp/rsh more secure with Kerberized versions but the best security is still obtained with ssh/scp.
 
  


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
Any deamon service for rlogin/rcp ust Linux - Newbie 1 09-12-2008 07:01 AM
rsh / rcp connection refused DotHQ Red Hat 3 09-07-2006 08:45 AM
Can't get rlogin, rsh to work in FC3 dangs Linux - Security 1 01-11-2005 11:45 AM
problem with rcp and rsh ! iamthewind Linux - Software 1 11-21-2003 03:03 AM
Linux - NT4 networking - RSH and RCP sijones Linux - Networking 1 06-09-2001 03:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:49 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