Thursday, 25 November 2021

How to expand disk space on Kali Linux (VMware)

 


 

This guide shows you how to expand your disk space. By doing this you can extend your Root ‘/’ partition in Kali Linux 2020.4.

Firstly, you need to go into Edit Virtual machine setting in your VMware Workstations 16 player.

You then click on ‘Hard Disk (SCSI)’

Once in the Hard Disk (SCSI) setting, you then click on ‘Expand…’

Select the Disk Size you would like. I Allocated 200gb in total. (Adding 120GB to the default 80GB)

You should receive this message (shown above).

Select OK until you are back to the screen you launch your VM from.

The first part of the process is done, we now need to go into our Kali Linux machine and partition the disk.

Open up your machine and log in.

(You will need to be signed in as Root for the next part) Use the command ‘Sudo su’ and then enter your password.

Use the following command

fdisk -l

As you can see we have a maximum capacity of 200GB aloud but our /dev/sda1 partition is only 79GB.

Use the following command:

gparted

Once in this screen you need to right click on /dev/sda5 linux swap and select swapoff.

After this has been switched off you then need to right click /dev/sda2 extended and click Resize/Move.

Expand the partition all the way across to the end. Confirm this after clicking Resize/Move.

Then right click /dev/sda5 Linux-swap and then Resize/Move.

Drag this all the way across.

Just click OK and ignore the following warning.

Next, right click on /dev/sda2 extended and then select Resize/Move.

Resize this so we create some unallocated space.

On the ‘Align to:’ drop down select Cylinder.

Now Right click /dev/sda1 ext4 and select Resize/Move.

Apply all the operations by clicking the tick.

The last step from here is to right click /dev/sda5 linux-swap and turn swap back on by selecting ‘swapon’.

Reboot your machine after all of this is done.

Use the command ‘fdisk -l’ to check this has worked. (after the reboot).

Should look something like this.

Hope that helped.

No comments:

Post a Comment

CISA Exam Guide

  CISA Exam guide  If you want to watch my video talking about the CISA exam and sharing some tips check out my YouTube video below.   What ...