5. Storage Issues Troubleshooting-EX342

According to the exam objectives you will need to be able to identify issues with storage and fix them. The following are the objectives of this section  :

Diagnose and troubleshoot file system issues

  • Recover corrupted file systems

We will be testing this on our virtual server.

First : Lets prepare our disks

-Add a new hard disk to your VM

-Login to your Linux Systems

lsblk
NAME            MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda               8:0    0  20G  0 disk
├─sda1            8:1    0   1G  0 part /boot
└─sda2            8:2    0  19G  0 part
├─centos-root 253:0    0  17G  0 lvm  /
└─centos-swap 253:1    0   2G  0 lvm  [SWAP]
sdb               8:16   0  10G  0 disk

the disk is now there and it has 10 GB

Let's check the file system after its been corrupted.

Mounting the file system we will have the message wrong file system type.

To fix the error for XFS file type

We will use the command xfs_repair as follows

To fix the error for EXT4 file type

We will use the command e2fsck

Lets try to mount it ad view the file system contents

  • Recover mis-configured or broken LVM configurations

we will create LVM  then break it then attempt to identify the issues and fix them.

let's set the disk create another partition for /dev/sdb with 3 Gb

We can see now we have sdb3 available

We will create a physical volume for sdb3

Let's create a logical volume

create the volume group

Then create the logical volume

View the logical volume information

create an xfs file system

  • Recover data from encrypted file systems

  • Identify and fix iSCSI issues