- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- How to transfer files from one server to another s...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 08:16 AM
04-25-2004 08:16 AM
Thanks.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 08:24 AM
04-25-2004 08:24 AM
SolutionIf it is a one time job, you could use remote copy ( rcp or find/cpio ). These are not the most secure commands.
add the ip address in the /.rhosts file
ipaddress root
# find /source | cpio -ov | remsh other_server | " cd /copy ; cpio -idvum "
# rcp -p /source other_server:/copy/
Hope this helps,
Robert-Jan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 08:27 AM
04-25-2004 08:27 AM
Re: How to transfer files from one server to another server without taking backup and then restore ?
http://www.software.hp.com/portal/swdepot/displayProductInfo.do?productNumber=T1471AA
Robert-Jan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 08:34 AM
04-25-2004 08:34 AM
Re: How to transfer files from one server to another server without taking backup and then restore ?
Thanks for the info.
I have few doubts.
I want to copy data from 'A' server to 'B' server. Now tell me how to use .rhosts file in this case ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 08:42 AM
04-25-2004 08:42 AM
Re: How to transfer files from one server to another server without taking backup and then restore ?
One drawback to using rcp is that not all ownerships, groups, and permissions are retained even with the -p option.
You might consider creating a "tarball".
e.g
On host A:
cd to desired directory:
tar cvf /mydir/myfile.tar .
Next FTP or FTP myfile.tar to Host B:
then cd to desired directory
tar xvf /mydir/myfile.tar
The "tarball" or "cpioball" method will preserve all metadata.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 11:03 AM
04-25-2004 11:03 AM
Re: How to transfer files from one server to another server without taking backup and then restore ?
2.rcp to ServerB
3.untar on serverB (Command is tar-xvf ... do man tar for detail)
You car put a small script into cron and it will run automatically as per your need. Using tar,you will not lose file permissions and attributes.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 03:23 PM
04-25-2004 03:23 PM
Re: How to transfer files from one server to another server without taking backup and then restore ?
You need to make the systems as trusted by adding entries in .rhosts file. Then you can take the backup and restore by the following comand.
#cd /Localdirectory
# tar cvf - .| remsh remotesvr "(cd /remotedirectory ; tar xvf - )"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 04:19 PM
04-25-2004 04:19 PM
Re: How to transfer files from one server to another server without taking backup and then restore ?
As everybody said use .rhost file to create trusted relationship between servers.
1. In server A login as root and create file .rhosts in home directory of root. file will looks like.
serverB root
same way create .rhosts file in server B root user's home directory
serverA root
after this use rcp command to transfer files.
#rcp -r /var serverb:/var
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 06:10 PM
04-25-2004 06:10 PM
Re: How to transfer files from one server to another server without taking backup and then restore ?
Another tool you might look at for what you want is rsync. It will only copy files that are not yet on the destination server, or have changed on the source server. It is in most cases a lot more efficient than copying the whole tree if you want both servers to be in sync. rsync can use ssh or rsh, so the .rhosts issues still exist. But with the explanation given so far that is not a problem. (Make sure the server you connect to can resolve the hostname from the IP address of the other server, otherwise the .rhosts won't work. And the permissions on the .rhosts file are important: 400 is the best mode: readable by the owner only).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2004 07:35 PM
04-25-2004 07:35 PM
Re: How to transfer files from one server to another server without taking backup and then restore ?
Login as root on Server A
cd $DIRECTORY
tar cvf - . |remsh "(cd $REMOTE_DIRECTORY; tar xvf -)"
Regds,
Kaps
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-26-2004 01:27 AM
04-26-2004 01:27 AM
Re: How to transfer files from one server to another server without taking backup and then restore ?
rdist - remote file distribution program
I use that for DR reasons, run nightly from cron:
# Copy myadm across to the DR site.
05 01 * * * /app/admin/drp/update-binaries.sh
# cat /app/admin/drp/update-binaries.sh
#! /bin/sh
# Keep the DRP copy of the vgpadm up-to-date.
# Currently the files are in:
#
# /home/vgpadm
#
# See the rdist(1M) distfile for a list of exclusions.
DRPDIR=/app/admin/drp
DRPHOST=server32
mount | grep /home > /dev/null 2>&1
if [ $? -eq 0 ]
then
( su - myadm -c "rdist -f $DRPDIR/distfile myadm"; ) 2>&1 |\
tee $DRPDIR/drp.log 2>&1 |\
mailx -s "VGPADM DRP rdist output" gwild@mydomain.com
fi
# cat distfile
MYDR = ( server32 )
#
# File systems to be copied over to the DR host.
# Don't use -R in install - so as not to remove files on destination host
MYADM = /home/myadm
myadm: ( ${MYADM} ) -> ( ${MYDR} )
install -w ;
except ${MYADM}/logfiles;
man rdist for mor information....
Rgds...Geoff