Methods for installing. RPM,. Tar,. tar.gz and tar.bz2 files in Linux

Source: Internet
Author: User
Tags bz2 pack advantage linux

I take the following three packages as an example: (Three packages are under/etc/opt)

A. example-1.2.3-1.rpm

B. Example-1.2.3-1.tar

C. example-1.2.3-1.tar.gz

1. Install RPM Package

Speaking of the RPM (REDHAT Package Management) standard software package, you may recall that the famous REDHAT company, it is the RPM package distribution, the installation of Linux software is simple. If the user wants to install the software released by RPM, simply type the command "Rpm-ivh xxx". RPM "can be. For example, users want to install OpenOffice. Org-1. 0. 1. RPM software package, just type in the command "Rpm-ivh OpenOffice." Org-1. 0. 1. RPM "can be. Another advantage of the RPM package distribution is that it is easy to remove the installed RPM packages as long as the "Rpm-e OpenOffice" is used. Org-1. 0. 1 "command will be able to install the OpenOffice just now." Org-1. 0. 1. The RPM is safely permanently removed from the hard drive. If you are installing/removing software in a x-window environment, then there is a better way, if you are using KDE, you can use KDE's own KPackage program to add or remove software, if you are using GNOME, you can use the GNORPM program to manage the software. Both programs are similar to the "Add/Remove Programs" feature in Microsoft Windows. The RPM software package is the easiest to install and manage, and it is recommended that you use this mode to manage your software later.

Installation method: Rpm-ivh example-1.2.3-1.rpm

View installation directory: RPM-QL example-1.2.3-1

Uninstall: Rpm-e example-1.2.3-1

2. Install the TAR pack

Installation method:

(1) Decompression tar bag: tar-xvf Example-1.2.3-1.tar

(2) into the unpacked directory: CD example-1.2.3-1

(3) to be executed sequentially:

[Root@jmwang example-1.2.3-1]#./configure (Some versions do not have this command, you can skip this step)

[Root@jmwang example-1.2.3-1]# make

[Root@jmwang example-1.2.3-1]# make install

[Root@jmwang example-1.2.3-1]# make clear (not required)

[Root@jmwang example-1.2.3-1]# make distclear (not required)

This completes the installation of the TAR pack.

3. Install tar.gz (TGZ) package

This column more highlights: http://www.bianceng.cnhttp://www.bianceng.cn/OS/Linux/

Software packages with tar.gz extensions are packaged in a tar program and are compressed with the GZIP program. To install this package, you need to extract the package first, using the TAR-ZXFV filename. Tar GZ "Can extract the package, extract the file in filename-named directory. Entering the directory, you can see the extracted files. Various software have different installation methods, but generally after each package uncompressed have install and Readme files, help file will have detailed installation instructions. To Tar. GZ (or TGZ) package release software has a disadvantage, is generally without automatic reverse installation program, if you need to have installed such programs to delete, you have to carefully look at the installation path and file name in Makefile, these for beginners have some difficulty.

Installation method:

(1) Decompression tar.gz bag: tar-zxvf example-1.2.3-1.tar.gz

(2) The following method is the same as the Example-1.2.3-1.tar package

4. Install TAR.BZ2 Package

Packages with tar.bz2 extensions are packages packaged with a tar program and compressed with a bzip2 program. Its advantage is that the compression rate is very high, need to use "BUNZIP2 filename.tar.bz2" for decompression. But the same drawback with the tar.gz package is that it is very cumbersome to remove. There are two methods of installing.

Installation method One:

(1) Unpack the TAR.BZ2 package first, execute BUNZIP2 example-1.2.3-1.tar.bz2 command to extract the tar packets.

(2) The following method is the same as the Example-1.2.3-1.tar package

Installation Method Two: (recommended)

(1) Perform TAR-JXVF Example-1.2.3-1.tar command decompression.

(2) The following method is the same as the Example-1.2.3-1.tar package

The two parameters of the Ps:tar command are explained:

-Z: Do you have gzip properties at the same time? Is that the need to use gzip compression?

-j: Do you have bzip2 properties at the same time? That is to use bzip2 compression?

Related Article

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.