2018-04-27 "Bird Brother's Linux private cuisine Basic Study (Fourth Edition)" chapter 22nd software Installation rpm, SRPM and Yum notes

Source: Internet
Author: User
Tags rpmbuild

There are two most common ways to install Linux software:
DPKG: This mechanism was first developed by the Debian Linux community, and through the dpkg mechanism, Debian provides software that can be installed simply and provide post-installation software information, which is very good. As long as other Linux distributions that derive from Debian use the dpkg mechanism to manage software, including b2d, Ubuntu, and so on.
? RPM: This mechanism was originally developed by the Red Hat Company, which was very useful, so many distributions use this mechanism as a way to manage software installations. Well-known developers, including Fedora, CentOS, SuSE and so on, are using this.

Distribution on behalf of the Software management mechanism using the instruction online upgrade mechanism (Directive)
Debian/ubuntu DPKG DPKG APT (apt-get)
Red hat/fedora rpm, Rpmbuild yum (yum)

RPM full name is "RedHat package Manager". RPM Extension: xxx.rpm
RPM is a wrapper file that compiles the software you want to install and then packs it into the RPM mechanism. Through the packaged software in the default database records, the software must be installed in order to record the dependency property software. When you install on your Linux host, RPM will first follow the data in the software to query the dependencies of the Linux host software is satisfied, if satisfied to install, if not satisfied will not install. During installation, the information of the software is written to the RPM database for future query, verification and anti-installation.
RPM File Installation Requirements:
1. The installation environment of the software files must be consistent or equivalent to the environmental requirements at the time of packaging;
2. Need to meet the software dependency property requirements;
3. Anti-installation requires special care, the lowest software can not be removed first, otherwise it may cause the whole system problems.

The meaning of the rpm file name, for example rp-pppoe-3.11-5.el7.x86_64.rpm:
Rp-pppoe-3.11-5. el7.x86_64. rpm
Software name software release number of times the appropriate hardware platform extension

Advantages of RPM:
? RPM contains compiled programs and configuration files and other data, can let users exempt from the problem of recompilation;
? RPM before being installed, will check the system's hard disk capacity, operating system version, etc., can avoid the wrong installation of files;
? The RPM file itself provides information such as software version information, dependent property software name, software use description, and the software contains documents to facilitate the understanding of the software;
? The RPM management method uses the database to record the relevant parameters of the RPM file for easy upgrade, removal, query and verification.

Disadvantages of RPM:
? Since the RPM file is compiled and packaged, the parameter profile cannot be modified, so the software file can only be installed in the original default hardware and operating system version.
? Some software is relevant, if the RPM software installation, but can not find its related precursor software, it will not be installed at this time.

SRPM the meaning of Source RPM. The RPM file contains the original code. The SRPM filename extension format is ***.src.rpm.
srpm file: You can recompile the RPM file that will fit our Linux environment by modifying the parameter configuration file within the srpm.
Installation of the srpm file:
? First the software is compiled in RPM management, at this time SRPM will be compiled into RPM files;
? Then install the completed RPM file into the Linux system





/root/rpmbuild/:
Specs This directory is placed in the software configuration files, such as the software's information parameters, settings items, etc. are placed here;
Suorces in this directory are the original files (*.tar.gz files) of the software and the config file.
Build in the process of compiling, some of the temporary data will be placed in this directory;
After the RPMs has been compiled, and the successful compilation succeeds, the packaged files are placed in this directory. It contains x86_64, Noarch .... And so on the secondary directory.
Srpms is similar to the RPMS, here is the SRPM package file! Sometimes when you want to release your software in a SRPM way, your SRPM file is placed in this directory.

Crontab

Correct:
Find the actual path to the file: Find/mnt-name ' pam-devel* '
There are pretty good search commands under Linux! Usually find is not very common! Because of the slow speed, but also the hard drive! Generally we are first to use Whereis or locate to check, if really can not find, just to find to search Yo! Why? Because Whereis only look for files under certain directories in the system, locate is using a database to search for filenames, of course, the two are quite fast, and there is no actual search of the file system state of the hard disk, compared to save time!

2018-04-27 "Bird Brother's Linux private cuisine Basic Study (Fourth Edition)" chapter 22nd software Installation rpm, SRPM and Yum notes

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.