SlideShare a Scribd company logo
Chapter 17Chapter 17
Advanced File SystemAdvanced File System
RAID Storage SystemRAID Storage System
●
Redundant Array of Inexpensive DisksRedundant Array of Inexpensive Disks
– Combine multiple small, inexpensive disk drivesCombine multiple small, inexpensive disk drives
to perform faster than a single physical diskto perform faster than a single physical disk
– Appear to the computer as a single virtual driveAppear to the computer as a single virtual drive
– Support fault-tolerance by redundantly storingSupport fault-tolerance by redundantly storing
information in various waysinformation in various ways
RAID TypesRAID Types
●
Many types of array architectures, RAID 1 ~ 6Many types of array architectures, RAID 1 ~ 6
– Different disk fault-toleranceDifferent disk fault-tolerance
– Different trade-offs in features and performanceDifferent trade-offs in features and performance
●
A non-redundant array of disk drives is oftenA non-redundant array of disk drives is often
referred to as RAID 0referred to as RAID 0
●
Only RAID 0, 1, 3 and 5 are commonly usedOnly RAID 0, 1, 3 and 5 are commonly used
– RAID 2 and 4 do not offer any significant advantages overRAID 2 and 4 do not offer any significant advantages over
these other typesthese other types
●
Certain combination is possible (10, 35 etc)Certain combination is possible (10, 35 etc)
– RAID 10 = RAID 1 + RAID 0RAID 10 = RAID 1 + RAID 0
RAID 0 - StripingRAID 0 - Striping
●
No redundancyNo redundancy
– No fault toleranceNo fault tolerance
●
High I/O performanceHigh I/O performance
– Parallel I/OParallel I/O
●
Require a minimum of 2 drives to implementRequire a minimum of 2 drives to implement
...
E
C
A
...
F
D
B
RAID 1 – MirroringRAID 1 – Mirroring
●
Provide good fault toleranceProvide good fault tolerance
– Works okay if one disk in a pair is downWorks okay if one disk in a pair is down
●
One write = a physical write on each diskOne write = a physical write on each disk
●
One read = either read both or read the less busy oneOne read = either read both or read the less busy one
– Could double the read rateCould double the read rate
●
Require a minimum of 2 drives to implementRequire a minimum of 2 drives to implement
...
C
B
A
...
C
B
A
RAID 3 - Parallel Array with ParityRAID 3 - Parallel Array with Parity
●
Fast read/writeFast read/write
●
All disk arms are synchronizedAll disk arms are synchronized
●
Speed is limited by the slowest diskSpeed is limited by the slowest disk
●
Require a minimum of 3 drives to implementRequire a minimum of 3 drives to implement
...
E
C
A
...
F
D
B
...
p
p
p
Parity Check - ConceptParity Check - Concept
●
An extra bit added to a byte to detect errors in storage orAn extra bit added to a byte to detect errors in storage or
transmissiontransmission
●
Even (odd) parity means that the parity bit is set so that thereEven (odd) parity means that the parity bit is set so that there
are an even (odd) number of one bits in the word, includingare an even (odd) number of one bits in the word, including
the parity bitthe parity bit
●
A single parity bit can only detect single bit errors since if anA single parity bit can only detect single bit errors since if an
even number of bits are wrong then the parity bit will noteven number of bits are wrong then the parity bit will not
changechange
●
It is not possible to tell which bit is wrongIt is not possible to tell which bit is wrong
...
11100010
01010011
11001100
...
00010111
11101010
00011001
...
11110101
10111001
11010101
RAID 5 – Parity CheckingRAID 5 – Parity Checking
●
For error detection, rather than full redundancyFor error detection, rather than full redundancy
●
Each stripe unit has an extra parity stripeEach stripe unit has an extra parity stripe
– Parity stripes are distributedParity stripes are distributed
●
Require a minimum of 3 drives to implementRequire a minimum of 3 drives to implement
...
p
C
A
...
E
p
B
...
F
D
p
Hardware vs. Software RAIDHardware vs. Software RAID
●
Software RAIDSoftware RAID
– Run on the server's CPURun on the server's CPU
– Directly dependent on server CPU performance and loadDirectly dependent on server CPU performance and load
– Occupies host system memory and CPU operation,Occupies host system memory and CPU operation,
degrading server performancedegrading server performance
●
Hardware RAIDHardware RAID
– Run on the RAID controller's CPURun on the RAID controller's CPU
– Does not occupy any host system memory. Is notDoes not occupy any host system memory. Is not
operating system dependentoperating system dependent
– Host CPU can execute applications while the arrayHost CPU can execute applications while the array
adapter's processor simultaneously executes arrayadapter's processor simultaneously executes array
functions: true hardware multi-taskingfunctions: true hardware multi-tasking
Array Creation withArray Creation with mdadmmdadm
●
mdadm ­h | ­­helpmdadm ­h | ­­help
●
An array can be created at install timeAn array can be created at install time
●
Create partitions with type FD (usingCreate partitions with type FD (using fdiskfdisk, or other, or other
partitioning software)partitioning software)
●
mdadm ­­create ­­helpmdadm ­­create ­­help
­C | ­­create /dev/mdX­C | ­­create /dev/mdX
­l | ­­level 0 | 1 | 4 | 5 | 6 | 10­l | ­­level 0 | 1 | 4 | 5 | 6 | 10
­n | ­­raid­devices # device [...]­n | ­­raid­devices # device [...]
­x | ­­spare­devices # device [...] ­x | ­­spare­devices # device [...] 
mdadm ­C /dev/md0 ­l 5 ­n 3 /dev/sdd1 /dev/sde1 mdadm ­C /dev/md0 ­l 5 ­n 3 /dev/sdd1 /dev/sde1 
/dev/sdf1 ­x 1 /dev/sdg1/dev/sdf1 ­x 1 /dev/sdg1
●
Create filesystemCreate filesystem
Software RAID MonitoringSoftware RAID Monitoring
●
/etc/mdadm.conf /etc/mdadm.conf 
– identify which devices are RAID devices and toidentify which devices are RAID devices and to
which ARRAY a specific device belongswhich ARRAY a specific device belongs
●
mdadm ­F | ­­follow | ­­monitormdadm ­F | ­­follow | ­­monitor
●
/proc/mdstat /proc/mdstat 
– real-time information and status about softwarereal-time information and status about software
RAID arrays and devicesRAID arrays and devices
Software RAID Control and DisplaySoftware RAID Control and Display
●
mdadm ­­managemdadm ­­manage
– ­f | ­­fail | ­­set­faulty­f | ­­fail | ­­set­faulty
– ­r | ­­remove­r | ­­remove
– ­a | ­­add­a | ­­add
●
mdadm ­­growmdadm ­­grow
●
mdadm ­­miscmdadm ­­misc
– ­Q | ­­query­Q | ­­query
– ­D | ­­detail­D | ­­detail
– ­o | ­­readonly­o | ­­readonly
– ­w | ­­readwrite­w | ­­readwrite
Failed Drive ReplacementFailed Drive Replacement
●
Fail, remove and add device withFail, remove and add device with mdadmmdadm
– mdadm ­­manage /dev/md0 ­f /dev/sdc1mdadm ­­manage /dev/md0 ­f /dev/sdc1
– mdadm ­­manage /dev/md0 ­r /dev/sdc1mdadm ­­manage /dev/md0 ­r /dev/sdc1
– mdadm ­­manage /dev/md0 ­a /dev/sdc1mdadm ­­manage /dev/md0 ­a /dev/sdc1
LVMLVM
●
Logical Volume ManagementLogical Volume Management
– Allow a single volume distributed across more thanAllow a single volume distributed across more than
one physical device, to form a larger file system sizeone physical device, to form a larger file system size
beyond device limitation.beyond device limitation.
– Flexibility on resizing or moving file systemFlexibility on resizing or moving file system, reduce, reduce
down time cost on file system migration.down time cost on file system migration.
●
All file systems exceptAll file systems except /boot//boot/ can live oncan live on
LVMLVM
– GRUB limitationGRUB limitation
– GRUB2 can handleGRUB2 can handle /boot/boot on LVMon LVM
LVM ComponentsLVM Components
●
Physical Volume (PV)Physical Volume (PV)
– A single device, like partition, disk, etc.A single device, like partition, disk, etc.
●
Volume Group (VG)Volume Group (VG)
– One or more PVs to form a VGOne or more PVs to form a VG
●
Physical Extend (PE)Physical Extend (PE)
– The basic consuming unit size divided from PVs whileThe basic consuming unit size divided from PVs while
joining a VGjoining a VG
●
Logical Volume (PV)Logical Volume (PV)
– Combination of PEs, can be used as block deviceCombination of PEs, can be used as block device
●
Logical Extend (LE)Logical Extend (LE)
– The PEs assigned to LVThe PEs assigned to LV
Implementing LVMImplementing LVM
●
Create partitionsCreate partitions
– fdisk /dev/devicefdisk /dev/device (Partition type 8E)(Partition type 8E)
– partproblepartproble
●
Create Physical VolumesCreate Physical Volumes
– pvcreate /dev/device ...pvcreate /dev/device ...
●
Create Volume GroupCreate Volume Group
– vgcreate VGname /dev/device ...vgcreate VGname /dev/device ...
Creating Logical VolumesCreating Logical Volumes
●
Create Logical VolumesCreate Logical Volumes
– lvcreate ­l extents ­n LVname VGnamelvcreate ­l extents ­n LVname VGname
– lvcreate ­L size ­n LVname VGnamelvcreate ­L size ­n LVname VGname
●
Create filesystemsCreate filesystems
– mkfs ­t file_system_type devicemkfs ­t file_system_type device
●
Mount the Logical Volume and testMount the Logical Volume and test
– EditEdit /etc/fstab/etc/fstab for persistencefor persistence
– RunRun mount ­amount ­a
Manipulating VGs & LVsManipulating VGs & LVs
●
ViewingViewing
– pvdisplay, vgdisplay, lvdisplay, lvmdiskscanpvdisplay, vgdisplay, lvdisplay, lvmdiskscan
– pvs, vgs, lvspvs, vgs, lvs
●
ResizingResizing
– vgreduce, vgextend, pvresizevgreduce, vgextend, pvresize
– lvreduce, lvextend, lvresizelvreduce, lvextend, lvresize
– resize2fsresize2fs
●
Moving PVs and VGsMoving PVs and VGs
– vgchange vgchange 
●
change attributes of a VGchange attributes of a VG
– vgexport & vgimport vgexport & vgimport 
●
move VGs between systemsmove VGs between systems
– pvmove pvmove 
●
move PEs between PVsmove PEs between PVs
LVM ImplementationLVM Implementation
●
Physical VolumePhysical Volume
– (Partition ID: x8e)(Partition ID: x8e)
PV PVPVPV
LVM ImplementationLVM Implementation
●
Volume GroupVolume Group
– One or more PVsOne or more PVs
PV PVPVPV
VG
LVM ImplementationLVM Implementation
●
Physical ExtendPhysical Extend
– Divided from VGDivided from VG
PV PVPVPV
PE
LVM ImplementationLVM Implementation
●
Logical VolumeLogical Volume
– Allocating PEsAllocating PEs
PV PVPVPV
VG
LV
LV
LV
LVM ImplementationLVM Implementation
●
lvreducelvreduce
– Releasing PEsReleasing PEs
PV PVPVPV
VG
LV
LVLV
LVM ImplementationLVM Implementation
●
lvextentlvextent
– Allocate more free PEsAllocate more free PEs
PV PVPVPV
VG
LV
LVLV
LVM ImplementationLVM Implementation
●
vgextentvgextent
– Joining new PV to make more PEsJoining new PV to make more PEs
PVPV PVPVPV
VG
LV
LVLV
LVM ImplementationLVM Implementation
●
pvmovepvmove
– Move PEs from one PV to other PVsMove PEs from one PV to other PVs
PVPV PVPVPV
VG
LV LV
LV
LVM ImplementationLVM Implementation
●
vgreducevgreduce
– Detach a PV from VGDetach a PV from VG
PVPV PVPVPV
VG
LV LV
LV
Device MapperDevice Mapper
●
In the Linux Kernel 2.6, the LVM2 is implemented inIn the Linux Kernel 2.6, the LVM2 is implemented in
terms of the device mapperterms of the device mapper
●
A simple block-level scheme for creating virtualA simple block-level scheme for creating virtual
block devices and mapping their contents onto otherblock devices and mapping their contents onto other
block devicesblock devices
●
Allows its I/O redirection services to be shared withAllows its I/O redirection services to be shared with
other volume managers (such as EVMS)other volume managers (such as EVMS)
●
SAN multipathing provides redundancy andSAN multipathing provides redundancy and
increased throughput, device-mapper providesincreased throughput, device-mapper provides
vendor-neutral multipathing configurationvendor-neutral multipathing configuration
●
Device files are located in /dev/mapperDevice files are located in /dev/mapper

