Solved

transferring directory from one unix server to another unix server?

Posted on 2006-07-20
8
398 Views
Last Modified: 2010-04-21
I would like to transfer directory "TestApp" from unix server "A" to Unix server "B". Can you please tell me how I can do this via command line?

Please let me know if you have any questions.Thanks
0
Comment
Question by:g46905
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 
LVL 6

Accepted Solution

by:
bira earned 500 total points
ID: 17146998
if you have scp , from server A you run:
scp -r TestApp serverB:/path

0
 

Author Comment

by:g46905
ID: 17147031
what is scp?
0
 
LVL 6

Expert Comment

by:bira
ID: 17147070
    scp - secure copy (remote file copy program)

SYNOPSIS
     scp [-1246BCpqrv] [-c cipher] [-F ssh_config] [-i identity_file]
         [-l limit] [-o ssh_option] [-P port] [-S program]
         [[user@]host1:]file1 [...] [[user@]host2:]file2

DESCRIPTION
     scp copies files between hosts on a network.  It uses ssh(1) for data
     transfer, and uses the same authentication and provides the same security
     as ssh(1).  Unlike rcp(1), scp will ask for passwords or passphrases if
     they are needed for authentication.

     Any file name may contain a host and user specification to indicate that
     the file is to be copied to/from that host.  Copies between two remote
     hosts are permitted.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:g46905
ID: 17147110

> scp -r TestApp serverB:/path

dont we need to specify the user Id and password of the remote server?
0
 
LVL 6

Expert Comment

by:bira
ID: 17147181
it will ask you for the user/passwd
run it as root

what kind of unix you have ?
0
 

Author Comment

by:g46905
ID: 17147192
sun solaris...

> run it as root

I am not familiar. can you provide an example?

Thanks,
0
 
LVL 6

Expert Comment

by:bira
ID: 17147236
to run it as root you normally should be the system
administrator.
but if you are not the administrator, you can run the
scp command with your own account, since you known
the password of the user/passwd at the remote host.

0
 
LVL 6

Expert Comment

by:JJSmith
ID: 17148673

If you are using Sun Solaris it may be worth looking up 'rdist' is is by far an elegant method of moving files between servers - should the need to do so, be a frequent requirement.

Cheers
JJ.
0

Featured Post

What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question