This is one additional change that's needed for software raid for ppc on installation. This change is actually in booty, and will allow anaconda/booty to accurately write the yaboot.conf configuration file when the user has created more than one bootable PReP partition. The code used to simply write: boot=/dev/<PReP partition> With this new functionality, a list is created containing any PReP partitions that are flagged for formatting. And that list is written to the boot= line of yaboot.conf. Credit where credit is due... Peter Jones developed this version of the patch. (My original didn't work). I've tested it and it writes boot=<dev list> to yaboot.conf accurately. (Slight munging may be necessary--this patch is against booty as of RHEL4). :-Dustin --- booty-0.44/checkbootloader.py 2005-06-14 15:35:38.000000000 -0400 +++ booty-0.44-raid/checkbootloader.py 2005-06-14 15:35:39.000000000 -0400 @@ -75,8 +75,6 @@ dev = string.split(field, '[')[0] if len(dev) == 0: continue - disk = getDiskPart(dev)[0] - rc.append(disk) return rc @@ -117,6 +115,14 @@ dev = string.replace(dev, "'", "") return dev +def getBootDevList(line): + devs = string.split(line, '=')[1] + rets = [] + for dev in devs: + dev = getBootDevString("=%s" % (dev,)) + rets.append(dev) + return string.join(rets) + def getBootloaderTypeAndBoot(instRoot = "/"): haveGrubConf = 1 haveLiloConf = 1 @@ -177,7 +183,7 @@ lines = f.readlines() for line in lines: if line[0:5] == "boot=": - bootDev = getBootDevString(line) + bootDev = getBootDevList(line) if bootDev: return ("YABOOT", bootDev) --- booty-0.44/bootloaderInfo.py 2004-10-04 12:51:41.000000000 -0400 +++ booty-0.44-raid/bootloaderInfo.py 2005-06-14 15:32:30.000000000 -0400 @@ -1501,12 +1501,21 @@ class ppcBootloaderInfo(bootloaderInfo): + def getPrepBootDevs(self, fs): + import fsset + devs = [] + for entry in fs.entries: + if isinstance(entry.fsystem, fsset.prepbootFileSystem) \ + and entry.format: + devs.append('/dev/%s' % (entry.device.getDevice(),)) + return devs + def writeYaboot(self, instRoot, fsset, bl, langs, kernelList, chainList, defaultDev, justConfigFile): from flags import flags - yabootTarget = '/dev/%s' %(bl.getDevice()) + yabootTarget = string.join(self.getPrepBootDevs(fsset)) bootDev = fsset.getEntryByMountPoint("/boot") if bootDev:
Attachment:
signature.asc
Description: This is a digitally signed message part