cancel
Showing results for 
Search instead for 
Did you mean: 

rcp command

SOLVED
Go to solution
fergani
Advisor

rcp command

I have two servers:-
The first one is called : server11.
The second one is called : server12.
I need to copy a file which is called : Faimos
form server11 to server12 with ALL
its SUB DIRECTORIES.
How can I write this command to do that?
bye.
6 REPLIES
Steven Schweda
Honored Contributor

Re: rcp command

> I have two servers:-

sizer -v

I'd probably use a "tar" pipeline. A Forum
(or Web) search for keywords like:
tar pipeline
should find many examples. If NFS is not
available between these systems, then you
might add "rsh" or "ssh" to your search.
Rob Leadbeater
Honored Contributor

Re: rcp command

Hi,

On server11,

# rcp -r //Faimos server12:/

Where and are the source and destination paths.

# man rcp

will give some more examples.

Regards,

Rob

fergani
Advisor

Re: rcp command

Hi,
I tried to copy directory (eset)with all sub directory form server11 to server12
I tried the following command :-
#rcp -r eset server12:/all_folders
but gives the following error:-
Permission denied.
what is the problem?
bye.
Rob Leadbeater
Honored Contributor

Re: rcp command

Hi,

> Permission denied

Looks self explanatory to me...

Check that the user you're copying as has write permission on the destination folder.

You might also want to check that a simple rsh command works... ie

# rsh server12 ls -l

Cheers,
Rob
fergani
Advisor

Re: rcp command

Hi Rob
the output of the following command:
# rsh server12 ls -l
Permission denied.
Cheers,
Rob
Rob Leadbeater
Honored Contributor
Solution

Re: rcp command

OK, check the contents of the file /.rhosts on server12.

That should contain a line with server11 at the start.

Cheers,
Rob