コード例 #1
0
def partitionObjectsInitialize(anaconda):
    # shut down all dm devices
    anaconda.id.diskset.closeDevices()
    anaconda.id.diskset.stopMdRaid()
    anaconda.id.zfcp.shutdown()

    # clean slate about drives
    isys.flushDriveDict()

    if anaconda.dir == DISPATCH_BACK:
        return

    # ensure iscsi devs are up
    anaconda.id.iscsi.startup(anaconda.intf)

    # ensure zfcp devs are up
    anaconda.id.zfcp.startup()

    # pull in the new iscsi drive
    isys.flushDriveDict()

    # read in drive info
    anaconda.id.diskset.refreshDevices()

    anaconda.id.partitions.setFromDisk(anaconda.id.diskset)
    anaconda.id.partitions.setProtected(anaconda.dispatch)

    # make sure we have all the device nodes we'll want
    iutil.makeDriveDeviceNodes()
コード例 #2
0
ファイル: iscsi.py プロジェクト: abelboldu/anaconda-ee
def stabilize(intf = None):
    # Wait for udev to create the devices for the just added disks
    if intf:
        w = intf.waitWindow(_("Scanning iSCSI nodes"),
                            _("Scanning iSCSI nodes"))
    time.sleep(2)

    # ensure we have device nodes for our partitions
    isys.flushDriveDict()
    iutil.makeDriveDeviceNodes()

    if intf:
        w.pop()
コード例 #3
0
ファイル: kickstart.py プロジェクト: jeramirez/base
    def doIscsi(self, args):
        KickstartHandlers.doIscsi(self, args)

        for target in self.ksdata.iscsi:
            kwargs = {"ipaddr": target.ipaddr, "port": target.port}
            if target.user and target.password:
                kwargs.update({"user": target.user, "pw": target.password})
            if target.user_in and target.password_in:
                kwargs.update({"user_in": target.user_in, "pw_in": target.password_in})

            if self.id.iscsi.addTarget(**kwargs):
                log.info("added iscsi target: %s" % (target.ipaddr,))

        # FIXME: flush the drive dict so we figure drives out again
        isys.flushDriveDict()
コード例 #4
0
    def doZFCP(self, args):
        KickstartHandlers.doZFCP(self, args)
        for fcp in self.ksdata.zfcp:
            self.id.zfcp.addFCP(fcp.devnum, fcp.wwpn, fcp.fcplun)

        isys.flushDriveDict()