add
This commit is contained in:
parent
c2be9f777f
commit
b95e82e797
@ -239,7 +239,10 @@ shutdown -c #取消指定时间的关机或重启
|
||||
```
|
||||
ssh username@ip #远程登录服务器
|
||||
|
||||
ssh username@ip 'pwd' #连接服务器并执行命令将结果返回给本地
|
||||
|
||||
ssh -p 2222 username@ip #指定端口登录远程服务器
|
||||
|
||||
```
|
||||
|
||||
#### ping 命令
|
||||
|
27
wget-curl.md
27
wget-curl.md
@ -8,6 +8,19 @@ wget -O demo.html url #下载文件并改为指定名称
|
||||
wget -c url #断点续传
|
||||
|
||||
wget -i url url url #下载多个文件
|
||||
|
||||
wget -t 5 url #网络不好时重试 5 次
|
||||
|
||||
wget -t 0 url #不断重试
|
||||
|
||||
wget --limit-rate 20k url #限速下载
|
||||
|
||||
wget -Q 100m url #设置下载最大额度
|
||||
|
||||
wget --mirror --convert-links url #递归复制其他网站作为镜像,类似爬虫
|
||||
|
||||
wget --user username --password pass url #认证
|
||||
|
||||
```
|
||||
|
||||
补充:`wget` 命令适用于下载。
|
||||
@ -21,6 +34,20 @@ curl -o demo.html https://www.baidu.com/index.php #下载指定文件并重命
|
||||
|
||||
curl -v www.baidu.com #显示请求的过程信息
|
||||
|
||||
curl url --silent #不显示下载进度信息
|
||||
|
||||
curl url -o index.html --progress #显示下载进度信息
|
||||
|
||||
curl --referer Referer_URL target_URL #设置 referer
|
||||
|
||||
curl url --cookie "user=username;pass=password" #设置 cookie
|
||||
|
||||
curl url --user-agent "Mozilla/5.0 ..." #设置 User-Agent
|
||||
|
||||
curl url --limit-rate 20k #限速
|
||||
|
||||
curl url --max-filesize bytes #设置下载最大额度
|
||||
|
||||
curl -X GET www.baidu.com #指定请求方法,请求方法必须大写
|
||||
|
||||
curl -C url #断点续传,适用网络不顺畅时下载大文件,无须重新下载
|
||||
|
Loading…
x
Reference in New Issue
Block a user