VMware Smart Assurance SMARTS | Installer fails to detect OS Patch Levels and leads to Installation Failure
search cancel

VMware Smart Assurance SMARTS | Installer fails to detect OS Patch Levels and leads to Installation Failure

book

Article ID: 323798

calendar_today

Updated On:

Products

VMware

Issue/Introduction

This article is a reference to troubleshoot such issue where OS patch lookup fails by the installers and files that may help us drive through such issues.

Symptoms:

Smarts installers not getting installed with OS patch levels error with error like:
image.png


Where-as the following confirm the OS patch levels present on the server:
image.png


Environment

VMware Smart Assurance - SMARTS

Cause

In this case, we need to determine if this issue is caused by the commands run by the installer which fail resulting in the failure in the installation. 

The installer runs commands like the following for the OS Patch level lookup :

  • # /bin/rpm -q --queryformat %{NAME}-%{VERSION}-%{RELEASE}.%{ARCH} glibc |sed -n 1p| sed -e 's/'glibc-'/\n/g' | grep -i i686 | tr -d '\n'
  • # /bin/rpm -q --queryformat %{NAME}-%{VERSION}-%{RELEASE}.%{ARCH} glibc |sed -n 1p| sed -e 's/'glibc-'/\n/g' | grep -i x86_64| tr -d '\n'
  • # /bin/rpm -q --queryformat %{NAME}-%{VERSION}-%{RELEASE}.%{ARCH} glibc |sed -e 's/'glibc-'/\n/g'  | grep -i i686 | grep -Po '\d+\.*\d*'| sed -n 1p | tr -d '\n'
  • # /bin/rpm -q --queryformat %{NAME}-%{VERSION}-%{RELEASE}.%{ARCH} glibc |sed -e 's/'glibc-'/\n/g'  | grep -i x86_64 | grep -Po '\d+\.*\d*'| sed -n 1p | tr -d '\n'

These run in common for all the listed OS patch levels and the above is only for one such patch level (i.e., glibc i686 and x86_64 variants) These commands could be found under: install.dir.<PID>-/InstallerData/installer.zip/InstallScript.iap_xml

Based on the review on customer environment, we have seen the lookup failing with grep -P option with the following error:

# /bin/rpm -q --queryformat %{NAME}-%{VERSION}-%{RELEASE}.%{ARCH} glibc |sed -e 's/'glibc-'/\n/g'  | grep -i i686 | grep -Po '\d+\.*\d*'| sed -n 1p | tr -d '\n'
grep: this version of PCRE is compiled without UTF support

# /bin/rpm -q --queryformat %{NAME}-%{VERSION}-%{RELEASE}.%{ARCH} glibc |sed -e 's/'glibc-'/\n/g'  | grep -i x86_64 | grep -Po '\d+\.*\d*'| sed -n 1p | tr -d '\n'
grep: this version of PCRE is compiled without UTF support

The "P" flag interprets the patterns as Perl-compatible regular expressions (PCRE) which may not be working these servers leading to the issue.

Resolution

Smarts is working as designed and this is an issue on the Server side.
VMware Support recommends to engage the server administration team to ensure that these lookup queries work with grep commands.