Linux installation using the compression tool 7-zip steps

  
                

7zip is an open source compression software that can be used for file extraction. It can only be used on Windows systems. Although it can be used in Linux systems, it is more troublesome to install. The following small series will introduce you to Linux installation and Use the 7zip method.

Here's how to install 7zip (or p7zip) in Linux.

Installing 7zip on Debian, Ubuntu or Linux Mint systems

There are three 7zip packages available on the Debian-based publishing system.

p7zip: Contains 7zr (the smallest 7zip archive tool) and can only handle native 7z formats.

p7zip-full: Contains 7z and supports 7z, LZMA2, XZ, ZIP, CAB, GZIP, BZIP2, ARJ, TAR, CPIO, RPM, ISO and DEB formats.

p7zip-rar: Contains a plugin that extracts RAR files.

It is recommended to install the p7zip-full package (not p7zip), as this is the most complete 7zip package that supports many archive formats. In addition, if you want to process RAR files, you also need to install the p7zip-rar package. The reason for making a standalone plugin package is because RAR is a proprietary format.

Let Ubuntu 12.10 support RAR and 7Z file decompression http://www.linuxidc.com/Linux/2012-11/74223.htm

$ sudo apt-get install p7zip-full P7zip-rar

Installing 7zip on Fedora or CentOS/RHEL systems

Two 7zip packages are available on Red Hat-based publishing systems.

p7zip: Contains the 7za command, which supports 7z, ZIP, GZIP, CAB, ARJ, BZIP2, TAR, CPIO, RPM, and DEB formats.

p7zip-plugins: Contains the 7z command, an additional plugin that extends the 7za command (for example, supports ISO format extraction).

On the CentOS/RHEL system, you need to make sure the EPEL repository is available before running the following command, but no additional libraries are required on the Fedora system.

$ sudo yum install p7zip p7zip-plugins

Note that unlike the Debian-based publishing system, the Red Hat-based publishing system does not provide a RAR plugin, so you cannot use the 7z command. Extract the extracted RAR file.

Creating or extracting archives using 7z

Once the 7zip software is installed, you can use the 7z command to package and unpack a wide variety of archives. The 7z command uses different plugins to assist in processing archives of the corresponding format.

Use & ldquo; a & rdquo; option you can create an archive file, it can create 7z XZ, GZIP, TAR, ZIP and BZIP2 file, these types of formats. If the specified archive already exists, it will "add" the file to the existing archive instead of overwriting the original archive.

$ 7z a "archive-filename" "list-of-files"

Use the “e” option to extract an archive file, and the extracted files will be placed in the current directory. The format supported by the extraction is much larger than the format supported at the time of creation, including 7z, XZ, GZIP, TAR, ZIP, BZIP2, LZMA2, CAB, ARJ, CPIO, RPM, ISO, and DEB.

$ 7z e "archive-filename"

Another way to unpack is to use the “x” option. Unlike the “e” option, it uses the full path to extract the archived content.

$ 7z xarchive-filename

To see a list of archived files, use the “l” option.

$ 7z l archive-filename

To update or delete archives, use the “u” and “d” options respectively.

$ 7z u "archive-filename" "list-of-files-to-update"

$ 7z d "archive-filename" "list-of-files-to-delete"

To test the integrity of the archive, use:

$ 7z t "archive-filename"

The above describes the method of using the 7zip compression tool for each Linux installation. 7zip can also be installed on Ubuntu and CentOS systems. File extraction requires 7zip commands.

Copyright © Windows knowledge All Rights Reserved