More Related Content

What's hot

LSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVMLSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVM
Marian Marinov
 
Comparison of-foss-distributed-storage
Comparison of-foss-distributed-storageComparison of-foss-distributed-storage
Comparison of-foss-distributed-storage
Marian Marinov
 
First steps on CentOs7
First steps on CentOs7First steps on CentOs7
First steps on CentOs7
Marc Cortinas Val
 
LSA2 - 02 Control Groups
LSA2 - 02   Control GroupsLSA2 - 02   Control Groups
LSA2 - 02 Control Groups
Marian Marinov
 
Linux: LVM
Linux: LVMLinux: LVM
Linux: LVM
Michal Sedlak
 
Kernel Recipes 2015 - Hardened kernels for everyone
Kernel Recipes 2015 - Hardened kernels for everyoneKernel Recipes 2015 - Hardened kernels for everyone
Kernel Recipes 2015 - Hardened kernels for everyone
Anne Nicolas
 
Linux kernel debugging
Linux kernel debuggingLinux kernel debugging
Linux kernel debugging
libfetion
 
Let's trace Linux Lernel with KGDB @ COSCUP 2021
Let's trace Linux Lernel with KGDB @ COSCUP 2021Let's trace Linux Lernel with KGDB @ COSCUP 2021
Let's trace Linux Lernel with KGDB @ COSCUP 2021
Jian-Hong Pan
 
