Hello!
I am trying to modify annaconda to allow me to install the MBR on the drive that has the /boot partition on it. This is important because the first drive in a fibre channel environment might be shared. Well I was hoping you could look at this code and tell me whats wrong? It works when I test it in a small script like this one: #!/usr/bin/python import re test1 = "/dev/hda" test2 = "/dev/sda2" p = re.compile( '[0-9]+$') bootMbr = p.sub( '', test2, 1) if test1 != bootMbr: print "bootMbr = ", bootMbr All I can think of is maybe the re.py function is missing from the annaconda install, but if thats the case why didn't it complain about the import function? Can I just simply copy that into the annaconda directory? Or better yet is there a better way to do what I am trying to do. I didn't see any relationship between diskSet.driveList and bootDev.device Any help is appreciated!! Thanks!! diff -Nur anaconda-7.2.orig/fsset.py anaconda-7.2/fsset.py --- anaconda-7.2.orig/fsset.py Fri Aug 24 18:08:04 2001 +++ anaconda-7.2/fsset.py Thu Dec 20 14:05:52 2001 @@ -23,6 +23,7 @@ import struct import partitioning import types +import re from log import log from translate import _, N_ @@ -724,6 +725,16 @@ elif bootDev.getName() == "RAIDDevice": return [ ( bootDev.device, "RAID Device" ) ] + # HACK - FibreBoot Support - bpeck + p = re.compile( '[0-9]+$') + bootMbr = p.sub( '', bootDev.device, 1) + if diskSet.driveList()[0] != bootMbr: + return [(diskSet.driveList()[0], N_("Master Boot Record (MBR)") ), + (bootMbr, N_("Master Boot Record of boot partition")), + (bootDev.device, N_("First sector of boot partition")) + ] + + return [ (diskSet.driveList()[0], N_("Master Boot Record (MBR)") ), (bootDev.device, N_("First sector of boot partition")) ] _______________________________________________ Redhat-devel-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-devel-list