In Linux, the rpm package is a management program that installs the required software on the host through database management; rpm is developed by Red Hat and is often used for installation, upgrade, uninstallation and query of software packages. Linux uses rpm to implement and manage the installation, viewing and deletion of software.
#The operating environment of this tutorial: linux7.3 system, Dell G3 computer.
What is the rpm package of Linux
RPM (RedHat Package Manager) is a management program that installs the required software on the host through database management.
Features of RPM package
1: Already compiled in advance
2: Easy to install
3: The environment is required to be consistent during the installation process
4:Reverse When installing, start from the top level
Naming rules for RPM packages
Example: bind-9.8.2-0.47.rc1.el6.x86_64.rpm
1.name , such as: bind, is the name of the software
2.version, such as: 9.8.2-0, is the version number of the software, the version number format is usually "major version number. minor version number. revision number" . 47, is the release version number, indicating how many times this rpm package was compiled
3.arch, such as i386, indicates the hardware platform for which the package is applicable. Currently, the platforms supported by rpm are: i386, i586 , i686, sparc and alpha
4..rpm and .src.rpm are the rpm package type suffixes, rpm is the compiled binary package, and .src.rpm is the source code package
5 .Special name:
(1) el*: indicates the publisher’s version, el6 indicates that this software package is used under rhel6.x/centos6.x;
(2) devel: Indicates that this rpm package is a software development package
(3)noarch: Indicates that such a software package can be installed and run on any platform and does not require a specific hardware platform
For example httpd-manual- 2.0.40-21.i386.rpm
httpd-manual ----- Package name
2 -----Main version number
0 -- --- Minor version number
40 ----- Minor version number
21 ----- Number of compilations
i386 ----- Suitable Platform
rpm ----- Description is an RPM package
Installation of RPM package
The installation of RPM package is very simple, just execute the following command:
rpm -ivh Software package name
Parameter description:
-i Installation
-v Display installation information
-h Display installation progress
The rpm command executes the installation of rpm packages and source packages. The rpm package ends with .rpm, and the source package ends with .src.rpm
Common RPM commands
-ivh 安装并显示安装进度(规则:rpm –ivh 包名) 示例:rpm –ivh bind-9.8.2-0.47.rc1.el6.x86_64.rpm -Uvh 升级软件包(rpm –Uvh 包名 //升级软件包-旧升新,低升高) 示例:rpm –Uvh --oldpackage bind-9.8.2-0.47.rc1.el6.x86_64.rpm(新版本软件包降级为旧版本) -ql 列出rpm软件包内的文件信息(显示已安装软件包内容) 示例:rpm –ql vsftpd (规则:rpm –ql 软件名) -qi 列出rpm软件包描述信息(显示已安装软件包属性) 示例:rpm –qi bind (规则:rpm –qi 软件名) -qf 查看指定文件属于哪个软件包(rpm –qf 文件名) 示例:rpm –qf /etc/rc.d/init.d/named -Va 校验所有rpm包,查找丢失的文件 -e 删除rpm软件包(rpm –e 包名) 示例:rpm –e bind-9.8.2-0.47.rc1.el6.x86_64.rpm -qpR 查看rpm包依赖关系 示例:rpm –qpR 包名 --force 忽略软件包及文件的冲突,即强制安装(长格式命令) --nodeps 忽略软件包的依赖关系(长格式命令) --test 安装测试,并不实际安装(长格式命令) 示例:测试--nodeps和--test,rpm –ivh httpd-2.2.15-53.el6.x86_64.rpm --test 并不安装,测试一下httpd软件包的依赖 rpm –qa
where
–a option is to query all installed software packages.
-q is to query whether a package is installed
(display difference: installed rpm packages will not display the suffix .rpm, while uninstalled packages will display the suffix .rpm)
Related recommendations: "Linux Video Tutorial"
The above is the detailed content of What is the rpm package of linux?. For more information, please follow other related articles on the PHP Chinese website!

Linux network configuration can be completed through the following steps: 1. Configure the network interface, use the ip command to temporarily set or edit the configuration file persistence settings. 2. Set up a static IP, suitable for devices that require a fixed IP. 3. Manage the firewall and use the iptables or firewalld tools to control network traffic.

Maintenance mode plays a key role in Linux system management, helping to repair, upgrade and configuration changes. 1. Enter maintenance mode. You can select it through the GRUB menu or use the command "sudosystemctlisolaterscue.target". 2. In maintenance mode, you can perform file system repair and system update operations. 3. Advanced usage includes tasks such as resetting the root password. 4. Common errors such as not being able to enter maintenance mode or mount the file system, can be fixed by checking the GRUB configuration and using the fsck command.

The timing and reasons for using Linux maintenance mode: 1) When the system starts up, 2) When performing major system updates or upgrades, 3) When performing file system maintenance. Maintenance mode provides a safe and controlled environment, ensuring operational safety and efficiency, reducing impact on users, and enhancing system security.

Indispensable commands in Linux include: 1.ls: list directory contents; 2.cd: change working directory; 3.mkdir: create a new directory; 4.rm: delete file or directory; 5.cp: copy file or directory; 6.mv: move or rename file or directory. These commands help users manage files and systems efficiently by interacting with the kernel.

In Linux, file and directory management uses ls, cd, mkdir, rm, cp, mv commands, and permission management uses chmod, chown, and chgrp commands. 1. File and directory management commands such as ls-l list detailed information, mkdir-p recursively create directories. 2. Permission management commands such as chmod755file set file permissions, chownuserfile changes file owner, and chgrpgroupfile changes file group. These commands are based on file system structure and user and group systems, and operate and control through system calls and metadata.

MaintenanceModeinLinuxisaspecialbootenvironmentforcriticalsystemmaintenancetasks.Itallowsadministratorstoperformtaskslikeresettingpasswords,repairingfilesystems,andrecoveringfrombootfailuresinaminimalenvironment.ToenterMaintenanceMode,interrupttheboo

The core components of Linux include kernel, file system, shell, user and kernel space, device drivers, and performance optimization and best practices. 1) The kernel is the core of the system, managing hardware, memory and processes. 2) The file system organizes data and supports multiple types such as ext4, Btrfs and XFS. 3) Shell is the command center for users to interact with the system and supports scripting. 4) Separate user space from kernel space to ensure system stability. 5) The device driver connects the hardware to the operating system. 6) Performance optimization includes tuning system configuration and following best practices.

The five basic components of the Linux system are: 1. Kernel, 2. System library, 3. System utilities, 4. Graphical user interface, 5. Applications. The kernel manages hardware resources, the system library provides precompiled functions, system utilities are used for system management, the GUI provides visual interaction, and applications use these components to implement functions.


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

ZendStudio 13.5.1 Mac
Powerful PHP integrated development environment

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

DVWA
Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

WebStorm Mac version
Useful JavaScript development tools

SublimeText3 Chinese version
Chinese version, very easy to use