Kgdb kdb modesetting
Kgdb kdb modesettingKgdb kdb modesetting
Kgdb kdb modesetting
Kaushal Kumar Gupta
 
Systemd for developers
Systemd for developersSystemd for developers
Systemd for developers
Alison Chaiken
 
Reconnaissance of Virtio: What’s new and how it’s all connected?
Reconnaissance of Virtio: What’s new and how it’s all connected?Reconnaissance of Virtio: What’s new and how it’s all connected?
Reconnaissance of Virtio: What’s new and how it’s all connected?
Samsung Open Source Group
 
Systemd: the modern Linux init system you will learn to love
Systemd: the modern Linux init system you will learn to loveSystemd: the modern Linux init system you will learn to love
Systemd: the modern Linux init system you will learn to love
Alison Chaiken
 
CLUG 2010 09 - systemd - the new init system
CLUG 2010 09 - systemd - the new init systemCLUG 2010 09 - systemd - the new init system
CLUG 2010 09 - systemd - the new init system
PaulWay
 
Containers with systemd-nspawn
Containers with systemd-nspawnContainers with systemd-nspawn
Containers with systemd-nspawn
Gábor Nyers
 
Introduction to systemd
Introduction to systemdIntroduction to systemd
Introduction to systemd
Yusaku OGAWA
 
Linux SD/MMC device driver
Linux SD/MMC device driverLinux SD/MMC device driver
Linux SD/MMC device driver
艾鍗科技
 
Linux fundamental - Chap 16 System Rescue
Linux fundamental - Chap 16 System RescueLinux fundamental - Chap 16 System Rescue
Linux fundamental - Chap 16 System Rescue
Kenny (netman)
 
Linux LVM Logical Volume Management
Linux LVM Logical Volume ManagementLinux LVM Logical Volume Management
Linux LVM Logical Volume Management
Manolis Kartsonakis
 

What's hot (20)

LSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVMLSA2 - 01 Virtualization with KVM
LSA2 - 01 Virtualization with KVM
 
Comparison of-foss-distributed-storage
Comparison of-foss-distributed-storageComparison of-foss-distributed-storage
Comparison of-foss-distributed-storage
 
First steps on CentOs7
First steps on CentOs7First steps on CentOs7
First steps on CentOs7
 
4. storage lvm
4. storage   lvm4. storage   lvm
4. storage lvm
 
FUSE Filesystems
FUSE FilesystemsFUSE Filesystems
FUSE Filesystems
 
LSA2 - 02 Control Groups
LSA2 - 02   Control GroupsLSA2 - 02   Control Groups
LSA2 - 02 Control Groups
 
Linux: LVM
Linux: LVMLinux: LVM
Linux: LVM
 
Kernel Recipes 2015 - Hardened kernels for everyone
Kernel Recipes 2015 - Hardened kernels for everyoneKernel Recipes 2015 - Hardened kernels for everyone
Kernel Recipes 2015 - Hardened kernels for everyone
 
Linux kernel debugging
Linux kernel debuggingLinux kernel debugging
Linux kernel debugging
 
Let's trace Linux Lernel with KGDB @ COSCUP 2021
Let's trace Linux Lernel with KGDB @ COSCUP 2021Let's trace Linux Lernel with KGDB @ COSCUP 2021
Let's trace Linux Lernel with KGDB @ COSCUP 2021
 
Kgdb kdb modesetting
Kgdb kdb modesettingKgdb kdb modesetting
Kgdb kdb modesetting
 
Systemd for developers
Systemd for developersSystemd for developers
Systemd for developers
 
