SIAD 2023/2024 © PS/TC DEI/FCTUC
SIAD
Serviços e Infraestruturas
de Alto Desempenho
LVMS and ZFS
SIAD 2023/2024 © PS/TC DEI/FCTUC 2
Last week:
• RAID systems revisited
• Intelligent data storage systems
• DAS systems
• SAN systems
• Fibre Channel
• iSCSI
• FCoE
• FCIP
• NAS systems
• NFS
SIAD 2023/2024 © PS/TC DEI/FCTUC 3
This week:
• LVMS – Logical Volume Management Systems
• The concept of file system snapshot
• Block-based access vs. object-based access
• ZFS as a modern file system & its implications on the data center
SIAD 2023/2024 © PS/TC DEI/FCTUC 4
Logical Volume Manager Concepts
A virtual file system is built up from
• PV: Physical Volumes (partitions on disks that form a volume group)
• VG: Volume Groups (virtual disks)
• LV: Logical Volumes (logical volume or mountable partition)
• PE: Physical Extent (mini partitions who build up LV)
Virtual file systems are flexible
• increase/decrease ”disk-space” while running
• easily manage fast growing virtual disks
• use dynamic growing virtual disks
LV’s work like standard disk devices
• can be raided
Not dependent on single disks for storage
Take snapshots of LV’s as backup mechanism
SIAD 2023/2024 © PS/TC DEI/FCTUC 5
Logical Volume Manager Concept
• One or several disks have one or more partitions
• VG is built up from several partitions on several disks
• LV is a part of or a whole VG
• The LV may be mounted as any other disk device
MP: Mounting point
SIAD 2023/2024 © PS/TC DEI/FCTUC 6
Snapshots
Virtual read-only copy of filesystem
• Snapshot has same contents that filesystem had
when snapshot was made.
• Snapshot uses pointers to data and copy-on-write (COW)
to avoid making a copy of entire filesystem.
• Snapshots may require as few as ~1% of the size of the filesystem
SIAD 2023/2024 © PS/TC DEI/FCTUC 7
Applications of snapshots
Faster restore operations:
• snapshots take seconds to create or restore from.
• The lifetime of snapshots for this purpose
may be as short as 1 minute or as long as a few days.
• These snapshots won’t help you if disk or other hardware fails.
They are NOT backups!!!
Staging for backups:
• Snapshot filesystem before starting backup.
• Files on snapshot do not change during backup
(simpler to keep consistent backups).
• Snapshot lifetime is how long it takes to backup
SIAD 2023/2024 © PS/TC DEI/FCTUC 8
Linux LVM snapshots
Linux LVM can create snapshots of logical volumes
Example: lvcreate -L500M -s -n backup /dev/db/db1
• creates snapshot (-s) volume named backup
• volume is snapshot of /dev/db/db1 LV
• can make 500M of changes.
What happens if volume of changes exceeds 500M?
• LV can’t receive copies of old data if changes are
made to original logical volume.
• Ensure 500M is more than enough space for changes
made during lifetime of snapshot
LV snapshots vs. VM snapshots
• Similar but different concepts
• Snapshot of file systems alone does not guarantee VM snapshot
SIAD 2023/2024 © PS/TC DEI/FCTUC 9
Examples of LVMS:
LINUX LVM
• http://www.globalknowledge.com/training/videodetail.asp?pageid=2222&vid=33
• http://www.howtoforge.com/linux_lvm
Solaris Volume Manager
Veritas Volume Manager
IBM LVM
NetBSD LVM
Windows Logical Disk Manager
…
Full list: http://en.wikipedia.org/wiki/Logical_volume_management
SIAD 2023/2024 © PS/TC DEI/FCTUC 10
Ephemeral, block and object storage
Source: OpenStack Operations Guide
SIAD 2023/2024 © PS/TC DEI/FCTUC 11
ZFS as a modern filesystem
(and LVM system)
Despite the usage of LVMS, most filesystems were
not designed for current data centers.
ZFS and Btrfs are modern file systems with a few technologies
specifically designed for modern data centers.
• Joksimoski and Loskovska, Overview of Modern File Systems
http://ciit.finki.ukim.mk/data/papers/7CiiT/7CiiT-09.pdf
For a very good introduction to ZFS (despite all the hype):
• http://www.slideshare.net/mewandalmeida/zfs
(these slides will be directly used in the rest of today’s class)
• https://www.youtube.com/watch?v=0oJ0vlzeJio
(long video, but also quite good)

