Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

where to check yum installed logs and complete status

avatar
Guru

When we installed any components vi amabri then it run yum install command in the background and if components is big in size then it takes time.

2017-02-06 05:23:04,413 - Installing package ambari-metrics-hadoop-sink ('/usr/bin/yum -d 0 -e 0 -y install ambari-metrics-hadoop-sink')

So i want to know that is there any way where we can check how much % it is completed and how much is remaining like we get this status in command line tool.

p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Menlo}

[root@w1 ~]# yum install ambari-metrics-monitor

Loaded plugins: fastestmirror

Setting up Install Process

Loading mirror speeds from cached hostfile

* base: bay.uchicago.edu

* extras: mirrors.cmich.edu

* updates: mirrors.cmich.edu

Resolving Dependencies

p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Menlo} p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Menlo; min-height: 15.0px}

Dependencies Resolved

================================================================================================================================================================================

Package Arch Version Repository Size

================================================================================================================================================================================

Installing:

ambari-metrics-monitor x86_64 2.4.1.0-22 Updates-ambari-2.4.1.0 176 k

Installing for dependencies:

cloog-ppl x86_64 0.15.7-1.2.el6 base 93 k

cpp x86_64 4.4.7-17.el6 base 3.7 M

gcc x86_64 4.4.7-17.el6 base 10 M

mpfr x86_64 2.4.1-6.el6 base 157 k

ppl x86_64 0.10.2-11.el6 base 1.3 M

python-devel x86_64 2.6.6-66.el6_8 updates 173 k

Updating for dependencies:

libgcc x86_64 4.4.7-17.el6 base 103 k

libgomp x86_64 4.4.7-17.el6 base 134 k

python x86_64 2.6.6-66.el6_8 updates 76 k

python-libs x86_64 2.6.6-66.el6_8 updates 5.3 M

Transaction Summary

================================================================================================================================================================================

Install 7 Package(s)

Upgrade 4 Package(s)

Total size: 21 M

Total download size: 17 M

Is this ok [y/N]: y

Downloading Packages:

(1/8): gcc-4.4.7-17.el6.x86_64.rpm | 10 MB 00:05

(2/8): libgcc-4.4.7-17.el6.x86_64.rpm | 103 kB 00:02

(3/8): libgomp-4.4.7-17.el6.x86_64.rpm | 134 kB 00:03

(4/8): mpfr-2.4.1-6.el6.x86_64.rpm | 157 kB 00:04

http://bay.uchicago.edu/centos/6.8/os/x86_64/Packages/ppl-0.10.2-11.el6.x86_64.rpm: [Errno 12] Timeout on http://bay.uchicago.edu/centos/6.8/os/x86_64/Packages/ppl-0.10.2-11.el6.x86_64.rpm: (28, 'Operation too slow. Less than 1 bytes/sec transfered the last 30 seconds')

Trying other mirror.

(5/8): ppl-0.10.2-11.el6.x86_64.rpm | 1.3 MB 00:02

(6/8): python-2.6.6-66.el6_8.x86_64.rpm | 76 kB 00:03

(7/8): python-devel-2.6.6-66.el6_8.x86_64.rpm | 173 kB 00:02

(8/8): python-libs-2.6.6-66.el6_8.x86_64.rpm | 5.3 MB 00:36

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Total

1 ACCEPTED SOLUTION

avatar
Master Guru

@Saurabh

You can check /var/log/messages to see if installation has started.

Also if you want to check how much data has been downloaded, yum keeps package in yum cache while downloading, you can run 'du -sh' in watch command to check the status.

Example.

Before downloading package

[root@prodnode1 ~]# ls -lrt /var/cache/yum//x86_64/6/Updates-ambari-2.4.0.1/packages/
total 0

Download started

[root@prodnode1 ~]# /usr/bin/yum -d 0 -e 0 -y install ambari-metrics-hadoop-sink

Status of cache directory

[root@prodnode1 ~]# ls -lrt /var/cache/yum//x86_64/6/Updates-ambari-2.4.0.1/packages/
total 4552
-rw-r--r--. 1 root root 4660232 Aug 30 20:49 ambari-metrics-hadoop-sink-2.4.0.1-1.x86_64.rpm

After installation is complete, package gets removed from cached location.

You can run something like below to keep watch over download

[root@prodnode1 ~]# watch du -sh /var/cache/yum//x86_64/6/Updates-ambari-2.4.0.1/packages/ambari-metrics-hadoop-sink-2.4.0.1-1.x86_64.rpm

Hope this what you were looking for. Please do let us know if you have any further questions! 🙂

View solution in original post

3 REPLIES 3

avatar
Master Mentor

@Saurabh

"/var/log/yum.log" file can be checked to know if a package is installed properly or not. Although it won't show the percentage.

Example:

# cat /var/log/yum.log | grep ambari-metrics-monitor
Feb 06 10:38:35 Erased: ambari-metrics-monitor
Feb 06 10:39:36 Installed: ambari-metrics-monitor-2.4.2.0-136.x86_64

.

For little more DEBUG informations you might want to increase the "debuglevel" in the file "/etc/yum.conf".

debuglevel=value

Where value is an integer between 1 and 10. Setting a higher debuglevel value causes yum to display more detailed debugging output. debuglevel=0 disables debugging output, while debuglevel=2 is the default.

.

https://linux.die.net/man/5/yum.conf

.

avatar
Guru

I tried to tail the log but it was not updating.

avatar
Master Guru

@Saurabh

You can check /var/log/messages to see if installation has started.

Also if you want to check how much data has been downloaded, yum keeps package in yum cache while downloading, you can run 'du -sh' in watch command to check the status.

Example.

Before downloading package

[root@prodnode1 ~]# ls -lrt /var/cache/yum//x86_64/6/Updates-ambari-2.4.0.1/packages/
total 0

Download started

[root@prodnode1 ~]# /usr/bin/yum -d 0 -e 0 -y install ambari-metrics-hadoop-sink

Status of cache directory

[root@prodnode1 ~]# ls -lrt /var/cache/yum//x86_64/6/Updates-ambari-2.4.0.1/packages/
total 4552
-rw-r--r--. 1 root root 4660232 Aug 30 20:49 ambari-metrics-hadoop-sink-2.4.0.1-1.x86_64.rpm

After installation is complete, package gets removed from cached location.

You can run something like below to keep watch over download

[root@prodnode1 ~]# watch du -sh /var/cache/yum//x86_64/6/Updates-ambari-2.4.0.1/packages/ambari-metrics-hadoop-sink-2.4.0.1-1.x86_64.rpm

Hope this what you were looking for. Please do let us know if you have any further questions! 🙂