def probe(self): """ Probe for any missing information about this format. """ if not self.exists: raise RaidMemberError("format does not exist", self.device) info = raid.mdexamine(self.device) if self.uuid is None: self.uuid = info['uuid'] if self.raidMinor is None: self.raidMinor = info['mdMinor']
def probe(self): """ Probe for any missing information about this device. I'd like to avoid paying any attention to "Preferred Minor" as it seems problematic. """ if not self.exists: raise RaidArrayError("device has not been created", self.name) try: self.devices[0].setup() except Exception: return info = raid.mdexamine(self.devices[0].path) if self.level is None: self.level = raid.raidLevel(info['level'])