SIAD.T.7. DC_Storage_LVMS

  • 1.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC SIAD Serviços e Infraestruturas de Alto Desempenho LVMS and ZFS
  • 2.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 2 Last week: • RAID systems revisited • Intelligent data storage systems • DAS systems • SAN systems • Fibre Channel • iSCSI • FCoE • FCIP • NAS systems • NFS
  • 3.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 3 This week: • LVMS – Logical Volume Management Systems • The concept of file system snapshot • Block-based access vs. object-based access • ZFS as a modern file system & its implications on the data center
  • 4.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 4 Logical Volume Manager Concepts A virtual file system is built up from • PV: Physical Volumes (partitions on disks that form a volume group) • VG: Volume Groups (virtual disks) • LV: Logical Volumes (logical volume or mountable partition) • PE: Physical Extent (mini partitions who build up LV) Virtual file systems are flexible • increase/decrease ”disk-space” while running • easily manage fast growing virtual disks • use dynamic growing virtual disks LV’s work like standard disk devices • can be raided Not dependent on single disks for storage Take snapshots of LV’s as backup mechanism
  • 5.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 5 Logical Volume Manager Concept • One or several disks have one or more partitions • VG is built up from several partitions on several disks • LV is a part of or a whole VG • The LV may be mounted as any other disk device MP: Mounting point
  • 6.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 6 Snapshots Virtual read-only copy of filesystem • Snapshot has same contents that filesystem had when snapshot was made. • Snapshot uses pointers to data and copy-on-write (COW) to avoid making a copy of entire filesystem. • Snapshots may require as few as ~1% of the size of the filesystem
  • 7.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 7 Applications of snapshots Faster restore operations: • snapshots take seconds to create or restore from. • The lifetime of snapshots for this purpose may be as short as 1 minute or as long as a few days. • These snapshots won’t help you if disk or other hardware fails. They are NOT backups!!! Staging for backups: • Snapshot filesystem before starting backup. • Files on snapshot do not change during backup (simpler to keep consistent backups). • Snapshot lifetime is how long it takes to backup
  • 8.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 8 Linux LVM snapshots Linux LVM can create snapshots of logical volumes Example: lvcreate -L500M -s -n backup /dev/db/db1 • creates snapshot (-s) volume named backup • volume is snapshot of /dev/db/db1 LV • can make 500M of changes. What happens if volume of changes exceeds 500M? • LV can’t receive copies of old data if changes are made to original logical volume. • Ensure 500M is more than enough space for changes made during lifetime of snapshot LV snapshots vs. VM snapshots • Similar but different concepts • Snapshot of file systems alone does not guarantee VM snapshot
  • 9.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 9 Examples of LVMS: LINUX LVM • http://www.globalknowledge.com/training/videodetail.asp?pageid=2222&vid=33 • http://www.howtoforge.com/linux_lvm Solaris Volume Manager Veritas Volume Manager IBM LVM NetBSD LVM Windows Logical Disk Manager … Full list: http://en.wikipedia.org/wiki/Logical_volume_management
  • 10.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 10 Ephemeral, block and object storage Source: OpenStack Operations Guide
  • 11.
    SIAD 2023/2024 ©PS/TC DEI/FCTUC 11 ZFS as a modern filesystem (and LVM system) Despite the usage of LVMS, most filesystems were not designed for current data centers. ZFS and Btrfs are modern file systems with a few technologies specifically designed for modern data centers. • Joksimoski and Loskovska, Overview of Modern File Systems http://ciit.finki.ukim.mk/data/papers/7CiiT/7CiiT-09.pdf For a very good introduction to ZFS (despite all the hype): • http://www.slideshare.net/mewandalmeida/zfs (these slides will be directly used in the rest of today’s class) • https://www.youtube.com/watch?v=0oJ0vlzeJio (long video, but also quite good)