diff --git a/SPECS/numpy.spec b/SPECS/numpy.spec
index 38902d3..3e4a343 100644
--- a/SPECS/numpy.spec
+++ b/SPECS/numpy.spec
@@ -8,7 +8,7 @@
 
 Name:           numpy
 Version:        1.17.3
-Release:        5%{?dist}
+Release:        6%{?dist}
 Summary:        A fast multidimensional array facility for Python
 
 # Everything is BSD except for class SafeEval in numpy/lib/utils.py which is Python
@@ -79,6 +79,8 @@ Requires:       python%{python3_pkgversion}-devel
 Provides:       python%{python3_pkgversion}-f2py = %{version}-%{release}
 %{?python_provide:%python_provide python%{python3_pkgversion}-numpy-f2py}
 
+# Require alternatives version that implements the --keep-foreign flag
+Requires(postun): alternatives >= 1.19.1-1
 # python38 installs the alternatives master symlink to which we attach a slave
 Requires: python38
 Requires(post): python38
@@ -176,7 +178,7 @@ alternatives --add-slave python3 %{_bindir}/python3.8 \
 %postun -n python%{python3_pkgversion}-numpy-f2py
 # Do this only during uninstall process (not during update)
 if [ $1 -eq 0 ]; then
-    alternatives --remove-slave python3 %{_bindir}/python3.8 \
+    alternatives --keep-foreign --remove-slave python3 %{_bindir}/python3.8 \
         f2py3
 fi
 
@@ -213,6 +215,10 @@ fi
 
 
 %changelog
+* Mon Aug 02 2021 Tomas Orsava <torsava@redhat.com> - 1.17.3-6
+- Adjusted the postun scriptlets to enable upgrading to RHEL 9
+- Resolves: rhbz#1933055
+
 * Mon Mar 09 2020 Tomas Orsava <torsava@redhat.com> - 1.17.3-5
 - Implement the alternatives system for the executables
 - Resolves: rhbz#1807041