Solved

Shrinking the disk

Posted on 2013-10-27
17
426 Views
Last Modified: 2013-11-16
I have a vm in vmware provisioned as Thin Format.After some time the machine allocated up to 400 G and then i deleted some of 100 G but it is still getting 400 G .How can i shrink this thin formated disk.
The virtual machine hosted is having a Linux based OS.
0
Comment
Question by:kastro Abbasi
  • 8
  • 7
  • 2
17 Comments
 
LVL 5

Expert Comment

by:wynandkunkel
ID: 39603557
You would have to use VMware Converter to accomplish this.  In the disk section you can select the minimum size of the disk or you can manually type in the size you want, bearing in mind that you cannot go smaller that the space used in the disk.
0
 
LVL 118
ID: 39603645
Install VMware vCenter Converter Standalone 5.5 on the Virtual Machine and Create a V2V, and in the wizard specify the new size of the virtual disk you require, and whether you want a thick or thin disk.

Installing converter on the VM to be converted is Best Practice, as recommended by VMware.


see my EE Article, Step by Step Tutorial Instructions with Screenshots

HOW TO:  P2V, V2V for FREE - VMware vCenter Converter Standalone 5.5

HOW TO:  Synchronize changes when completing a P2V or V2V with VMware vCenter Converter Standalone 5.1

HOW TO: Improve the transfer rate of a Physical to Virtual (P2V), Virtual to Virtual Conversion (V2V) using VMware vCenter Converter Standalone 5.0
0
 

Author Comment

by:kastro Abbasi
ID: 39603647
you mean i have to move this vm to some other datastore ,as this is linux machine and many users are working on it.
please explain a little bit more
0
 
LVL 5

Expert Comment

by:wynandkunkel
ID: 39603655
Hi ayazabbasi,

You could "move" it to the same datastore as converter will create a copy of the machine.  This might just then take a little longer as the same datastore would be reading the old machine and writing the new machine at the same time.  

In my experience this is typically something that you should do after hours, or during "quiet time"...

Once the "conversion" has completed you could then delete the "old" copy.

There is no other VMware supported method of doing this.
0
 
LVL 118
ID: 39603656
If this is a Linux machine, what Linux distribution are you using?

Converter may not be comopatible or support your VM.

You will have to ensure, ALL Services are shutdown, and ALL users are logged out.

BUT first, what Linux Distribution?
0
 

Author Comment

by:kastro Abbasi
ID: 39603907
I am using suse enterprise linux on esxi 4.1.Is there no other way as by using vmkfstools

or any other way except converter
0
 
LVL 118

Accepted Solution

by:
Andrew Hancock (VMware vExpert / EE MVE) earned 500 total points
ID: 39603921
I'm afraid VMware removed support for shrinking disks in the OS after 2.5/3.0.

You could also try a cloning tool to another disk of smaller size.

Converter 5.5 does support the following Linux Distros for conversion:-

SUSE Linux Enterprise Server 9.x (32-bit and 64-bit)
SUSE Linux Enterprise Server 10.x (32-bit and 64-bit)
SUSE Linux Enterprise Server 11.x (32-bit and 64-bit)
0
 

Author Comment

by:kastro Abbasi
ID: 39606813
Can i use the Magic parted to shrink my suse enterprise Linux
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 118
ID: 39606883
you can use partition utilities, the OS partition will change, but not the virtual disk (vmdk).
0
 

Author Comment

by:kastro Abbasi
ID: 39606953
so you mean by using the magic partition i ll shrink the os partition,then i have to use vmware converter to shrink the vmdk.
as the vmdk.
but now the vmdk size has reached to 1T and i dont have so much space to shift this vm of 1T by using vmware converter.so thats why i was using magic partition to shrink the os partition .so what do you suggest it will work or not
0
 

Author Comment

by:kastro Abbasi
ID: 39607067
I mean in first step i shrinked the linux partitions by using magic partition and what is the second step to shrink the vmdk size
0
 
LVL 118
ID: 39607100
Converter will shrink the partition and disk in a single procedure there is no need to use additional partition products.
0
 
LVL 118
ID: 39607103
Why has the size increased from 400GB to 1TB ?
0
 

Author Comment

by:kastro Abbasi
ID: 39607120
as first i was trying to use the dd utility to append the block with zeroes.it filled all the space .
0
 
LVL 118
ID: 39607150
So the disk is now 1TB
0
 

Author Comment

by:kastro Abbasi
ID: 39607764
yes it is having ITB size
0
 
LVL 118
ID: 39607966
What is the maximum size you have made the thin disk?

you will need to convert.
0

Featured Post

How to Backup Ubuntu to Amazon S3

CloudBerry Backup offers automatic cloud backup and restoration for Linux. It has both GUI and command line interface (CLI) ensuring its flexibility in use. Find out more

Join & Write a Comment

This is an issue that we can get adding / removing permissions in the vCSA 6.0. We can also have issues searching for users / groups in the AD (using your identify sources). This is how one of the ways to handle this issues and fix it.
In this step by step tutorial with screenshots, we will show you HOW TO: Enable SSH Remote Access on a VMware vSphere Hypervisor 6.5 (ESXi 6.5). This is important if you need to enable SSH remote access for additional troubleshooting of the ESXi hos…
Teach the user how to use create log bundles for vCenter Server or ESXi hosts Open vSphere Web Client: Generate vCenter Server and ESXi host log bundle:  Open vCenter Server Appliance Web Management interface and generate log bundle: Open vCenter Se…
This tutorial will walk an individual through the steps necessary to enable the VMware\Hyper-V licensed feature of Backup Exec 2012. In addition, how to add a VMware server and configure a backup job. The first step is to acquire the necessary licen…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now