1833860 Members
2201 Online
110063 Solutions
New Discussion

Re: Remote copy

 
SOLVED
Go to solution
Abhijit P.
Valued Contributor

Remote copy

Hi all,

I have a Sun Server and other HP Servers.

I want to copy some data from Sun server to HP server now the directories which I have to copy contains lots of sudirectories and these also has its subdirectories.So I can';t to a ftp in this case could you please tell me whether its possible by rcp and if yes then how

Thanks in Advance

Abhi
7 REPLIES 7
Muthukumar_5
Honored Contributor

Re: Remote copy

If you do rcp from hp-server (destination) or from sun server (source). It will copy all sub directories in it.

Example:

rcp sunserver:/tmp/test/ /tmp/test/

hth.
Easy to suggest when don't know about the problem!
Suraj Singh_1
Trusted Contributor

Re: Remote copy

Hi Abhijit,

You can use either rcp or scp.

1. Syntax for rcp:
from Sun server:
# rcp /path_to_data hp_server:/

2. Syntax for scp, from Sun Server:
# scp /path_to_data username@hp_server:/

Regards
What we cannot speak about we must pass over in silence.
Gopi Sekar
Honored Contributor

Re: Remote copy



use scp for secure copy, for this you need to have ssh server running on either source or destination machine.

eg: scp -r source/directory user@remotemachine:/destination/directory

use rcp otherwise.
eg: rcp -r source/directory user@remotemachine:/destination/directory

Regards,
Gopi
Never Never Never Giveup
Abhijit P.
Valued Contributor

Re: Remote copy

hi all,
thanks for your earlier replies but when I am doing

rcp -r sourcedir user@hpserver dest dir.
it is giving error

remshd: Login incorrect.

regards,
Abhi
Bharat Katkar
Honored Contributor
Solution

Re: Remote copy

Hi Abhi,
You need to set .rhosts file on both the servers. It is not allowinf to login.
See man .rhosts.

If you are not concerned about security and this servers are on private network then you can just do:

# echo + + > /.rhosts

On both the server.

Hope that helps.
Regards,
You need to know a lot to actually know how little you know
Muthukumar_5
Honored Contributor

Re: Remote copy

You have to setup /etc/hosts.equiv and .rhosts files setup on both machines to allow them.


in hp-ux machine:

/etc/hosts.equiv
sunserver root

i hope u r using root account on both machines.

sun machine:
/etc/hosts.equiv
hpserver root

If this backup is for one time then use scp -r option with this and give password.

Easy to suggest when don't know about the problem!
Abhijit P.
Valued Contributor

Re: Remote copy

Thank you all for quick reply.

Regards,
Abhijit