"리눅스 압축파일 내부 파일목록 보기"의 두 판 사이의 차이

잔글 (봇: 자동으로 텍스트 교체 (-==참고 자료== +==참고==))
 
(같은 사용자의 중간 판 3개는 보이지 않습니다)
21번째 줄: 21번째 줄:


==실습==
==실습==
<source lang='dos'>
<source lang='console'>
[root@jmnote ~]# echo hello > hello.txt
[root@zetawiki ~]# echo hello > hello.txt
[root@jmnote ~]# echo world > world.txt
[root@zetawiki ~]# echo world > world.txt
[root@jmnote ~]# tar cvf temp.tar *.txt
[root@zetawiki ~]# tar cvf temp.tar *.txt
hello.txt
hello.txt
world.txt
world.txt
</source>
</source>
<source lang='dos'>
<source lang='console'>
[root@jmnote ~]# tar tvf temp.tar
[root@zetawiki ~]# tar tvf temp.tar
-rw-r--r-- root/root        6 2014-03-24 22:32:17 hello.txt
-rw-r--r-- root/root        6 2014-03-24 22:32:17 hello.txt
-rw-r--r-- root/root        6 2014-03-24 22:32:22 world.txt
-rw-r--r-- root/root        6 2014-03-24 22:32:22 world.txt
40번째 줄: 40번째 줄:
*[[bz2]]
*[[bz2]]


==참고 자료==
==참고==
*http://www.cyberciti.biz/faq/list-the-contents-of-a-tar-or-targz-file/
*http://www.cyberciti.biz/faq/list-the-contents-of-a-tar-or-targz-file/


[[분류: tar]]
[[분류: tar]]

2017년 7월 11일 (화) 04:21 기준 최신판

list the contents of a tar or tgz file
압축파일 내부 파일목록 보기
tar, tgz, bz2 내부 파일목록 보기

1 방법[ | ]

tar
Bash
Copy
tar tvf 파일명.tar
tgz
Bash
Copy
tar ztvf 파일명.tgz
tar ztvf 파일명.tar.gz
bz2
Bash
Copy
tar tvf 파일명.bz2

2 실습[ | ]

Console
Copy
[root@zetawiki ~]# echo hello > hello.txt
[root@zetawiki ~]# echo world > world.txt
[root@zetawiki ~]# tar cvf temp.tar *.txt
hello.txt
world.txt
Console
Copy
[root@zetawiki ~]# tar tvf temp.tar
-rw-r--r-- root/root         6 2014-03-24 22:32:17 hello.txt
-rw-r--r-- root/root         6 2014-03-24 22:32:22 world.txt

3 같이 보기[ | ]

4 참고[ | ]