Check the dnf check exit code before attempting migration.

This commit is contained in:
Peter Ajamian 2022-02-12 23:03:02 +13:00
parent f3fe6d768a
commit dac80ad0f6
1 changed files with 4 additions and 0 deletions

View File

@ -269,6 +269,10 @@ pre_check () {
'migrate2rocky. See the README file for details.'
fi
dnf -y check || exit_message \
'Errors found in dnf/rpm database. Please correct before running '\
'migrate2rocky.'
# Get available space to compare to requirements.
# If the stock kernel is not installed we don't require space in /boot
if ! rpm -q --quiet kernel; then