"리눅스 curl"의 두 판 사이의 차이

잔글 (봇: 자동으로 텍스트 교체 (-<source lang='cli'> +<source lang='console'>))
18번째 줄: 18번째 줄:
The document has moved
The document has moved
<A HREF="http://www.google.com/">here</A>.
<A HREF="http://www.google.com/">here</A>.
</BODY></HTML>
</source>
<source lang='console'>
$ curl google.com
  % Total    % Received % Xferd  Average Speed  Time    Time    Time  Current
                                Dload  Upload  Total  Spent    Left  Speed
100  261  100  261    0    0  1673      0 --:--:-- --:--:-- --:--:--  2088<HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8">
<TITLE>302 Moved</TITLE></HEAD><BODY>
<H1>302 Moved</H1>
The document has moved
<A HREF="http://www.google.co.kr/?gfe_rd=cr&amp;ei=EqkMV9vmJuzC8gfO3b_oAg">here</A>.
</BODY></HTML>
</BODY></HTML>
</source>
</source>

2016년 4월 12일 (화) 16:52 판

1 개요

cURL, curl, libcurl
/usr/bin/curl
  • 원격서버(FTP, HTTP 등)에서 파일 받아 보여주는 도구[1]

2 설치 확인

[root@zetawiki ~]# rpm -qa curl
curl-7.19.7-26.el6_1.2.x86_64

3 실행예시 1: 기본

[root@zetawiki ~]# curl google.com
<HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8">
<TITLE>301 Moved</TITLE></HEAD><BODY>
<H1>301 Moved</H1>
The document has moved
<A HREF="http://www.google.com/">here</A>.
</BODY></HTML>
$ curl google.com
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   261  100   261    0     0   1673      0 --:--:-- --:--:-- --:--:--  2088<HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8">
<TITLE>302 Moved</TITLE></HEAD><BODY>
<H1>302 Moved</H1>
The document has moved
<A HREF="http://www.google.co.kr/?gfe_rd=cr&amp;ei=EqkMV9vmJuzC8gfO3b_oAg">here</A>.
</BODY></HTML>

4 실행예시 2: 정보 보기

[root@zetawiki ~]# curl -I google.com
HTTP/1.1 301 Moved Permanently
Location: http://www.google.com/
Content-Type: text/html; charset=UTF-8
Date: Sat, 06 Oct 2012 03:14:42 GMT
Expires: Mon, 05 Nov 2012 03:14:42 GMT
Cache-Control: public, max-age=2592000
Server: gws
Content-Length: 219
X-XSS-Protection: 1; mode=block
X-Frame-Options: SAMEORIGIN

5 같이 보기

6 주석

  1. A utility for getting files from remote servers (FTP, HTTP, and others)

7 참고 자료

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}