Linux入门:常用命令:curl用法【等待后续添加】
来源:互联网 发布:ubuntu Server安装教程 编辑:程序博客网 时间:2024/04/29 12:14
可下载文件地址(url)http://mirrors.163.com/centos/6/centosplus/x86_64/Packages/kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpm
$ pwd/root
以下是curl的常用命令
curl -O url【-o与-O简单解释就是下载文件】
-O/–remote-name Write output to a file named as the remote file
–remote-name-all Use the remote file name for all URLs
$ curl -O http://mirrors.163.com/centos/6/centosplus/x86_64/Packages/kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpm $ ll-rw-r--r--. 1 root root 34185112 Jul 28 15:54 kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpm
curl -o url
-o/–output Write output to instead of stdout
–pass Pass phrase for the private key (SSL/SSH)
–post301 Do not switch to GET after following a 301 redirect (H)
–post302 Do not switch to GET after following a 302 redirect (H)
$ curl -o test.rpm http://mirrors.163.com/centos/6/centosplus/x86_64/Packages/kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpm $ ll-rw-r--r--. 1 root root 34185112 Jul 28 15:54 test.rpm
curl -I url
-I/–head Show document info only
[root@localhost ~]# curl -I http://mirrors.163.com/centos/6/centosplus/x86_64/Packages/kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpmHTTP/1.1 200 OKServer: nginxDate: Thu, 28 Jul 2016 08:02:32 GMTContent-Type: application/x-redhat-package-managerContent-Length: 34185112Connection: keep-aliveLast-Modified: Wed, 01 Jun 2016 03:52:10 GMTETag: "574e5bea-2099f98"Accept-Ranges: bytes
下载文件还可以使得wget
[root@localhost ~]# wget http://mirrors.163.com/centos/6/centosplus/x86_64/Packages/kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpm--2016-07-28 16:05:52-- http://mirrors.163.com/centos/6/centosplus/x86_64/Packages/kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpmResolving mirrors.163.com... 123.58.173.185, 123.58.173.186Connecting to mirrors.163.com|123.58.173.185|:80... connected.HTTP request sent, awaiting response... 200 OKLength: 34185112 (33M) [application/x-redhat-package-manager]Saving to: “kernel-2.6.32-642.1.1.el6.centos.plus.x86_64.rpm.1”18% [============> ] 6,472,720 603K/s eta 44s
【等待后续添加】
0 0
- Linux入门:常用命令:curl用法【等待后续添加】
- linux入门知识(待后续添加)
- Linux常用命令-curl
- linux curl用法详解
- linux curl 用法详解
- Linux命令CURL用法
- Linux命令CURL用法
- Linux命令CURL用法
- linux curl命令用法总结
- Linux 常用命令 之 http请求命令 curl
- Django入门:使用技巧【后续会一直添加】
- curl常用命令
- CURL常用命令
- CURL常用命令
- CURL常用命令
- CURL常用命令
- curl常用命令
- CURL常用命令
- 10009---【项目管理和构建】——Maven下载、安装和配置(二)
- PM 创建设备 函数 EQUIPMENT_SAVE
- Android5.0 CollapsingToolbarLayout 基本使用
- POJ 1562 Oil Deposits(DFS,八连通,连通分量)
- shared_ptr
- Linux入门:常用命令:curl用法【等待后续添加】
- 【library "libmaliinstr.so" not found】解决办法
- iOS-UI分析利器--Reveal安装破解以及简单使用
- ScrollView中嵌套ListView或GridView,只显示一行
- 计算几何的学习
- 线程-模拟死锁问题
- HDU1159最长公共子序列
- MDI 父亲窗体遍历子窗体
- 高性能ORM数据访问组件Deft,比dapper快20%以上