Copy Folder From Ssh To Local Code Example


Example 1: scp folder from server to local


scp -r user@your.server.example.com:/path/to/foo /home/user/Desktop/

Example 2: ssh copy folder from local to remote


scp -ra /path/to/local/storage user@remote.host:/path/to/copy

Example 3: how to copy directory to a ssh server


# Copy from machine a to b
scp -r /path/to/directory user@ipaddress:/path/to/destination

# Copy from machine b to a
scp -r user@ipaddress:/path/to/destination /path/to/directory

Example 4: copy from remote to local


scp file.txt remote_username@10.10.0.2:/remote/directory

Example 5: ssh copy folder from local to remote


scp -r -P xxxx /path/of/your/local/folder username@hostname:/path/to/remote/server/folder

Example 6: ssh copy folder from local to remote


scp -P xxxx username@hostname:/path/of/remote/server/filename /path/to/local/destination/folder

Comments

Popular posts from this blog

Converting A String To Int In Groovy

"Cannot Create Cache Directory /home//.composer/cache/repo/https---packagist.org/, Or Directory Is Not Writable. Proceeding Without Cache"

Android How Can I Convert A String To A Editable