Before removing a partition, unmount any partitions on the device and turn off any swap space on the device.

1. Start parted, where /dev/mapper/mpathbp is the device on which to remove the partition :-

# parted /dev/mapper/mpathbp

2. View the current partition table to determine the minor number of the partition to remove :-

(parted) print

3. Remove the partition with the command rm. For example, to remove the partition with minor number 3 :-

(parted) rm 3

4. The changes start taking place as soon as you press Enter, so review the command before committing to it. After removing the partition, use the print command to confirm that it is removed from the partition table. You should also view the output of

# cat /proc/partitions

to make sure the kernel knows the partition is removed. The last step is to remove it from the /etc/fstab file. Find the line that declares the removed partition, and remove it from the file.

We can’t create a Linux partition larger than 2 TB using the fdisk command. The fdisk won’t create partitions larger than 2 TB. This is fine for desktop and laptop users, but on server you need a large partition. For example, you can’t create 3TB or 4TB partition size (RAID based) using the fdisk command. It will not allow you to create a partition that is greater than 2TB.

To solve this problem use GNU parted command with GPT. It supports Intel EFI/GPT partition tables. Partition Table (GPT) is a standard for the layout of the partition table on a physical hard disk. It is a part of the Extensible Firmware Interface (EFI) standard proposed by Intel as a replacement for the outdated PC BIOS, one of the few remaining relics of the original IBM PC. EFI uses GPT where BIOS uses a Master Boot Record (MBR).

Linux GPT Kernel Support:- EFI GUID Partition support works on both 32bit and 64bit platforms. You must include GPT support in kernel in order to use GPT. If you don’t include GPT support in Linux kernel, after rebooting the server, the file system will no longer be mountable or the GPT table will get corrupted. By default RHEL/ CentOS comes with GPT kernel support. However, if you are using Debian or Ubuntu Linux, you need to recompile the kernel. Set CONFIG_EFI_PARTITION to y to compile this feature.

7. Use the mkfs.ext3 or mkfs.ext4 command to format the file system, enter :-

# mkfs.ext4 /dev/mapper/mpathbp1

8. Type the following commands to mount /dev/mapper/mpathbp1, enter :-

# mkdir /datasrv# mount /dev/mpathbp1 /datasrv# df -hT

9. Edit in /etc/fstab file during Booting Process for Mounting.

# vim /etc/fstab

/dev/mapper/mpathbp1 /backup ext4 defaults 1 0

Note :- Make sure you replace /dev/mapper/mpathbp1 with actual RAID or Disk name or Block Ethernet device such as /dev/etherd/e0.0. Do not forget to update /etc/fstab, if necessary. Also note that booting from a GPT volume requires support in your BIOS / firmware. This is not supported on non-EFI platforms. We suggest you, boot server from another disk such as IDE / SATA / SSD disk and store data on /datasrv.

Before setting up DM-Multipath on your system, ensure that your system has been updated & includes the device-mapper-multipath package.You set up multipath with the mpathconf utility, which creates the multipath configuration file /etc/multipath.conf.

# mpathconf

a) If the /etc/multipath.conf file already exists, the mpathconf utility will edit it.b) If the /etc/multipath.conf file does not exist, the mpathconf utility will use the /usr/share/doc/device-mapper-multipath-0.4.9/multipath. conf file as the starting file.c) If the /usr/share/doc/device-mapper-multipath-0.4.9/multipath.conf file does not exist the mpathconf utility will create the /etc/multipath. conf file from scratch.

If you do not need to edit the /etc/multipath.conf file, you can set up DM-Multipath for a basic failover configuration by running the following command. This command enables the multipath configuration file and starts the multipathd daemon. If you need to edit the /etc/multipath. conf file before starting the multipathd daemon. use the following procedure to set up DM-Multipath for a basic failover configuration.

Since the value of user_friendly_name is set to yes in the configuration file, the multipath devices will be created as /dev/mapper/mpathn.

If you do not set the find_multipaths configuration parameter to yes, can use the following procedure to modify the multipath configuration file to ignore the local disks when configuring multipath.

2. Determine which disks are the internal disks and mark them as the ones to blacklist. In this example, /dev/sda is the internal disk. Note that as originally configured in the default multipath configuration file, executing the multipath -v2 shows the local disk, /dev/sda, in themultipath map.