Ensure yum cache is ready before update
To workaround yum bug with libnss we need to make yum cache before running update. In fact we should have done this regardless of the bug. Change-Id: I5b2355fb8abe3c8d4b9ce9c62b9ffdba8c1e8d9d Resolves: rhbz#1458841 Closes-Bug: #1703830 (cherry picked from commit1a544f66a5
) (cherry picked from commit7d5929f5ba
)
This commit is contained in:
parent
058b8559a2
commit
5b3c4dffbe
|
@ -301,6 +301,8 @@ function systemctl_swift {
|
|||
# Special-case OVS for https://bugs.launchpad.net/tripleo/+bug/1635205
|
||||
# Update condition and add --notriggerun for +bug/1669714
|
||||
function special_case_ovs_upgrade_if_needed {
|
||||
# Always ensure yum has full cache
|
||||
yum makecache || echo "Yum makecache failed. This can cause failure later on."
|
||||
if rpm -qa | grep "^openvswitch-2.5.0-14" || rpm -q --scripts openvswitch | awk '/postuninstall/,/*/' | grep "systemctl.*try-restart" ; then
|
||||
echo "Manual upgrade of openvswitch - ovs-2.5.0-14 or restart in postun detected"
|
||||
rm -rf OVS_UPGRADE
|
||||
|
|
|
@ -44,6 +44,9 @@ fi
|
|||
|
||||
command_arguments=${command_arguments:-}
|
||||
|
||||
# Always ensure yum has full cache
|
||||
yum makecache || echo "Yum makecache failed. This can cause failure later on."
|
||||
|
||||
# yum check-update exits 100 if updates are available
|
||||
set +e
|
||||
check_update=$(yum check-update 2>&1)
|
||||
|
|
Loading…
Reference in New Issue