Reconnaissance of Virtio: What’s new and how it’s all connected?
Reconnaissance of Virtio: What’s new and how it’s all connected?Reconnaissance of Virtio: What’s new and how it’s all connected?
Reconnaissance of Virtio: What’s new and how it’s all connected?
 
Systemd: the modern Linux init system you will learn to love
Systemd: the modern Linux init system you will learn to loveSystemd: the modern Linux init system you will learn to love
Systemd: the modern Linux init system you will learn to love
 
CLUG 2010 09 - systemd - the new init system
CLUG 2010 09 - systemd - the new init systemCLUG 2010 09 - systemd - the new init system
CLUG 2010 09 - systemd - the new init system
 
Containers with systemd-nspawn
Containers with systemd-nspawnContainers with systemd-nspawn
Containers with systemd-nspawn
 
Introduction to systemd
Introduction to systemdIntroduction to systemd
Introduction to systemd
 
Linux SD/MMC device driver
Linux SD/MMC device driverLinux SD/MMC device driver
Linux SD/MMC device driver
 
Linux fundamental - Chap 16 System Rescue
Linux fundamental - Chap 16 System RescueLinux fundamental - Chap 16 System Rescue
Linux fundamental - Chap 16 System Rescue
 
Linux LVM Logical Volume Management
Linux LVM Logical Volume ManagementLinux LVM Logical Volume Management
Linux LVM Logical Volume Management
 

Viewers also liked

Chap 18 net
Chap 18 netChap 18 net
Chap 18 net
Kenny (netman)
 
Ras pioverview
Ras pioverviewRas pioverview
Ras pioverviewAlec Clews
 
Unix tutorial-08
Unix tutorial-08Unix tutorial-08
Unix tutorial-08
Tushar Jain
 
Linux pipe & redirection
Linux pipe & redirectionLinux pipe & redirection
Linux pipe & redirection
Colin Su
 
Linux network monitoring hands-on pratice
Linux network monitoring hands-on praticeLinux network monitoring hands-on pratice
Linux network monitoring hands-on pratice
Kenny (netman)
 
Basics of-linux
Basics of-linuxBasics of-linux
Basics of-linux
Singsys Pte Ltd
 
Linux fundamentals
Linux fundamentalsLinux fundamentals
Linux fundamentals
chakrikolla
 
Your first linux programs
Your first linux programsYour first linux programs
Your first linux programs
Dr. Ahmed Al Zaidy
 
Power point (asking permission)
Power point (asking permission)Power point (asking permission)
Power point (asking permission)ahmaddarda1505
 
Linux fundamental - Chap 05 filter
Linux fundamental - Chap 05 filterLinux fundamental - Chap 05 filter
Linux fundamental - Chap 05 filter
Kenny (netman)
 
Linux fundamental - Chap 13 account management
Linux fundamental - Chap 13 account managementLinux fundamental - Chap 13 account management
Linux fundamental - Chap 13 account management
Kenny (netman)
 
Linux fundamental - Chap 09 pkg
Linux fundamental - Chap 09 pkgLinux fundamental - Chap 09 pkg
Linux fundamental - Chap 09 pkg
Kenny (netman)
 
Linux fundamental - Chap 14 shell script
Linux fundamental - Chap 14 shell scriptLinux fundamental - Chap 14 shell script
Linux fundamental - Chap 14 shell script
Kenny (netman)
 
Linux fundamental - Chap 02 perm
Linux fundamental - Chap 02 permLinux fundamental - Chap 02 perm
Linux fundamental - Chap 02 perm
Kenny (netman)
 
Linux-Permission
Linux-PermissionLinux-Permission
Linux-Permission
Colin Su
 
Importance of linux system fundamental in technical documentation reading
Importance of linux system fundamental in technical documentation readingImportance of linux system fundamental in technical documentation reading
Importance of linux system fundamental in technical documentation reading
Kenny (netman)
 
Linux files and file permission
Linux files and file permissionLinux files and file permission
Linux files and file permissionU.P Police
 
Red Hat Certified engineer course
  Red Hat Certified engineer course   Red Hat Certified engineer course
Red Hat Certified engineer course
Ali Abdo
 

Viewers also liked (20)

Chap 18 net
Chap 18 netChap 18 net
Chap 18 net
 
Ras pioverview
Ras pioverviewRas pioverview
Ras pioverview
 
Unix tutorial-08
Unix tutorial-08Unix tutorial-08
Unix tutorial-08
 
Linux pipe & redirection
Linux pipe & redirectionLinux pipe & redirection
Linux pipe & redirection
 
Linux Commands
Linux CommandsLinux Commands
Linux Commands
 
Linux network monitoring hands-on pratice
Linux network monitoring hands-on praticeLinux network monitoring hands-on pratice
Linux network monitoring hands-on pratice
 
Basics of-linux
Basics of-linuxBasics of-linux
Basics of-linux
 
Linux fundamentals
Linux fundamentalsLinux fundamentals
Linux fundamentals
 
Your first linux programs
Your first linux programsYour first linux programs
Your first linux programs
 
Power point (asking permission)
Power point (asking permission)Power point (asking permission)
Power point (asking permission)
 
Unix - Filters/Editors
Unix - Filters/EditorsUnix - Filters/Editors
Unix - Filters/Editors
 
Linux fundamental - Chap 05 filter
Linux fundamental - Chap 05 filterLinux fundamental - Chap 05 filter
Linux fundamental - Chap 05 filter
 
Linux fundamental - Chap 13 account management
Linux fundamental - Chap 13 account managementLinux fundamental - Chap 13 account management
Linux fundamental - Chap 13 account management
 
Linux fundamental - Chap 09 pkg
Linux fundamental - Chap 09 pkgLinux fundamental - Chap 09 pkg
Linux fundamental - Chap 09 pkg
 
Linux fundamental - Chap 14 shell script
Linux fundamental - Chap 14 shell scriptLinux fundamental - Chap 14 shell script
Linux fundamental - Chap 14 shell script
 
