下载

[root@localhost ~]# curl -O http://mirrors.example.com/abc.tar.gz

登录验证并下载

[root@localhost ~]# curl -u username:password -O http://mirrors.example.com/abc.tar.gz

下载并重命名文件名称

[root@localhost ~]# curl -o 123.tgz http://mirrors.example.com/abc.tar.gz

断点续传下载(-C -)

[root@localhost ~]# curl -C - -O http://mirrors.example.com/abc.tar.gz

限速下载(默认单位B/s)

[root@localhost ~]# curl --limit-rate 128k -O http://mirrors.example.com/abc.tar.gz

请求头信息

[root@localhost ~]# curl -I 192.168.2.95:8080

HTTP/1.1 200 OK

Server: Apache-Coyote/1.1

Content-Type: text/html;charset=ISO-8859-1

Transfer-Encoding: chunked

Date: Tue, 14 Jun 2016 02:26:26 GMT

[root@localhost ~]#

Logo

更多推荐