FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora/Linux Management Tools

 
 
LinkBack Thread Tools
 
Old 03-17-2009, 01:52 AM
David Lehman
 
Default Don't use disk.maximizePartition anymore.

We are doing a fine job of maximizing things on our own, and
maximizePartitions is actually shrinking our partitions in an
effort to make sure they are cylinder-aligned. Bottom line,
it's not doing anything useful. If we decide to start making
all partitions cylinder-aligned, we will want to do it in
another way besides calling maximizePartitions, and presumably
our current accuracy will be preserved. If not, we can always
bring it back.
---
storage/partitioning.py | 23 -----------------------
1 files changed, 0 insertions(+), 23 deletions(-)

diff --git a/storage/partitioning.py b/storage/partitioning.py
index c10a3d2..8243080 100644
--- a/storage/partitioning.py
+++ b/storage/partitioning.py
@@ -932,29 +932,6 @@ def growPartitions(disks, partitions):
except PartitioningError, e:
raise PartitioningError("failed to grow partitions")

- # Maximize partitions, we do this after growing all partitions
- # as some partitions may grow unlimited, and we don't want them
- # eating up the entire disk when we still need to grow others
- for part in growable:
- constraint = parted.Constraint(device=disk.partedDisk.device)
-
- # don't grow beyond the request's maximum size
- if part.req_max_size:
- max_sect = (part.req_max_size * (1024 * 1024)) / sectorSize
- if constraint.maxSize > max_sect:
- constraint.maxSize = max_sect
-
- # don't grow beyond the resident filesystem's max size
- if part.format.maxSize > 0:
- max_sect = (part.format.maxSize * (1024 * 1024)) / sectorSize
- if constraint.maxSize > max_sect:
- constraint.maxSize = max_sect
-
- disk.partedDisk.maximizePartition(part.partedParti tion, constraint)
- log.debug("grew partition %s to %dMB" % (part.name,
- part.partedPartition.getSize()))
- log.debug("the disk's copy is %dMB" % disk.partedDisk.getPartitionByPath(part.path).getS ize())
-
# reset all requests to their original requested size
for part in partitions:
if part.exists:
--
1.6.0.6

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 
Old 03-17-2009, 01:59 AM
David Cantrell
 
Default Don't use disk.maximizePartition anymore.

I'm ok with this. We should keep an eye on things to see if it affects
other operating systems for dual boot scenarios.


On 03/16/2009 04:52 PM, David Lehman wrote:

We are doing a fine job of maximizing things on our own, and
maximizePartitions is actually shrinking our partitions in an
effort to make sure they are cylinder-aligned. Bottom line,
it's not doing anything useful. If we decide to start making
all partitions cylinder-aligned, we will want to do it in
another way besides calling maximizePartitions, and presumably
our current accuracy will be preserved. If not, we can always
bring it back.
---
storage/partitioning.py | 23 -----------------------
1 files changed, 0 insertions(+), 23 deletions(-)

diff --git a/storage/partitioning.py b/storage/partitioning.py
index c10a3d2..8243080 100644
--- a/storage/partitioning.py
+++ b/storage/partitioning.py
@@ -932,29 +932,6 @@ def growPartitions(disks, partitions):
except PartitioningError, e:
raise PartitioningError("failed to grow partitions")

- # Maximize partitions, we do this after growing all partitions
- # as some partitions may grow unlimited, and we don't want them
- # eating up the entire disk when we still need to grow others
- for part in growable:
- constraint = parted.Constraint(device=disk.partedDisk.device)
-
- # don't grow beyond the request's maximum size
- if part.req_max_size:
- max_sect = (part.req_max_size * (1024 * 1024)) / sectorSize
- if constraint.maxSize> max_sect:
- constraint.maxSize = max_sect
-
- # don't grow beyond the resident filesystem's max size
- if part.format.maxSize> 0:
- max_sect = (part.format.maxSize * (1024 * 1024)) / sectorSize
- if constraint.maxSize> max_sect:
- constraint.maxSize = max_sect
-
- disk.partedDisk.maximizePartition(part.partedParti tion, constraint)
- log.debug("grew partition %s to %dMB" % (part.name,
- part.partedPartition.getSize()))
- log.debug("the disk's copy is %dMB" % disk.partedDisk.getPartitionByPath(part.path).getS ize())
-
# reset all requests to their original requested size
for part in partitions:
if part.exists:



--
David Cantrell <dcantrell@redhat.com>
Red Hat / Honolulu, HI

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 

Thread Tools




All times are GMT. The time now is 02:14 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org