Uploaded image for project: 'RHEL Conversions'
  1. RHEL Conversions
  2. RHELC-1275

Analysis: Exit with 1 on a rollback failure

XMLWordPrintable

    • False
    • False
    • Hide

      None

      Show
      None
    • 5
    • 2024-R2
    • Testable

      During testing of the pre-conversion analysis in Insights, we've realized we have no easy way to programatically discern when a rollback that is being performed at the end of the analysis ends up incomplete (HMS-3128) because the exit code is 0. Currently we have a workaround that looks for keywords like fail or error in the terminal output but that's obviously not ideal.

      Acceptance criteria:

      • All the rollback steps are performed - i.e. even if one step fails, the following ones are performed nevertheless.
      • When any of the rollback steps fails, convert2rhel exits with 1.
      • A critical level log message saying that the rollback failed is printed at the end of the teminal output
        • With a rollback failure the system is in an undefined state and the pre-conversion analysis report has much less of a value - it can be omitted so that the user focuses on the resolving the rollback failure (omit printing the analysis result to terminal as well as generating the json/txt report files)

      Related:

      • Currently convert2rhel exits with 1 when run in a conversion mode and an inhibitor is detected. To distinguish an inhibitor from a rollback failure, we've decided on Cabal that we'll introduce a new exit code 2 for inhibitors detected during the conversion.

              ahosek@redhat.com Adam Hosek
              mbocek@redhat.com Michal Bocek
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: