How to Add/Remove the Swap Memory in Ubuntu and Linux.

preview_player
Показать описание
Hi Friends,
▬ Contents of this video ▬▬▬▬▬▬▬▬▬▬
In this video, We will show you How to Add/Remove the Swap Memory in Ubuntu and Linux.

Adding Swap Memory
▬▬▬▬▬▬▬▬▬▬
Step 1: Checking the Swap Information
----------------------------------------------------------------
sudo swapon --show

Step 2: Checking the hard disk space
------------------------------------------------------------

free -h
df -h

Step 3: Creating a Swap File
---------------------------------------------

sudo fallocate -l 1G /swapfile

ls -lh /swapfile

Step 4: Permission setting
------------------------------------------

sudo chmod 600 /swapfile

ls -lh /swapfile

Step 5: Enable Swap File
---------------------------------------

sudo mkswap /swapfile

sudo swapon /swapfile

sudo swapon --show

Remove Swap Memory
▬▬▬▬▬▬▬▬▬▬
Step 1: Checking the Swap Information
---------------------------------------------------------------
sudo swapon --show

Step 2: Checking the hard disk space
-----------------------------------------------------------

free -h

Step 3: Disable Swap
----------------------------------

sudo swapoff -a

Step 4: Remove the Swap file
------------------------------------------------

sudo rm /swapfile

Step 5: Check Swap is disabled
---------------------------------------------------

sudo swapon --show

free -h

Subscribe our channel "TechiesBadi" for more updates and stay connected with us on social networking sites,

Рекомендации по теме
Комментарии
Автор

THANK YOUU!! my pc only has 32 gb and I wasted storage by adding 3 gb swap now it's finally gone!! and it's back to 1gb. You earn a subscribe

unbelievableplayzz
Автор

Thanks man!! Finally deleted the swap mem.

unohorizon
Автор

After rebooting computer Swap memory is not available any solution??

riyazsaeed
Автор

Why didn't you edit the fstab to disable the swap?

boringboringboringboring
join shbcf.ru