summaryrefslogtreecommitdiffstats
path: root/src/com.gluster.storage.management.server.scripts
diff options
context:
space:
mode:
Diffstat (limited to 'src/com.gluster.storage.management.server.scripts')
-rw-r--r--src/com.gluster.storage.management.server.scripts/src/DiskUtils.py2
-rwxr-xr-xsrc/com.gluster.storage.management.server.scripts/src/gluster_provision_block_wrapper.py17
2 files changed, 4 insertions, 15 deletions
diff --git a/src/com.gluster.storage.management.server.scripts/src/DiskUtils.py b/src/com.gluster.storage.management.server.scripts/src/DiskUtils.py
index e796f479..c76c1c01 100644
--- a/src/com.gluster.storage.management.server.scripts/src/DiskUtils.py
+++ b/src/com.gluster.storage.management.server.scripts/src/DiskUtils.py
@@ -307,7 +307,7 @@ def getDiskInfo(diskDeviceList=None):
partition["SpaceInUse"] = used
if partition["MountPoint"] or isDataDiskPartitionFormatted(partitionDevice):
partition["Init"] = True
- #partition["Status"] = "INITIALIZED"
+ partition["Status"] = "INITIALIZED"
if partition["MountPoint"]:
if "/export/" in partition["MountPoint"]:
partition["Type"] = "DATA"
diff --git a/src/com.gluster.storage.management.server.scripts/src/gluster_provision_block_wrapper.py b/src/com.gluster.storage.management.server.scripts/src/gluster_provision_block_wrapper.py
index 89d7df38..a3b2776d 100755
--- a/src/com.gluster.storage.management.server.scripts/src/gluster_provision_block_wrapper.py
+++ b/src/com.gluster.storage.management.server.scripts/src/gluster_provision_block_wrapper.py
@@ -89,26 +89,15 @@ def main():
writeStatus(deviceFormatStatusFile, "Device format failed\n")
sys.exit(5)
- ## try:
- ## process = subprocess.Popen(command,
- ## stdout=fptr,
- ## stderr=subprocess.PIPE,
- ## stdin=subprocess.PIPE,
- ## close_fds=True)
- ## status = process.wait()
- ## except OSError:
- ## os.unlink(deviceFormatOutputFile)
- ## Utils.log(syslog.LOG_ERR, "formatting disk command failed. command: %s" % str(command))
- ## writeStatus(deviceFormatStatusFile, "Formatting disk command failed\n")
- ## removeLockFile()
- ## sys.exit(-5)
-
if status != 0:
Utils.removeFile(deviceFormatOutputFile)
Utils.removeFile(deviceFormatLockFile)
writeStatus(deviceFormatStatusFile, "Device format failed\n")
sys.exit(6)
+ if Utils.runCommand("/sbin/udevtrigger") != 0:
+ Utils.log("failed running /sbin/udevtrigger")
+
if Utils.runCommand("/usr/bin/lshal") != 0:
Utils.log("failed running /usr/bin/lshal")
writeStatus(deviceFormatStatusFile, "Completed\n")