how to scp from remote machine to local machine code example
Example 1: scp local to remote
scp -i <private_key> ./file.txt remote_username@remote_ip:/remote/directory
Example 2: how to scp from remote machine to local machine
scp [email protected]:/path/to/file /path/to/store/file
scp [email protected]:/root/test.tar /home/tom/