?
Solved

Shrinking the disk

Posted on 2013-10-27
17
Medium Priority
?
433 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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 123
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
Don't Cry: How Liquid Web is Ensuring Security

WannaCry is just the start. Read how Liquid Web is protecting itself and its customers against new threats.

 
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 123
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 123

Accepted Solution

by:
Andrew Hancock (VMware vExpert / EE MVE^2) earned 2000 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
 
LVL 123
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 123
ID: 39607100
Converter will shrink the partition and disk in a single procedure there is no need to use additional partition products.
0
 
LVL 123
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 123
ID: 39607150
So the disk is now 1TB
0
 

Author Comment

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

you will need to convert.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When rebooting a vCenters 6.0 and try to connect using vSphere Client we get this issue "Invalid URL: The hostname could not parsed." When we get this error we need to do some changes in the vCenter advanced settings to fix the issue.
The business world is becoming increasingly integrated with tech. It’s not just for a select few anymore — but what about if you have a small business? It may be easier than you think to integrate technology into your small business, and it’s likely…
Teach the user how to edit .vmx files to add advanced configuration options Open vSphere Web Client: Edit Settings for a VM: Choose VM Options -> Advanced: Add Configuration Parameters:
Teach the user how to configure vSphere Replication and how to protect and recover VMs Open vSphere Web Client: Verify vsphere Replication is enabled: Enable vSphere Replication for a virtual machine: Verify replicated VM is created: Recover replica…
Suggested Courses

765 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