Bug 1414341
| Summary: | The part/partition and autopart commands are used both in one kickstart file | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 6 | Reporter: | Tereza Cerna <tcerna> |
| Component: | preupgrade-assistant | Assignee: | Michal Bocek <mbocek> |
| Status: | CLOSED ERRATA | QA Contact: | Alois Mahdal <amahdal> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 6.9 | CC: | mbocek, ovasik, phracek |
| Target Milestone: | rc | Keywords: | Extras |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | preupgrade-assistant-2.3.2-1.el6 | Doc Type: | No Doc Update |
| Doc Text: |
undefined
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2017-03-21 12:10:28 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
Related problem:
================
When user runs regeneration of kickstart with command 'preupg-kickstart-generator', it causes traceback and writes error message:
"The part/partition and autopart commands can't be used at the same time"
Example:
========
# preupg
# preupg-kickstart-generator
Cannot read the system Kickstart at /root/preupgrade/kickstart/anaconda-ks.cfg.
The '/root/preupgrade/postmigrate.d' folder is empty - scripts to be executed after the migration should be placed here.
Do you want to continue with kickstart generation without any postmigration scripts? (Y/n)
y
The Preupgrade Assistant generates a kickstart file in '/root/preupgrade/kickstart/preupgrade.ks'.
The Kickstart file contains:
- users with UID/GID which you should create on Red Hat Enterprise Linux 7 system.
- the partitioning layout which was used on this system
- the package set which was installed on this system.
- the firewall rules which were enabled on this system.
The Kickstart file is pre-generated from this system and is not to be used directly for
the installation of Red Hat Enterprise Linux 7.
The Kickstart file needs to be modified by the administator.
These directories exist on the migration system:
- /root/preupgrade/preupg_results-170118044230/cleanconf - configuration files which can be used on the migrated system.
- /root/preupgrade/preupg_results-170118044230/dirtyconf - configuration files which need to be clarified by the administrator.
# preupg-kickstart-generator
Cannot read the system Kickstart at /root/preupgrade/kickstart/anaconda-ks.cfg.
Traceback (most recent call last):
File "/usr/bin/preupg-kickstart-generator", line 27, in ?
sys.exit(main())
File "/usr/bin/preupg-kickstart-generator", line 19, in main
app.main()
File "/usr/lib/python2.4/site-packages/preupg/kickstart/application.py", line 255, in main
dummy_ks = self.generate()
File "/usr/lib/python2.4/site-packages/preupg/kickstart/application.py", line 231, in generate
if not self.collect_data():
File "/usr/lib/python2.4/site-packages/preupg/kickstart/application.py", line 102, in collect_data
os.path.join(self.dir_name, settings.KS_TEMPLATE))
File "/usr/lib/python2.4/site-packages/preupg/kickstart/application.py", line 127, in load_or_default
ksparser.readKickstart(ks_template)
File "/usr/lib/python2.4/site-packages/preupg_pykickstart/parser.py", line 784, in readKickstart
self._stateMachine (lambda: fh.readline())
File "/usr/lib/python2.4/site-packages/preupg_pykickstart/parser.py", line 658, in _stateMachine
self.handleCommand(lineno, args)
File "/usr/lib/python2.4/site-packages/preupg_pykickstart/parser.py", line 487, in handleCommand
retval = self.handler.dispatcher(args, lineno)
File "/usr/lib/python2.4/site-packages/preupg_pykickstart/base.py", line 396, in dispatcher
obj = self.commands[cmd].parse(args[1:])
File "/usr/lib/python2.4/site-packages/preupg_pykickstart/commands/partition.py", line 375, in parse
raise KickstartParseError, formatErrorMsg(self.lineno, msg=errorMsg)
preupg_pykickstart.errors.KickstartParseError: The following problem occurred on line 38 of the kickstart file:
The part/partition and autopart commands can't be used at the same time
Resolved by upstream commit: https://github.com/upgrades-migrations/preupgrade-assistant/commit/a01f099a2b4237e267d902c5e7e3d437e8710ca3 I cannot reproduce this. With new version, only `autopart` is used with old version, only `part commands` are used---but never both. This was originally found in 2.2.1-1.el5. On el6 channel, the last version is 2.1.10-6.el6, so my guess is that the problematic code was never released. Michal, can you please confirm if that is the case? If so, I would propose dropping this from erratum and closing it (there is nothing to fix from RHEL6 customer POV). Otherwise, please provide hint how to reproduce this on RHEL6. (Same situation as with bug 1414344). (In reply to Michal Bocek from bug 1414344 comment #5) > Alois, to reproduce this in 2.1.10-6.el6, make sure you have "autopart" in > /root/anaconda-ks.cfg - it serves as a basis for the generated kickstart. > > When generating kickstart the "part" commands were always added no matter > whether there was "autopart" already or not. OK, so this reproducer actually works. Thanks! With 2.1.10-6.el6, both `part` and `autopart` end up in the resultsing kickstart. With 2.3.3-1.el6, only `autopart` ends up in the resultsing kickstart. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2017-0819.html |
# rpm -q preupgrade-assistant{,-el5toel7{,-data}} preupgrade-assistant-2.2.1-1.el5 preupgrade-assistant-el5toel7-0.6.40-1.el5 preupgrade-assistant-el5toel7-data-0.20170101-1.el5