Bug 675322
Summary: | RHEL 6 anaconda generates invalid anaconda-ks.cfg when using multipath devices | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | John Ruemker <jruemker> | ||||||||
Component: | anaconda | Assignee: | Ales Kozumplik <akozumpl> | ||||||||
Status: | CLOSED DUPLICATE | QA Contact: | Release Test Team <release-test-team-automation> | ||||||||
Severity: | medium | Docs Contact: | |||||||||
Priority: | medium | ||||||||||
Version: | 6.0 | CC: | akozumpl, bugproxy, ekuric, gregswift, jzeleny | ||||||||
Target Milestone: | rc | ||||||||||
Target Release: | --- | ||||||||||
Hardware: | All | ||||||||||
OS: | Linux | ||||||||||
Whiteboard: | |||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||
Doc Text: | Story Points: | --- | |||||||||
Clone Of: | Environment: | ||||||||||
Last Closed: | 2011-06-07 13:58:47 UTC | Type: | --- | ||||||||
Regression: | --- | Mount Type: | --- | ||||||||
Documentation: | --- | CRM: | |||||||||
Verified Versions: | Category: | --- | |||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||
Embargoed: | |||||||||||
Bug Depends On: | |||||||||||
Bug Blocks: | 658636, 697582, 705163 | ||||||||||
Attachments: |
|
Description
John Ruemker
2011-02-04 21:46:27 UTC
*** Bug 688443 has been marked as a duplicate of this bug. *** Created attachment 486001 [details]
Kickstart files and console outputs
Created attachment 486002 [details]
Kickstart files and console outputs - RHEL6.1 Alpha
Created attachment 490338 [details]
Error message
------- Comment on attachment From anibalca.ibm.com 2011-04-06 12:36 EDT-------
We added this line:
echo -e "defaults {\n user_friendly_names yes\n}" > /etc/multipath.conf
to the %pre section of the kickstart file and then we got the same analog error message that we got when using sda (see attached file).
------- Comment From vahegde1.ibm.com 2011-04-20 00:56 EDT------- Hi Ales / Red Hat , Any update on this issue ? Will it be fixed in 6.1 cycle ? Thanks Vasant (In reply to comment #6) > ------- Comment From vahegde1.ibm.com 2011-04-20 00:56 EDT------- > Hi Ales / Red Hat , > > Any update on this issue ? Will it be fixed in 6.1 cycle ? > > Thanks > Vasant Hello, this is scheduled for the 6.2 cycle. Ales ------- Comment From rdc.ibm.com 2011-05-04 11:15 EDT------- Raising to ship issue since the bug prevents kickstart installations from being done on machines with multipath disks Another customer reported problems with using multipath devices in kickstart with RHEL6, and so I had reason to dig deeper into this issue. The problem, as noted in my original comments, is that clearpart/ignoredisk do not accept mpath* names. This has larger implications than just the generated anaconda-ks.cfg not working, however. Since ignoredisk and clearpart are the basis for what gets added to storage.exclusiveDisks, and thus what can be used in a 'part' command, there is no way (that I can come up with) to use kickstart and have any control over which multipath device is used for certain partitions. If you specify mpath names in clearpart/ignoredisk, you will get an error (Specified nonexistent disk...). If you only specify the underlying disks in ignoredisk/clearpart and attempt to use 'part --ondisk=mpathX ...' where mpathX is comprised of the devices you specified in ignoredisk/clearpart, you will get a traceback. Traceback (most recent call first): File "/usr/lib/anaconda/storage/partitioning.py", line 995, in allocatePartitions disklabel = disklabels[_disk.path] File "/usr/lib/anaconda/storage/partitioning.py", line 868, in doPartitioning allocatePartitions(storage, disks, partitions, free) File "/usr/lib/anaconda/storage/partitioning.py", line 227, in doAutoPartition exclusiveDisks=anaconda.id.storage.clearPartDisks) File "/usr/lib/anaconda/dispatch.py", line 208, in moveStep rc = stepFunc(self.anaconda) File "/usr/lib/anaconda/dispatch.py", line 126, in gotoNext self.moveStep() File "/usr/lib/anaconda/dispatch.py", line 231, in currentStep self.gotoNext() File "/usr/lib/anaconda/text.py", line 593, in run (step, instance) = anaconda.dispatch.currentStep() File "/usr/bin/anaconda", line 1115, in <module> anaconda.intf.run(anaconda) KeyError: '/dev/mapper/mpatha' You'll also get a traceback if you don't specify --ondisk, as anaconda will auto-select mpathX as the device to partition, ending up at the same result. This traceback is due to disklabels[] in allocatePartitions being empty, as a result of mpatha not being in exclusiveDisks: anaconda = storage.anaconda disks = storage.partitioned if exclusiveDisks: disks = [d for d in disks if d.name in exclusiveDisks] for disk in disks: disk.setup() [...] allocatePartitions(storage, disks, partitions, free) So this lead to me investigating the underlying reasons for clearpart/ignoredisk not accepting mpath names. ClearPart.parse() and IgnoreDisk.parse() are responsible for checking the listed devices to see if they exist, and these are set in motion by: File "/usr/bin/anaconda", line 818, in <module> ksdata = kickstart.parseKickstart(anaconda, opts.ksfile) Its only after this call that we actually set up the device tree, which involves finding mpath devices: File "/us/bin/anaconda", line 1098, in <module> storage.storageInitialize(anaconda) So, the reason we can't include mpath names in ignoredisk/clearpart is because anaconda is not yet aware of them at the time that we run *.parse. Since changing the ordering of these calls around doesn't seem feasible, my idea for solving this was to simply add mpathX names to exclusiveDisks as we find them during storageInitialize. That way you would specify your underlying disks ignoredisk/clearpart, and then just specify your mpath device in part commands. Unfortunately my attempt at implementing this was unsuccessful. However I wanted to share the above details of my analysis here in case it helps with finding a solution. Thanks, and let me know if I can help in any way. -John John, there is a fix ready for bug 696876 which is this same issue from the other side, that is "anaconda does not recognize 'clearpart --linux --drives=mpatha' and similar". I suggest we either 1) close this as a dup 2) keep it open just for QA to verify they can install using the generated kickstart. What do you think? I'm fine with this being closed as a dupe. Thanks! *** This bug has been marked as a duplicate of bug 696876 *** |