Skip to content
View in the app

A better way to browse. Learn more.

hosang I.T.

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

scp

SCP Linux Command – How to SSH File Transfer from Remote to Local

SCP Syntax

scp [OPTIONS] [[user@]src_host:]file1 [[user@]dest_host:]file2
  • scp - It initializes the command and ensures a secure shell is in place.
  • OPTIONS - They grant different permissions depending on how they have been used. Some of the most common options include:
  • P(Caps) - specifies the port to establish connection with the remote host.
  • p(lowercase) - preserves the times-tamp for ease of modification and access.
  • r - copies the entire directory recursively
  • q - copies files quietly, doesn't display the progress messages. Also known as quiet mode.
  • C - for compression of data during transmission.
  • To understand more about OPTIONS read scp options
  • src_host - where the file is hosted. The source can either be a client or server depending on the origin of the file.
  • dest_host - where the file will be copied to.

Examples

Copy File from Local Host to Remote Host

scp test.txt user@destination:/location

Copy all files ending in php to Remote Host

scp *.php user@destination:/~/
  • *.php - copies all the files with the .php extension in the currently specified folder.
  • /~/ - means copy them to the home directory.

Copy a file with one name but save it on remote host with a different filename

scp -P 8080 test.txt user@destination:/user/home/test2.txt

 

Copy Files from Remote Host to Local Host

scp <remote_username>@<IPorHost>:<PathToFile> <LocalFileLocation>

Copy File test2.txt from Remote Host to Local Host

scp user@remotehost:test2.txt .

Copy Files from Remote Host to another Remote Host

scp [email protected]:/files/test.txt [email protected]:/files

Copy Multiple Files

scp file1 file2 ... user@<ip_address_of_user>: Destination

So SCP is a very powerful tool when needing to move files around between systems over the network

User Feedback

Recommended Comments

There are no comments to display.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Add a comment...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.