Linux fundamental - Chap 02 perm
Linux fundamental - Chap 02 permLinux fundamental - Chap 02 perm
Linux fundamental - Chap 02 perm
 
Linux-Permission
Linux-PermissionLinux-Permission
Linux-Permission
 
Importance of linux system fundamental in technical documentation reading
Importance of linux system fundamental in technical documentation readingImportance of linux system fundamental in technical documentation reading
Importance of linux system fundamental in technical documentation reading
 
Linux files and file permission
Linux files and file permissionLinux files and file permission
Linux files and file permission
 
Red Hat Certified engineer course
  Red Hat Certified engineer course   Red Hat Certified engineer course
Red Hat Certified engineer course
 

Similar to Chap 17 advfs

Raid
Raid Raid
GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...
GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...
GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...
TSOLUTIONS
 
logical volume manager.ppt
logical volume manager.pptlogical volume manager.ppt
logical volume manager.ppt
Pandiya Rajan
 
Open Source Data Deduplication
Open Source Data DeduplicationOpen Source Data Deduplication
Open Source Data Deduplication
RedWireServices
 
The Unofficial VCAP / VCP VMware Study Guide
The Unofficial VCAP / VCP VMware Study GuideThe Unofficial VCAP / VCP VMware Study Guide
The Unofficial VCAP / VCP VMware Study Guide
Veeam Software
 
Raid
RaidRaid
Performance evolution of raid
Performance evolution of raidPerformance evolution of raid
Performance evolution of raid
Zubair Sami
 
Understanding RAID Controller
Understanding RAID ControllerUnderstanding RAID Controller
Understanding RAID Controller
Raid Data Recovery
 
Demystifying Storage - Building large SANs
Demystifying  Storage - Building large SANsDemystifying  Storage - Building large SANs
Demystifying Storage - Building large SANs
Directi Group
 
RAID CAAL
RAID CAALRAID CAAL
RAID CAAL
GumballXD49
 
What is R.A.I.D?
What is R.A.I.D?What is R.A.I.D?
What is R.A.I.D?
Sumit kumar
 
Repositories as Code
Repositories as CodeRepositories as Code
Repositories as Code
Kris Buytaert
 
Windows internals Essentials
Windows internals EssentialsWindows internals Essentials
Windows internals Essentials
John Ombagi
 

Similar to Chap 17 advfs (20)

Raid
Raid Raid
Raid
 
Raid level
Raid levelRaid level
Raid level
 
GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...
GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...
GeoVision : CCTV Solutions : RAID vs Non-RAID System for Storing Surveillance...
 
Raid
RaidRaid
Raid
 
Firebird and RAID
Firebird and RAIDFirebird and RAID
Firebird and RAID
 
RAID
RAIDRAID
RAID
 
Raid+controllers
Raid+controllersRaid+controllers
Raid+controllers
 
logical volume manager.ppt
logical volume manager.pptlogical volume manager.ppt
logical volume manager.ppt
 
1.2 raid
1.2  raid1.2  raid
1.2 raid
 
SEMINAR
SEMINARSEMINAR
SEMINAR
 
Open Source Data Deduplication
Open Source Data DeduplicationOpen Source Data Deduplication
Open Source Data Deduplication
 
The Unofficial VCAP / VCP VMware Study Guide
The Unofficial VCAP / VCP VMware Study GuideThe Unofficial VCAP / VCP VMware Study Guide
The Unofficial VCAP / VCP VMware Study Guide
 
Raid
RaidRaid
Raid
 
Performance evolution of raid
Performance evolution of raidPerformance evolution of raid
Performance evolution of raid
 
Understanding RAID Controller
Understanding RAID ControllerUnderstanding RAID Controller
Understanding RAID Controller
 
Demystifying Storage - Building large SANs
Demystifying  Storage - Building large SANsDemystifying  Storage - Building large SANs
Demystifying Storage - Building large SANs
 
RAID CAAL
RAID CAALRAID CAAL
RAID CAAL
 
What is R.A.I.D?
What is R.A.I.D?What is R.A.I.D?
What is R.A.I.D?
 
Repositories as Code
Repositories as CodeRepositories as Code
Repositories as Code
 
Windows internals Essentials
Windows internals EssentialsWindows internals Essentials
Windows internals Essentials
 

More from Kenny (netman)

rpi_audio configuration steps
rpi_audio configuration stepsrpi_audio configuration steps
rpi_audio configuration steps
Kenny (netman)
 
Rpi audio
Rpi audioRpi audio
Rpi audio
Kenny (netman)
 
About the Course
About the CourseAbout the Course
About the Course
Kenny (netman)
 
Linux fundamental - Chap 15 Job Scheduling
Linux fundamental - Chap 15 Job SchedulingLinux fundamental - Chap 15 Job Scheduling
Linux fundamental - Chap 15 Job Scheduling
Kenny (netman)
 
Linux fundamental - Chap 07 vi
Linux fundamental - Chap 07 viLinux fundamental - Chap 07 vi
Linux fundamental - Chap 07 vi
Kenny (netman)
 
Linux fundamental - Chap 06 regx
Linux fundamental - Chap 06 regxLinux fundamental - Chap 06 regx
Linux fundamental - Chap 06 regx
Kenny (netman)
 
Linux fundamental - Chap 04 archive
Linux fundamental - Chap 04 archiveLinux fundamental - Chap 04 archive
Linux fundamental - Chap 04 archive
Kenny (netman)
 
Linux fundamental - Chap 03 file
Linux fundamental - Chap 03 fileLinux fundamental - Chap 03 file
Linux fundamental - Chap 03 file
Kenny (netman)
 
Linux fundamental - Chap 00 shell
Linux fundamental - Chap 00 shellLinux fundamental - Chap 00 shell
Linux fundamental - Chap 00 shell
Kenny (netman)
 
Linux system security
Linux system securityLinux system security
Linux system security
Kenny (netman)
 
Linux Network Monitoring
Linux Network MonitoringLinux Network Monitoring
Linux Network Monitoring
Kenny (netman)
 
