diff options
author | Martin Sivak <msivak@redhat.com> | 2008-03-25 22:45:56 +0100 |
---|---|---|
committer | Martin Sivak <msivak@redhat.com> | 2008-03-25 22:47:57 +0100 |
commit | c0beca8cfd3af9a38dee89fc2ffb83bb5b2b6e55 (patch) | |
tree | ca1b6ce939b572daebf20eac5c885b36c8ce0c6f | |
parent | 7e4430e2f8edb9af1c982a22dd357edb755fe994 (diff) | |
download | anaconda-c0beca8cfd3af9a38dee89fc2ffb83bb5b2b6e55.tar.gz anaconda-c0beca8cfd3af9a38dee89fc2ffb83bb5b2b6e55.tar.xz anaconda-c0beca8cfd3af9a38dee89fc2ffb83bb5b2b6e55.zip |
Do not try to initialize iSCSI drive, when the portal cannot be detected (#435173)
-rw-r--r-- | iscsi.py | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -114,6 +114,10 @@ class iscsiTarget: return True def startNode(self, node): + if node is None or self.portal is None: + log.warn("unable to find portal information") + return + argv = [ "-m", "node", "-T", node, "-p", self.portal, "-o", "update", "-n", "node.conn[0].startup", "-v", "automatic" ] @@ -122,6 +126,10 @@ class iscsiTarget: stdout = "/dev/tty5", stderr="/dev/tty5") def loginToNode(self, node): + if node is None or self.portal is None: + log.warn("unable to find portal information") + return + argv = [ "-m", "node", "-T", node, "-p", self.portal, "--login" ] log.debug("iscsiadm %s" %(string.join(argv),)) rc = iutil.execWithRedirect(ISCSIADM, argv, |