Skip to content

Commit

Permalink
Updated pattern to detect running yum/dnf processes more reliably
Browse files Browse the repository at this point in the history
  • Loading branch information
sven-borkert committed Sep 1, 2022
1 parent 26e93ce commit 58d06d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion agents/plugins/yum
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ echo "<<<yum>>>"
if [ "$YUM_CURRENT" != "$YUM_CACHED" ] || [ ! -s $CACHE_RESULT_CHECK ]
then
count=0
while [ -n "$(pgrep -f "python /usr/bin/yum")" ]; do
while [ -n "$(pgrep -f "python (/usr|)/bin/(yum|dnf)")" ]; do
if [ $count -eq 3 ]; then
echo "Tried to run yum for 30 secs but another yum instance was running"
exit 2
Expand Down

0 comments on commit 58d06d5

Please sign in to comment.