How To Create Partition In Red Hat

Creating partition :

Like windows fat & ntfs here file system is ext2,ext3,vfat are userd.

There are two type of hard disk :

1 sata 2 pata
1 sata hdd =sda 1st pata hdd=hda
2 sata hdd = sdb 2 pata hdd=hdb
3 sata hdd = sdc 3 pata hdd=hdc

How to check pc has SATA hdd or PARA HDD in Red Hat?

Command
[root@localhost~]# fdisk  -l

Step (1) : How to crate a partition in red hat?

Command
[root@localhost~]# fdisk  /dev/sda

Command :

  • m : for help
  • d : delete a partition
  • n : add a new partition
  • w : write table to disk and exit
  • q : quit without saving change

Command (m for help) : n

  • First cylinder (1098-2434,default 1098) : 1098
  • Last cylinder or +size or +sizeM or +sizek
    (1098-2434,default 2434):+100M

Command (m for help): w

Command (m for help): w

Command
#partprobe	/dev/had or 
#partprobe /dev/sda

Step (2) : How to make the file system in Red Hat?

Like windows “fat” “ntfs” here we have “ext2” “ext3” “vfat”

Command
#	mkfs.ext2 /dev/hda4
#mkfs.ext3 /dev/sda4

Step (3) : How to create a folder & mount the partition to use in Red Hat?

Command
# mkdir /mnt/song  /mnt/video
#mount /dev/hda4 /mnt/song ---> temporary mount
#mount /dev/sda4 /mnt/video ---> temporary mount

For check :

Command
#mount
[root@localhost ~]#cd /mnt/song
[root@localhost song]# touch myfile1 ,myfile2
[root@localhost song]# mkdir a b c

Permanente mount in Red Hat :

What is mount mount in Red Hat?

Mount is jointing.

What is mount pointing in Red Hat?

Mount point is point where the partition is joint. Mount point the partition in two way temporary & Permanente.

What is temporary mount in Red Hat?

Eg :

Command
#mount /dev/hda /mnt/song

How to create permanente mount in Red Hat?

Eg :

Command
#vim /etc/fstab

in the file add the line is below.

  • /dev/hda4 ---> Partition
  • /mnt/song ---> Mount point
  • ext3 ---> File system
  • defaults ---> Extra permision
  • 0 0

:wq or :x ---> (for save & exit)

How to mount all the entry in fstab file in Red Hat?

Command
#mount -a
To check
#mount
Notepad

After the system reboot Permanente partition is remain.

#Creating_partition_in_red_hat #Permanente_mount_in_Red_Hat #How_to_check_pc_has_SATA_hdd_or_PARA_HDD_in_Red_Hat #How_to_crate_a_partition_in_red_hat #How_to_make_the_file_system_in_Red_Hat #What_is_mount_mount_in_Red_Hat #What_is_mount_pointing_in_Red_Hat #What_is_temporary_mount_in_Red_Hat #How_to_create_Permanente_mount_in_Red_Hat

(New page will open, for Comment)

Not yet commented...