YUM Flashcards

1
Q

Only check for available list of updates

A

yum check-update
then,
yum update httpd

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Search online repos with updates to upgrade packages with yum

A

yum update

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Get info about specific package with yum

A

yum info httpd

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Display all packages installed by yum

A

yum list installed | grep httpd

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Clean yum cache info and its local db file

A

yum clean all

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Install/remove/reinstall app with yum

A

yum -y install httpd
yum remove httpd
yum reinstall httpd
yum localinstall htop

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Remove package and it dependencies with yum

A

yum autoremove httpd

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Find with yum what package provides a specified file name

A

yum whatprovides */htpd

yum provides /var/www => httpd -the basic dir for Apache HTTP server

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Download a package with yum

A

yum install yum-utils

yumdownloader htop

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Yum global conf file
Yum’s repositories
Yum cash location of latest requests

A

/etc/yum.conf
/etc/yum.repos.d/
/var/cache/yum

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Rpm DB location

A

/var/lib/rpm

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Repair corrupted rpm db

A

rpm –rebuilddb

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

List files in rpm package

List files in app

A

rpm -qpl htop.2.2.0.rpm

rpm -ql htop

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Display info on rpm package

A

rpm -qpi htop.2.2.0.rpm

the info as yum info htop would provide

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

List all rpm packages installed on a system

A

rpm -qa | grep htop

the same as yum list installed would provide

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Uninstall rpm package

A

rpm -e htop

17
Q

Verify installed rpm packages

A

rpm -Va

18
Q

Query if rpm package is installed

A

rpm -q htop

19
Q

List conf files of rpm package
List doc files of rpm package
Show info about package the file belongs to

A

rpm -qc sysstat
rpm -qd sysstat
rpm -qf /etc/request-key.conf =>keyutils.1.5-10

20
Q

Install rpm package

A

rpm -ivh htop.2.2.0.rpm

21
Q

RHEL8 app stream and modules

A

App streams are to separate user space apps from kernel operations
BaseOs repo is for base packages
App stream delivered in 2 formats:
-rpms
-modules
Modules can contain multiple streams to make multiple versions of apps available
Modules can have profiles. Profile- list of packages to a specific use-case (min, recommended, complete installation etc)

22
Q

Show module list

A

yum module list

23
Q

Search the module that provides httpd package

A

yum module provides httpd

24
Q

Get more info about module

A

yum module info php

25
Q

Show profiles of a module

A

yum module info –profile php

26
Q

Show list of streams for a module

A

yum module list php

27
Q

Install module with yum module

A
yum module install php:7.1
\_\_\_\_\_\_\_\_\_\_\_\_\_\_
yum module install php:7.2. This will disable 7.1. steram and 7.2 will be enabled
28
Q

Install specific profile of the module

A

yum module install php:7.1/devel

29
Q

Enable specific module

A

yum module enable php:7.1

30
Q

List all yum groups including hidden groups

List all yum groups installed

A

yum groups list hidden

yum groups list installed

31
Q

Get info about a specific yum group

A

yum groups info “Network File System Client”

32
Q

Install specific yum group

A

yum groups install “Network File System Client”

33
Q

Show yum commands history

A

yum history

yum history info id

34
Q

Undo a command from yum history

A

yum history undo 3 (id)

id can be got by yum history