Linux RPM and YUM instruction usage notes

RPM instruction module

1. View rpm

1. Query all installed rpm packages

rpm -qa

Demo
Insert picture description here
2. Query software package information

rpm -qi package name

Demo
Insert picture description here
3. Query the files in the software package

rpm -ql package name

Demo
Insert picture description here

4. Query the package to which the file belongs

rpm -qf file full path name

Demo
Insert picture description here

Two, uninstall RPM

rpm -e RPM package name

Demo

删除firefox

Insert picture description here

Three, install the RPM package

rpm -ivh RPM package full path name

Demo

安装firefox

Insert picture description here

YUM module

One, query

1. Check whether the yum server has software that needs to be installed

yum list | grep xx
yum search xxx

Solve the "Cannot find a valid baseurl for repo: base" link

Demo
Insert picture description hereInsert picture description here

2. Download and install

yum install The full name of the software to be downloaded and installed

Demo
Insert picture description here

Guess you like

Origin blog.csdn.net/magicproblem/article/details/111477418