LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
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 11-16-2009, 04:47 AM   #1
Chaosbreaker
LQ Newbie
 
Registered: Nov 2009
Posts: 15

Rep: Reputation: 0
RCP - how to setup for Red Hat Linux and getting it to work with Linux/Windows


Hi

I've been trying to get rcp command to work for my development environment but to no avail.

I'm working on a Red Hat Linux server, and the rcp is meant to be used between Linux-Linux and Linux-Windows system.

I've done some reading up and this is what I found:-

Quote:
Step 01: Turn on RCP service on UNIX Host

Turn on the RCP service on unix machine by using inetd:

1. Log on as root.
2. Edit the file /etc/Inetd.conf.
3. Uncomment the lines that start with shell and that start with exec.
4. Save the file.
5. Use ps -ef |grep inetd and determine inetd service pid. Send the Host User Profile (HUP) signal to inetd by using kill or by using pkill.
6. Run inetd again.

To turn on the RCP service by using xinetd:

1. Log on as root.
2. Edit the file /etc/Xinetd.d/rsh. You may get another file based on your linux distrinution.
3. Change the line disable to no.
4. Save the file.
5. Use ps -ef |grep inetd and determine inetd service pid. Send the HUP signal to xinetd by using kill or by using pkill.
6. Run xinetd again.

Step 02: Set the security permissions
After turning on RCP services you must set the security permissions to allow the Windows host to connect to your computer.

1. Edit the file /etc/hosts.equiv. Based on your linux distribution this file may vary. You can get like /etc/hosts.allow.
2. In the file add a line that contains the name of your Windows host.
3. Add a second line that contains the name of your Windows host and the name of a user who can access the directory that you want to transfer. Separate the two elements with a tab character.
4. Save the file.
I noted that my Red Hat have xinetd BUT I don't have the rsh file in step (2). It says I may get another file but which file should I be looking for?

As for Step 02, I did find hosts.allow and updated that and the hosts file itself. Besides that, I also use useradd to add a user to match up with the one in the other system since I've read that the rcp required both end to use the same user name.

Still, I believe I may still be missing something out. Anyone have an idea?

P.S. I know some will post that rcp is old and scp is the way to go. I can't agree more. However, the project I'm working on requires rcp since some guy in the other team design everything using it for god knows why. So I'm stuck with it whether I like it or not.

Any advice/leads will be much appreciated. I'm still surfing around and fidgeting to try to get it to work in the mean time.

Thanks in advance.
 
Old 11-16-2009, 10:31 AM   #2
TB0ne
Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 15,105

Rep: Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719Reputation: 2719
Quote:
Originally Posted by Chaosbreaker View Post
Hi

I've been trying to get rcp command to work for my development environment but to no avail.

I'm working on a Red Hat Linux server, and the rcp is meant to be used between Linux-Linux and Linux-Windows system.

I've done some reading up and this is what I found:-



I noted that my Red Hat have xinetd BUT I don't have the rsh file in step (2). It says I may get another file but which file should I be looking for?

As for Step 02, I did find hosts.allow and updated that and the hosts file itself. Besides that, I also use useradd to add a user to match up with the one in the other system since I've read that the rcp required both end to use the same user name.

Still, I believe I may still be missing something out. Anyone have an idea?

P.S. I know some will post that rcp is old and scp is the way to go. I can't agree more. However, the project I'm working on requires rcp since some guy in the other team design everything using it for god knows why. So I'm stuck with it whether I like it or not.

Any advice/leads will be much appreciated. I'm still surfing around and fidgeting to try to get it to work in the mean time.

Thanks in advance.
Well, you don't say what version of RedHat linux (Enterprise? OLD RH?), but you can try (as root), typing in "yum install rsh". It's probably not installed, since it's old and insecure, but you CAN install it and get it going.

And as far as scp goes...I feel your pain, but I'd strongly argue with anyone at your company that goes against it. RCP/RSH is old and insecure, and designing things to work with it, rather than updating to make use of more current technology, is pointless. It may be the easy/lazy way to go for the other guy (probably because he can't figure out SSH ), but he needs to build a bridge and get over it.....
 
Old 11-16-2009, 06:29 PM   #3
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.6, Centos 5.10
Posts: 16,324

