REDHAT:- How to create a swap partition in REDHAT

3

Hello dosto to kaise hai aap log,

Bhaiyon aaj hum is article me seekhne bale hai ki LINUX SYSTEM me swap partition kaise Creat karte hai.

( In this article we are going to learn How to craete a swap partition using command fdisk, before that let me expian you what is the use of swap partition in linux )

Q:- Add a Swap parititon
Add an addition swap partition of 512 Mib to your system. The Swap parititon should automatically mount when your system boots. do not remove or otherwise alter any existing swap partition on your system. Keep in mind that additional parition my be required by other items.

Answer:-

Freinds jo command me aapko batane jo raha hu us command se aap new swap partition create kar sakte hai command chalane ke liye sbse pahle apna linux system open karle phir usme aap right click se teminal open kar le phir niche di hui command chalaye

 

#Free -m     ( dispaly swap size )

#fdisk -l  ( To list the available free disk and created partition )

#fdisk /dev/vdb ( To create a new partition )

Press ‘n’

press ‘e’ ( e= extended partition )

First sector ————————–Enter

last sector —————————Enter

Press ‘n’  ( new partition logical

Press ‘i’ ( if ask logical )

First sector ————————–Enter

Last sector ————————–+512M

Press ‘t’ ( changes id )

selected partition number 

type swap id (82)

Press ‘p’      ( display partition )

Press ‘w’ ( save and exit )

# partprobe /dev/vdb

#fdisk -l

#mkswap /dev/vdb6

#swapon /dev/vdb6

#blkid

Copy swap id

open files

#nano /etc/fstab

Paste id      swap     swap     defults    0      0

ctrl+x+y+enter

#free -m

3 COMMENTS

  1. Very nice article for everyone needful information is there.
    Navigator system: Any issue related to server we will always help to client regarding server support & maintenance, installation, and upgrade, also rent DELL, HP, IBM, Oracle, SUN servers at best price.

LEAVE A REPLY

Please enter your comment!
Please enter your name here