I'm writing a script to automatically transfer files between two different Linux servers. Every time I use the SCP command, it requires me to input a password. Is there anyway around this for an automated process?
            Asked
            
        
        
            Active
            
        
            Viewed 1,964 times
        
    0
            
            
        - 
                    Public key authentication. Also, consider using rsync. – Lev Levitsky Jun 23 '14 at 16:03
1 Answers
1
            
            
        As Lev Levitsky commented, SSH Public Key Authentication is what you need in order to get around being prompted for a password every time you use scp to copy a file. See http://www.thegeekstuff.com/2008/06/perform-ssh-and-scp-without-entering-password-on-openssh/ for an excellent step-by-step guide on how to setup SSH Public Key Authentication.
 
    
    
        mti2935
        
- 11,465
- 3
- 29
- 33