Rep: Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041
Agree with TB0ne, maybe try showing the 'designer' this http://www.informit.com/articles/art...p=169465&rll=1 or even better, show your mgr.
In any case, as asked, tell us exactly which versionof RH you've got eg

cat /etc/redhat-release

Note that RH has used xinetd instead of inetd for many yrs now.
http://www.linuxtopia.org/online_boo...pwrappers.html see 42.5.3 & ff

Last edited by chrism01; 11-17-2009 at 12:25 AM.
 
Old 11-16-2009, 09:27 PM   #4
Chaosbreaker
LQ Newbie
 
Registered: Nov 2009
Posts: 15

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by chrism01 View Post
Agree with TB0ne, maybe try showing the 'designer' this http://www.informit.com/articles/art...p=169465&rll=1 or even better, show your mgr.
In any case, as aksed, tell us exactly which versionof RH you've got eg

cat /etc/redhat-release

Note that RH has used xinetd instead of inetd for many yrs now.
http://www.linuxtopia.org/online_boo...pwrappers.html see 42.5.3 & ff
Unfortunately, when I got involved with the project, a lot of the interface documents had already been defined and baselined, so getting a change from rcp to scp is gonna take a loooooong process, and whether it happens or not is a different issue altogether.

Anyway, the Red Hat I'm using is version 5.2. As pointed out, xinetd is used instead of inetd.

I'm trying to do an rcp from the RHEL server to a Windows Vista workstation but keep getting connection refused. Trying to figure out why now.

Below are the updates I made. I also provide some info to help you guys have a clearer picture.

Workstation, Dell
=================
- Windows Vista
- 192.168.2.51
- User Accounts: RCP, DW

Server
======
- RHEL 5.2
- 192.168.2.7
- User Accounts: RCP, root

Noted that I created the RCP user account on both machine.
I also noted that the workstation do not have rcp/rsh... expected since its probably phased out. Because of this, I'm not sure now whether the rcp connection gets refused because Vista doesn't have it and therefore does not allow it?

I tried to copy the rcp file over but when I run a command, nothing happens.

I also updated the following files:-
(Note that I am able to ping between the two machines)

Workstation, Dell
=================
file: C:\Windows\System32\drivers\etc\hosts
192.168.2.7 LINUX

Server
======
file: /etc/hosts
192.168.2.51 WINDOWS

file: /etc/host.allow
rcpbind : 192.168.2.51/255.255.255.0 : allow
rcpbind : ALL : deny

In addition, I'm supposed to set the disable to no for rcp but in the /etc/xinetd.d/ folder, I don't see any rcp file. Do I create one?

Let me know if I'm doing anything wrong.
Thanks.
 
Old 11-19-2009, 04:37 PM   #5
stevec
LQ Newbie
 
Registered: Mar 2004
Location: Bloomington, IN
Posts: 21

Rep: Reputation: 15
I'm in this same boat--trying to set up rsh on a cluster of RHEL 5.4 servers. I have a program that's going to parallelize them over TCP via RSH for a distributed computing cluster. Obviously ssh is not an option because the overhead of encryption is going to slow down processing. These nodes will all be set up such that they are not accessible from any but the head node, which will not be accessible via rsh.

So since I have what I think is a relatively legitimate reason, any suggestions on how to best set this up? I'm reading a lot of conflicting documentation. It seems like I should be able to set up /etc/hosts.equiv and it should just go, but it's not. I'm getting the following:
Code:
[root@server1 ~]# rsh server2 pwd
connect to address 10.79.19.*** port 544: No route to host
Trying krb4 rsh...
connect to address 10.79.19.*** port 544: No route to host
trying normal rsh (/usr/bin/rsh)
server2: No route to host
[root@server1 ~]#
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
rcp on Red Hat Enterprise AS 3 JAdj Red Hat 3 01-18-2007 03:03 PM
GUI setup Red Hat Linux 9.0 sniperbooger Linux - Newbie 1 11-05-2005 02:13 PM
wireless card setup on red hat linux blitz Linux - Laptop and Netbook 3 08-07-2003 10:29 PM


All times are GMT -5. The time now is 06:14 PM.

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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration