3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

scp, wget,curlの違い

Posted at

使用可能プロトコル

       Protocol            Recursive Symlink
==============================================================
scp    ssh                 o         
wget   ftp,http            o
curl   ftp,http,sftp,scp   x
rsync  ssh                 o         NotFollow

scpはrecursive可能

scp -r -p  user@host://etc/*  /.../ToDdir

ftpはhomedirを起点とするので、任意のディレクトリをコピーするコツ

絶対パスは、homedir起点

ユーザのhome-dirを起点にftpするので、ディレクトリがあわない

curl --user USER:PASS ftp://formhost/Fromdir
wget --ftp-user=USER --ftp-password=PASS ftp://fromhost/Fromdir

home-dirから無理やり相対パス指定する

ユーザのhome-dirを起点にftpするので、相対指定する。

wget --ftp-user=USER --ftp-password=PASS ftp://fromhost/../../etc/hosts
curl --user USER:PASS ftp://fromhost/../../etc/hosts
3
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?