Concise Linux Command Line notes: Bzip2

Source: Internet
Author: User
ArticleDirectory
    • Parameters
    • Option
    • Example
    • Tips

Compressing and extracting files Bzip2 [Options] [File-list]

Bunzip2 [Options] [File-list]

Bzcat [Options] [File-list]

Bzip2recover [File]

 

Bzip2ProgramUsed to compress files. bunzip2 is used to restore Bzip2 compressed files. bzcat is used to display Bzip2 compressed files. bzip2recover is used to repair files damaged during Bzip2 compression.

 

Parameters

File-listList of path names of one or more files to be compressed/decompressed

 

Option

-C: Write the compressed or decompressed results to the standard output.

-D: Decompress the file compressed with Bzip2. This option is used for Bzip2-D, which is equivalent to bunzip2.

-F force compression to overwrite existing files

-K the input file is not deleted when the file is compressed or decompressed.

-Q: suppress warning information, but display key information

-T to verify the integrity of the compressed file. If the file is complete, no information is displayed.

-V displays the process information during compression or decompression.

 

Example Bzip2
 
Siu @ darling ~ /Work $LsA B CDirSiu @ darling~ /Work $Bzip2Asiu @ darling~ /Work $LsA.bz2 B CDir

Compressed file

Bzip2-V
Siu @ darling ~ /Work $Bzip2-V B:1.123:1,7.121Bits/Byte,10.99% Saved,182 In,162Out. Siu @ darling~ /Work $LsA.bz2 B .bz2 CDir

Compress the file and display the compressed information

 

Bzcat
Siu @ darling ~ /Work $BzcatA.bz2 picture perfect memories scattered all around the floorreachingForThe phone'Cause I can'T fight it anymoreand I wonderIfI ever cross your mindfor me It Happens allTime

Show compressed file content

Bunzip2
 
Siu @ darling ~ /Work $Bunzip2A.bz2 Siu @ darling~ /Work $LsA B .bz2 CDir

Decompress the file

 

Bunzip2-K
 
Siu @ darling ~ /Work $Bunzip2-K B .bz2 Siu @ darling~ /Work $LsA B B .bz2 CDir

Decompress the file and keep the original file.

 

Tips

Bzip2 program compression efficiency is better than Gzip

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.