File tree 1 file changed +22
-3
lines changed
1 file changed +22
-3
lines changed Original file line number Diff line number Diff line change 674
674
675
675
<table >
676
676
<tr >
677
- <td><a href="#a-mkdir ">ssh</a></td>
678
- <td><a href="#b-cd ">whoami</a></td>
679
- <td><a href="#c-pwd ">passwd</a></td>
677
+ <td><a href="#a-ssh ">ssh</a></td>
678
+ <td><a href="#b-whoami ">whoami</a></td>
679
+ <td><a href="#c-passwd ">passwd</a></td>
680
680
<td><a href="#d-quota">quota</a></td>
681
681
<td><a href="#e-date">date</a></td>
682
682
<td><a href="#f-cal">cal</a></td>
702
702
<td><a href="#v-whois">whois</a></td>
703
703
<td><a href="#w-dig">dig</a></td>
704
704
<td><a href="#x-wget">wget</a></td>
705
+ <td><a href="#y-scp">scp</a></td>
705
706
</tr >
706
707
</table >
707
708
@@ -824,6 +825,24 @@ wget file
824
825
```
825
826
826
827
828
+ ### y. ` scp `
829
+ Transfer files between a local host and a remote host or between two remote hosts.
830
+
831
+ * copy from local host to remote host*
832
+ ``` bash
833
+ scp source_file user@host:directory/target_file
834
+ ```
835
+ * copy from remote host to local host*
836
+ ``` bash
837
+ scp user@host:directory/source_file target_file
838
+ scp -r user@host:directory/source_folder farget_folder
839
+ ```
840
+ This command also accepts an option ` -P ` that can to used to connect to specific port.
841
+ ``` bash
842
+ scp -P port user@host:directory/source_file target_file
843
+ ```
844
+
845
+
827
846
# 2. Basic Shell Programming
828
847
829
848
You can’t perform that action at this time.
0 commit comments