File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
tests/kola/upgrade/extended Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -244,6 +244,19 @@ selinux-sanity-check() {
244
244
245
245
ok " Reached version: $version "
246
246
247
+ verify-alternatives-migration () {
248
+ # Verify iptables migration
249
+ if [[ $( alternatives --admindir /etc/alternatives-admindir --display iptables | grep -c -E ' link currently points to /usr/(bin|sbin)/iptables-nft' ) != " 1" ]]; then
250
+ fatal " Error: migration did not set iptables to nft backend"
251
+ fi
252
+ if [[ $( iptables --version | grep -c " nf_tables" ) != " 1" ]]; then
253
+ fatal " Error: iptables not reset to nftables backend"
254
+ fi
255
+
256
+ ok " alternatives migration verification passed."
257
+
258
+ }
259
+
247
260
# Are we all the way at the desired target version?
248
261
# If so then we can exit with success!
249
262
if vereq $version $target_version ; then
@@ -256,6 +269,8 @@ if vereq $version $target_version; then
256
269
fi
257
270
# One last check!
258
271
selinux-sanity-check
272
+ # One more last check
273
+ verify-alternatives-migration
259
274
exit 0
260
275
fi
261
276
You can’t perform that action at this time.
0 commit comments