Linux software installation management

Package classification (the script installation package is written by experts for novices and loses customization)
source package
Binary package (RPM package, system default package)
 
source of rpm package
The rpm package is in the system CD
 
rpm package naming rules
httpd-2.2.15-15.el6centos.1.i686.rpm
Package name-software version-software release times-suitable linux platform-suitable hardware platform-rpm package extension
 
rpm package dependencies
tree dependencies
circular dependency
Module dependency (library file dependency) solution query website: www.rpmfind.net to find the package where the library file is located
 
Full name of package: use the full name of the package when the operating package is a package that is not installed, and pay attention to the path
Package name: I use the package name when I have installed packages, which is to search the database in /var/lib/rpm.
 
RPM install
rpm -ivh package full name
install
verbose show details
hash shows progress
--nodeps do not detect dependencies
 
yum is actually an online installation method for rpm packages
 
RPM package upgrade
rpm -Uvh package full name
-U(upgrade)
 
RPM package uninstall
rpm -e package name
erase uninstall
 
rpm package query
Check if it is installed
rpm -q package name
rpm -qa (query all installed packages)
rpm -qa | grep httpd (regular expression) to query all related packages
 
Query package details
rpm -qi package name
-i information Query software information
 
Query information about rpm packages that are not installed (the information is generated before installation)
rpm -qip package full name
-p package Query information about packages not installed
 
Query package file installation location
rpm -ql package name
-l list list
 
Query the installation location of the rpm package file that is not installed
rpm -qlp package full name
 
 
The default installation location of the rpm package
/etc/config file installation directory
/usr/bin/executable command installation directory
/usr/lib/The location where the function library used by the program is saved
/usr/share/doc/basic software manual save location
/usr/share/man/help file save location
 
Query which rpm package the system file belongs to
rpm -qf system filename
-f Query which package (file) the system file belongs to
Manually created filenames or system-created temporary filenames will not work. The file must be created through the rpm package to be queried
 
Query package dependencies (too many queries, not commonly used in practice)
rpm -qR package name
-R Query package dependencies (requires)
rpm -qRp package full name
 
 
RPM package verification
rpm -V installed package name
-V Verify the files in the specified RPM package
(To determine whether the file has been manipulated by others)
The specific contents of the eight pieces of information in the verification content are as follows:
Whether the size of the S file has changed (size)
M file type or file permissions are changed mold)
5 Whether the md5 check of the file has changed, that is, whether the content has changed
Whether the master-slave code of the D device has changed (device)
Whether the L file path has changed (load)
Has the owner of the U file changed?
Whether the group of the G file has changed
Whether the modification time of the T file has changed
 
file type
c configuration file (config)
d Ordinary documentation (documentation)
g ghost file (ghost)
LAuthorization document (license)
r description file (read me)
 
 
RPM package file extraction
rpm2cpio package full name | cpio -idv . file absolute path
 
-rpm2cpio
Command to convert rpm package to cpio format (2 is to)
-cpio
is a standard tool for creating software archives and extracting files from archives
 
cpio options < [file|device] options:
-i copy-in mode, restore
-d Automatically create a new directory when restoring
-v show restore process
 
 
 
 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325104747&siteId=291194637