Fix autopartion and get install uuid.

master3.3
Mike Hiretsky 12 years ago
parent 14c196e205
commit a9e0e7b806

@ -281,7 +281,7 @@ class Distributive(object):
joinFrom = partial(path.join,fromdir)
params = [cpCmd,"-a"]+\
map(joinFrom,
ifilterfalse(byfile,
ifilterfalse(byfile or operator.not_,
listDirectory(fromdir)))+\
[todir]
filenum = countFiles(fromdir)

@ -731,6 +731,7 @@ class Install(color_print):
targetDistr.convertToDirectory()
self.endTask()
self.clVars.processRefresh()
if self.clVars.Get('os_install_root_type') != "flash":
self.afterCopyHDDinstall(targetDistr)
else:

@ -104,7 +104,7 @@ class AutoPartition:
return True
else:
sleep(waittime)
raise AutoPartitionError(
raise AutopartitionError(
_("Failed to found partition %s after creating partition table")
%dev)
@ -112,13 +112,13 @@ class AutoPartition:
"""
Create GPT partition table by /sbin/gdisk
"""
NEW_PARTITION_TABLE = "o\ny\n"
NEW_PARTITION_TABLE = "3\no\ny\n"
NEW_PARTITION = "n\n\n\n"
NEW_BIOSBOOT_PARTITION = "n\n\n\n%s\nef02\n"
MAX_SIZE = "\n\n"
WRITE_AND_QUIT = "w\ny\n"
fdiskProg = getProgPath('/usr/sbin/fdisk')
fdiskProg = getProgPath('/usr/sbin/gdisk')
fdisk = process(fdiskProg,device)
fdisk.write(NEW_PARTITION_TABLE)
scheme = scheme.format(memory=memory,
@ -152,7 +152,7 @@ class AutoPartition:
return True
else:
sleep(waittime)
raise AutoPartitionError(
raise AutopartitionError(
_("Failed to found partition %s after creating partition table")
%dev)

@ -114,6 +114,7 @@ class VariableOsDeviceDev(ReadonlyVariable,DeviceHelper):
while len(res) == 65535:
res = os.read(self.master,65535)
self.parent.Invalidate(self.name)
self.parent.Invalidate('os_install_disk_uuid')
except OSError as e:
pass

Loading…
Cancel
Save