Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am using scp to copy a file from remote server to local and it is working as expected.

scp remote_server.com:/data/ar_uw2a_vol_0286036c_2012-04-24-05-35-00 . 

I have 2 questions:

1) Since I am copying file from production server, I do not want to affect the performance if scp takes time. Does this operation affect the performance of remote server?

2) Is there any better / faster way to copy a file? The file is already going to be different (name based on current date and time)

share|improve this question
    
scp has a limit option to limit the bandwidth used. It also winds up limiting the CPU and disk usage too, but you can use nice/ionice and whatever other tools your platform offers to minimize its impact. –  David Schwartz Apr 24 '12 at 5:49
3  
Everything affects performance. You need to be more specific as to what you're concerned about... –  voretaq7 Apr 24 '12 at 5:55
1  
@voretaq7 You scared me for a second. Thought you were going to launch into a prescription drug advertisement. –  Wesley Apr 24 '12 at 5:58
    
You can use rsync if u want to speed up the transfer. –  Alan Kuras Apr 24 '12 at 5:59
    
@WesleyDavid Drugs are my anti-drug. –  voretaq7 Apr 24 '12 at 6:04

1 Answer 1

up vote 4 down vote accepted

Since I am copying file from production server, I do not want to affect the performance if scp takes time. Does this operation affect the performance of remote server?

Define "performance." If we're talking CPU performance, then SCP is going to cost you the price of encrypting with 128-bit AES (I believe that's the default for SSH2, but can't find a reference right now).

If you're talking bandwidth performance, then it will cost you the overhead of your encryption algorithm and strength.

If you're talking throughput performance, then you'll have to rate limit to your needs using either limit in SCP (as David Schwartz mentions in his comment above) or an different tool like perhaps pv.

Is there any better / faster way to copy a file? The file is already going to be different (name based on current date and time)

Define "better" and "faster". Define them very carefully. If you're saturating your CPU (very unlikely) there are different options than if you are saturating your bandwidth. Both involve rate limiting, however, and are fairly straightforward.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.