加密應用(GPG)
加密應用(GPG)加密應用(GPG)
加密應用(GPG)
Kenny (netman)
 
金鑰管理 (PKI)
金鑰管理 (PKI)金鑰管理 (PKI)
金鑰管理 (PKI)
Kenny (netman)
 
Linux firewall
Linux firewallLinux firewall
Linux firewall
Kenny (netman)
 

More from Kenny (netman) (14)

rpi_audio configuration steps
rpi_audio configuration stepsrpi_audio configuration steps
rpi_audio configuration steps
 
Rpi audio
Rpi audioRpi audio
Rpi audio
 
About the Course
About the CourseAbout the Course
About the Course
 
Linux fundamental - Chap 15 Job Scheduling
Linux fundamental - Chap 15 Job SchedulingLinux fundamental - Chap 15 Job Scheduling
Linux fundamental - Chap 15 Job Scheduling
 
Linux fundamental - Chap 07 vi
Linux fundamental - Chap 07 viLinux fundamental - Chap 07 vi
Linux fundamental - Chap 07 vi
 
Linux fundamental - Chap 06 regx
Linux fundamental - Chap 06 regxLinux fundamental - Chap 06 regx
Linux fundamental - Chap 06 regx
 
Linux fundamental - Chap 04 archive
Linux fundamental - Chap 04 archiveLinux fundamental - Chap 04 archive
Linux fundamental - Chap 04 archive
 
Linux fundamental - Chap 03 file
Linux fundamental - Chap 03 fileLinux fundamental - Chap 03 file
Linux fundamental - Chap 03 file
 
Linux fundamental - Chap 00 shell
Linux fundamental - Chap 00 shellLinux fundamental - Chap 00 shell
Linux fundamental - Chap 00 shell
 
Linux system security
Linux system securityLinux system security
Linux system security
 
Linux Network Monitoring
Linux Network MonitoringLinux Network Monitoring
Linux Network Monitoring
 
加密應用(GPG)
加密應用(GPG)加密應用(GPG)
加密應用(GPG)
 
金鑰管理 (PKI)
金鑰管理 (PKI)金鑰管理 (PKI)
金鑰管理 (PKI)
 
Linux firewall
Linux firewallLinux firewall
Linux firewall
 

Recently uploaded

Supporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptxSupporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptx
Jisc
 
Operation Blue Star - Saka Neela Tara
Operation Blue Star   -  Saka Neela TaraOperation Blue Star   -  Saka Neela Tara
Operation Blue Star - Saka Neela Tara
Balvir Singh
 
Palestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptxPalestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptx
RaedMohamed3
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Thiyagu K
 
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdfAdversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Po-Chuan Chen
 
Additional Benefits for Employee Website.pdf
Additional Benefits for Employee Website.pdfAdditional Benefits for Employee Website.pdf
Additional Benefits for Employee Website.pdf
joachimlavalley1
 
The Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdfThe Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdf
kaushalkr1407
 
The geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideasThe geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideas
GeoBlogs
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
camakaiclarkmusic
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
Sandy Millin
 
Polish students' mobility in the Czech Republic
Polish students' mobility in the Czech RepublicPolish students' mobility in the Czech Republic
Polish students' mobility in the Czech Republic
Anna Sz.
 
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th SemesterGuidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Atul Kumar Singh
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
Celine George
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
EugeneSaldivar
 
special B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdfspecial B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdf
Special education needs
 
"Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe..."Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe...
SACHIN R KONDAGURI
 
678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf
CarlosHernanMontoyab2
 
The Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptxThe Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptx
DhatriParmar
 
How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...
Jisc
 
The Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official PublicationThe Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official Publication
Delapenabediema
 

Recently uploaded (20)

Supporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptxSupporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptx
 
Operation Blue Star - Saka Neela Tara
Operation Blue Star   -  Saka Neela TaraOperation Blue Star   -  Saka Neela Tara
Operation Blue Star - Saka Neela Tara
 
Palestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptxPalestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptx
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
 
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdfAdversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
 
Additional Benefits for Employee Website.pdf
Additional Benefits for Employee Website.pdfAdditional Benefits for Employee Website.pdf
Additional Benefits for Employee Website.pdf
 
The Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdfThe Roman Empire A Historical Colossus.pdf
The Roman Empire A Historical Colossus.pdf
 
The geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideasThe geography of Taylor Swift - some ideas
The geography of Taylor Swift - some ideas
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
 
Polish students' mobility in the Czech Republic
Polish students' mobility in the Czech RepublicPolish students' mobility in the Czech Republic
Polish students' mobility in the Czech Republic
 
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th SemesterGuidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th Semester
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
 
special B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdfspecial B.ed 2nd year old paper_20240531.pdf
special B.ed 2nd year old paper_20240531.pdf
 
"Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe..."Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe...
 
678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf
 
The Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptxThe Accursed House by Émile Gaboriau.pptx
The Accursed House by Émile Gaboriau.pptx
 
How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...How libraries can support authors with open access requirements for UKRI fund...
How libraries can support authors with open access requirements for UKRI fund...
 
The Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official PublicationThe Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official Publication
 

