-
Bug
-
Resolution: Done
-
Minor
-
Conversions-Phase 3
-
None
Given a CentOS7 host connected to Insights when we run the analysis task then the convert2rhel.repo file is not being backed up and thus not restored.
The steps to follow are a regultar analysis:
- Install subscription-manager, rhc, rhc-worker-script, insights-client
- Register the system to the insights
- Check that the host is visible as CentOS in the UI
- Create a custom yum convert2rhel.repo in /etc/yum.repos.d/
- Run the pre-conversion analysis task
- Verify it is possible to do a full conversion and check files.
The test is failing in the 6th step when checking the files. We check that the custom convert2rhel.repo is there but it is not. In the attached convert2rhel-insights-tasks-analysis.log there are two lines where the script seems to find the repo file but fails when creating the backup, after that overwrites the file:
2024-05-10 13:18:32,048 - INFO - File /etc/yum.repos.d/convert2rhel.repo already present on system, backing up to .backup.
2024-05-10 13:18:32,048 - WARNING - Failed to create back up of /etc/yum.repos.d/convert2rhel.repo ([Errno 2] No such file or directory)