Chap 17 advfs

  • 1. Chapter 17Chapter 17 Advanced File SystemAdvanced File System
  • 2. RAID Storage SystemRAID Storage System ● Redundant Array of Inexpensive DisksRedundant Array of Inexpensive Disks – Combine multiple small, inexpensive disk drivesCombine multiple small, inexpensive disk drives to perform faster than a single physical diskto perform faster than a single physical disk – Appear to the computer as a single virtual driveAppear to the computer as a single virtual drive – Support fault-tolerance by redundantly storingSupport fault-tolerance by redundantly storing information in various waysinformation in various ways
  • 3. RAID TypesRAID Types ● Many types of array architectures, RAID 1 ~ 6Many types of array architectures, RAID 1 ~ 6 – Different disk fault-toleranceDifferent disk fault-tolerance – Different trade-offs in features and performanceDifferent trade-offs in features and performance ● A non-redundant array of disk drives is oftenA non-redundant array of disk drives is often referred to as RAID 0referred to as RAID 0 ● Only RAID 0, 1, 3 and 5 are commonly usedOnly RAID 0, 1, 3 and 5 are commonly used – RAID 2 and 4 do not offer any significant advantages overRAID 2 and 4 do not offer any significant advantages over these other typesthese other types ● Certain combination is possible (10, 35 etc)Certain combination is possible (10, 35 etc) – RAID 10 = RAID 1 + RAID 0RAID 10 = RAID 1 + RAID 0
  • 4. RAID 0 - StripingRAID 0 - Striping ● No redundancyNo redundancy – No fault toleranceNo fault tolerance ● High I/O performanceHigh I/O performance – Parallel I/OParallel I/O ● Require a minimum of 2 drives to implementRequire a minimum of 2 drives to implement ... E C A ... F D B
  • 5. RAID 1 – MirroringRAID 1 – Mirroring ● Provide good fault toleranceProvide good fault tolerance – Works okay if one disk in a pair is downWorks okay if one disk in a pair is down ● One write = a physical write on each diskOne write = a physical write on each disk ● One read = either read both or read the less busy oneOne read = either read both or read the less busy one – Could double the read rateCould double the read rate ● Require a minimum of 2 drives to implementRequire a minimum of 2 drives to implement ... C B A ... C B A
  • 6. RAID 3 - Parallel Array with ParityRAID 3 - Parallel Array with Parity ● Fast read/writeFast read/write ● All disk arms are synchronizedAll disk arms are synchronized ● Speed is limited by the slowest diskSpeed is limited by the slowest disk ● Require a minimum of 3 drives to implementRequire a minimum of 3 drives to implement ... E C A ... F D B ... p p p
  • 7. Parity Check - ConceptParity Check - Concept ● An extra bit added to a byte to detect errors in storage orAn extra bit added to a byte to detect errors in storage or transmissiontransmission ● Even (odd) parity means that the parity bit is set so that thereEven (odd) parity means that the parity bit is set so that there are an even (odd) number of one bits in the word, includingare an even (odd) number of one bits in the word, including the parity bitthe parity bit ● A single parity bit can only detect single bit errors since if anA single parity bit can only detect single bit errors since if an even number of bits are wrong then the parity bit will noteven number of bits are wrong then the parity bit will not changechange ● It is not possible to tell which bit is wrongIt is not possible to tell which bit is wrong ... 11100010 01010011 11001100 ... 00010111 11101010 00011001 ... 11110101 10111001 11010101
  • 8. RAID 5 – Parity CheckingRAID 5 – Parity Checking ● For error detection, rather than full redundancyFor error detection, rather than full redundancy ● Each stripe unit has an extra parity stripeEach stripe unit has an extra parity stripe – Parity stripes are distributedParity stripes are distributed ● Require a minimum of 3 drives to implementRequire a minimum of 3 drives to implement ... p C A ... E p B ... F D p
  • 9. Hardware vs. Software RAIDHardware vs. Software RAID ● Software RAIDSoftware RAID – Run on the server's CPURun on the server's CPU – Directly dependent on server CPU performance and loadDirectly dependent on server CPU performance and load – Occupies host system memory and CPU operation,Occupies host system memory and CPU operation, degrading server performancedegrading server performance ● Hardware RAIDHardware RAID – Run on the RAID controller's CPURun on the RAID controller's CPU – Does not occupy any host system memory. Is notDoes not occupy any host system memory. Is not operating system dependentoperating system dependent – Host CPU can execute applications while the arrayHost CPU can execute applications while the array adapter's processor simultaneously executes arrayadapter's processor simultaneously executes array functions: true hardware multi-taskingfunctions: true hardware multi-tasking
  • 10. Array Creation withArray Creation with mdadmmdadm ● mdadm ­h | ­­helpmdadm ­h | ­­help ● An array can be created at install timeAn array can be created at install time ● Create partitions with type FD (usingCreate partitions with type FD (using fdiskfdisk, or other, or other partitioning software)partitioning software) ● mdadm ­­create ­­helpmdadm ­­create ­­help ­C | ­­create /dev/mdX­C | ­­create /dev/mdX ­l | ­­level 0 | 1 | 4 | 5 | 6 | 10­l | ­­level 0 | 1 | 4 | 5 | 6 | 10 ­n | ­­raid­devices # device [...]­n | ­­raid­devices # device [...] ­x | ­­spare­devices # device [...] ­x | ­­spare­devices # device [...]  mdadm ­C /dev/md0 ­l 5 ­n 3 /dev/sdd1 /dev/sde1 mdadm ­C /dev/md0 ­l 5 ­n 3 /dev/sdd1 /dev/sde1  /dev/sdf1 ­x 1 /dev/sdg1/dev/sdf1 ­x 1 /dev/sdg1 ● Create filesystemCreate filesystem
  • 11. Software RAID MonitoringSoftware RAID Monitoring ● /etc/mdadm.conf /etc/mdadm.conf  – identify which devices are RAID devices and toidentify which devices are RAID devices and to which ARRAY a specific device belongswhich ARRAY a specific device belongs ● mdadm ­F | ­­follow | ­­monitormdadm ­F | ­­follow | ­­monitor ● /proc/mdstat /proc/mdstat  – real-time information and status about softwarereal-time information and status about software RAID arrays and devicesRAID arrays and devices
  • 12. Software RAID Control and DisplaySoftware RAID Control and Display ● mdadm ­­managemdadm ­­manage – ­f | ­­fail | ­­set­faulty­f | ­­fail | ­­set­faulty – ­r | ­­remove­r | ­­remove – ­a | ­­add­a | ­­add ● mdadm ­­growmdadm ­­grow ● mdadm ­­miscmdadm ­­misc – ­Q | ­­query­Q | ­­query – ­D | ­­detail­D | ­­detail – ­o | ­­readonly­o | ­­readonly – ­w | ­­readwrite­w | ­­readwrite
  • 13. Failed Drive ReplacementFailed Drive Replacement ● Fail, remove and add device withFail, remove and add device with mdadmmdadm – mdadm ­­manage /dev/md0 ­f /dev/sdc1mdadm ­­manage /dev/md0 ­f /dev/sdc1 – mdadm ­­manage /dev/md0 ­r /dev/sdc1mdadm ­­manage /dev/md0 ­r /dev/sdc1 – mdadm ­­manage /dev/md0 ­a /dev/sdc1mdadm ­­manage /dev/md0 ­a /dev/sdc1
  • 14. LVMLVM ● Logical Volume ManagementLogical Volume Management – Allow a single volume distributed across more thanAllow a single volume distributed across more than one physical device, to form a larger file system sizeone physical device, to form a larger file system size beyond device limitation.beyond device limitation. – Flexibility on resizing or moving file systemFlexibility on resizing or moving file system, reduce, reduce down time cost on file system migration.down time cost on file system migration. ● All file systems exceptAll file systems except /boot//boot/ can live oncan live on LVMLVM – GRUB limitationGRUB limitation – GRUB2 can handleGRUB2 can handle /boot/boot on LVMon LVM
  • 15. LVM ComponentsLVM Components ● Physical Volume (PV)Physical Volume (PV) – A single device, like partition, disk, etc.A single device, like partition, disk, etc. ● Volume Group (VG)Volume Group (VG) – One or more PVs to form a VGOne or more PVs to form a VG ● Physical Extend (PE)Physical Extend (PE) – The basic consuming unit size divided from PVs whileThe basic consuming unit size divided from PVs while joining a VGjoining a VG ● Logical Volume (PV)Logical Volume (PV) – Combination of PEs, can be used as block deviceCombination of PEs, can be used as block device ● Logical Extend (LE)Logical Extend (LE) – The PEs assigned to LVThe PEs assigned to LV
  • 16. Implementing LVMImplementing LVM ● Create partitionsCreate partitions – fdisk /dev/devicefdisk /dev/device (Partition type 8E)(Partition type 8E) – partproblepartproble ● Create Physical VolumesCreate Physical Volumes – pvcreate /dev/device ...pvcreate /dev/device ... ● Create Volume GroupCreate Volume Group – vgcreate VGname /dev/device ...vgcreate VGname /dev/device ...
  • 17. Creating Logical VolumesCreating Logical Volumes ● Create Logical VolumesCreate Logical Volumes – lvcreate ­l extents ­n LVname VGnamelvcreate ­l extents ­n LVname VGname – lvcreate ­L size ­n LVname VGnamelvcreate ­L size ­n LVname VGname ● Create filesystemsCreate filesystems – mkfs ­t file_system_type devicemkfs ­t file_system_type device ● Mount the Logical Volume and testMount the Logical Volume and test – EditEdit /etc/fstab/etc/fstab for persistencefor persistence – RunRun mount ­amount ­a
  • 18. Manipulating VGs & LVsManipulating VGs & LVs ● ViewingViewing – pvdisplay, vgdisplay, lvdisplay, lvmdiskscanpvdisplay, vgdisplay, lvdisplay, lvmdiskscan – pvs, vgs, lvspvs, vgs, lvs ● ResizingResizing – vgreduce, vgextend, pvresizevgreduce, vgextend, pvresize – lvreduce, lvextend, lvresizelvreduce, lvextend, lvresize – resize2fsresize2fs ● Moving PVs and VGsMoving PVs and VGs – vgchange vgchange  ● change attributes of a VGchange attributes of a VG – vgexport & vgimport vgexport & vgimport  ● move VGs between systemsmove VGs between systems – pvmove pvmove  ● move PEs between PVsmove PEs between PVs
  • 19. LVM ImplementationLVM Implementation ● Physical VolumePhysical Volume – (Partition ID: x8e)(Partition ID: x8e) PV PVPVPV
  • 20. LVM ImplementationLVM Implementation ● Volume GroupVolume Group – One or more PVsOne or more PVs PV PVPVPV VG
  • 21. LVM ImplementationLVM Implementation ● Physical ExtendPhysical Extend – Divided from VGDivided from VG PV PVPVPV PE
  • 22. LVM ImplementationLVM Implementation ● Logical VolumeLogical Volume – Allocating PEsAllocating PEs PV PVPVPV VG LV LV LV
  • 23. LVM ImplementationLVM Implementation ● lvreducelvreduce – Releasing PEsReleasing PEs PV PVPVPV VG LV LVLV
  • 24. LVM ImplementationLVM Implementation ● lvextentlvextent – Allocate more free PEsAllocate more free PEs PV PVPVPV VG LV LVLV
  • 25. LVM ImplementationLVM Implementation ● vgextentvgextent – Joining new PV to make more PEsJoining new PV to make more PEs PVPV PVPVPV VG LV LVLV
  • 26. LVM ImplementationLVM Implementation ● pvmovepvmove – Move PEs from one PV to other PVsMove PEs from one PV to other PVs PVPV PVPVPV VG LV LV LV
  • 27. LVM ImplementationLVM Implementation ● vgreducevgreduce – Detach a PV from VGDetach a PV from VG PVPV PVPVPV VG LV LV LV
  • 28. Device MapperDevice Mapper ● In the Linux Kernel 2.6, the LVM2 is implemented inIn the Linux Kernel 2.6, the LVM2 is implemented in terms of the device mapperterms of the device mapper ● A simple block-level scheme for creating virtualA simple block-level scheme for creating virtual block devices and mapping their contents onto otherblock devices and mapping their contents onto other block devicesblock devices ● Allows its I/O redirection services to be shared withAllows its I/O redirection services to be shared with other volume managers (such as EVMS)other volume managers (such as EVMS) ● SAN multipathing provides redundancy andSAN multipathing provides redundancy and increased throughput, device-mapper providesincreased throughput, device-mapper provides vendor-neutral multipathing configurationvendor-neutral multipathing configuration ● Device files are located in /dev/mapperDevice files are located in /dev/mapper