0% found this document useful (0 votes)
7 views27 pages

6-LEC6 Servermangment

Module 5 of the Server Management course focuses on Storage Management, covering disk management, RAID, fault tolerance, and backup strategies. It emphasizes the importance of understanding FreeBSD's storage options, including adding and resizing disks, as well as the implementation of RAID for fault tolerance. Additionally, the module introduces ZFS as an advanced file system that enhances data integrity and performance.

Uploaded by

hhhmoayad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views27 pages

6-LEC6 Servermangment

Module 5 of the Server Management course focuses on Storage Management, covering disk management, RAID, fault tolerance, and backup strategies. It emphasizes the importance of understanding FreeBSD's storage options, including adding and resizing disks, as well as the implementation of RAID for fault tolerance. Additionally, the module introduces ZFS as an advanced file system that enhances data integrity and performance.

Uploaded by

hhhmoayad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 27

Server Management –

Module 5: Storage Management

Lecture 6
Dr Mohammed Elbasheir
Course Modules
• Module 0: Course Design
• Module 1: Introduction to Servers and Server Operating Systems
• Module 2: Getting Started with FreeBSD Server
• Module 3: Software Maintenance
• Module 4: Tuning and Configuration
• Module 5: Storage Management
• Module 6: Networking
• Module 7: Shell Scripting
• Module 8: Building a WordPress Server
Module 5
• Storage Management
• Part A
– Disk management
– RAID and fault tolerance
– Performing backups
• Part B
– ZFS
Objectives
• Upon successful completion of this module, you should be able to:
– Understand the storage management options of FreeBSD
– Add disks
– Resize disks
– Understand RAID and its value to storage management
– Define the Z file system
– Perform backups
PART A
Overview I
• Management of storage local to the server
– This would include those disks that are directly used by the server for its
operating system. We must monitor these disks for utilization, adjust their size
as needed, and be able to attach new drives. We must also understand how to
mount and unmount drives automatically as the system is booting.
• Management of storage attached to the server
– A server can attach to storage indirectly, such as through network attached
storage (NAS) and storage attached network (SAN) devices. To our UNIX
systems these will appear as though local drives. But understanding this type
of storage and how to work with it is key. Included in this discussion will be
cloud storage, both public and private.
Overview II
• Fault tolerance
– While backups provide us with some security in case of failure, we might also
want to configure servers to use fault tolerant storage, or RAID (redundant
arrays of independent disks). RAID will allow a system to keep running,
without apparent issue to the users of that system, should a disk drive fail.
Robust servers are typically configured with multiple redundancies (such as
redundant power supplies). Providing redundant storage makes sense. Both
software and hardware RAID will be discussed.
• Performing backups
– The different types of backup, such as disk image, differential file, and
synchronization, will be discussed, as well as when we would choose to use
each. Topics that go beyond our immediate server, such as where to store
those backups, must be considered.
Adding Disks
• Storage in FreeBSD Handbook
• Demonstration of adding disks to a virtual machine
• We will use a file
– truncate -s 1g disk.img
– mdconfig disk.img
– newfs /dev/md0
– mount /dev/md0 /mnt
Working With Partitions
• Commands to be used:
– gpart
– newfs
– mount
– growfs
• A great disk setup guide
• Resizing disks
GEOM
• GEOM: Modular Disk Transformation Framework
• FreeBSD Handbook
• Special mention for geli
RAID
• Redundant array of independent disks
• Intended to provide fault tolerance for systems operations
• RAID is a complex topic
– Some references
• https://www.techtarget.com/searchstorage/definition/RAID
• http://www.webopedia.com/TERM/R/RAID.html
• https://en.wikipedia.org/wiki/RAID
RAID Implementation
• RAID can be hardware based
– Network storage devices
• Enterprise (SAN)
• Home (NAS)
• RAID can be software based
– Features built into the operating system
– Provide RAID capability
– Must have multiple disk drives to implement
RAID Hardware
RAID Demonstration
• We will now implement a RAID mirror (Level 1) using the two drives we
created
• See gmirror for more information
• Then demonstrate what happens when we take a drive away
Backing Up
• Backups are critical to a successful IT operation
• Quote from our RAID readings: “RAID is not a backup”
• Backup management key for system administrators
– What to back up?
– When to back up?
– What to back up to?
• Reference
– FreeBSD Handbook
– Backup options
Backup Thoughts
• Backups should be automated
– Controlled by administrators, not users
• Multiple backup destinations should be used
– At least one should be offsite
• Cloud or backup media moved offsite
Backup Options
• The tools that you use will depend on the type of backup
– dump
• Best for automated full system backups to backup device like tape
– tar
• Good for backing up individual files or directories
– rsync
• Can be automated via cron
• Synchronizes only changed files
– Backup applications
• Backula
– Cloud services
• Require customized setup
Dump Command
• Dump command intended to back up entire disks/partitions
• Restore command restores from dump
• dump man page
Tar Command
• tar command creates single file archives
– Similar to “zip” files
• Convenient for whole directories or sets of files
• Not compressed by default
• Huge number of options
• tar man page
Rsync Command
• Does incremental backup of only changed files
• Can connect to remote site via SSH
• Can be automated in cron job
– For SSH, need to authenticate
• Can echo password via a pipe
• Preferred way is to configure SSH server to use key pairs
• Likely install needed: pkg install rsync
• rsync man page
Demonstration
• Will now demonstrate tar and rsync
Summary
• Backups are a critical aspect of a properly run IT shop
• Holistic implementation approach
– Not just the backup operation
– Placement of files
• Separate partitions and devices
• Network storage
• Backups worthless if not available
– Off-site storage a key element of the implementation
Continue Practice Project
• Install and configure Nextcloud in your jail
• Follow the Nextcloud tutorial
• Will need to apply all knowledge learned so far
• Need to finish configuration
PART B
ZFS Overview
• An advanced file system
• Fosters data integrity
– When data is written, a checksum is calculated
– Checksum is used whenever file is accessed
• Pooling of storage
• Multiple caching mechanisms for improved performance
In Class Assignment
• Create presentation about ZFS before break
• Give presentation after break
• Include
– History of ZFS
• Explain the difference between ZFS and OpenZFS
– Strengths and weaknesses of ZFS (focus on OpenZFS)
• Compare to other file systems
– What are the main features and how are they implemented
– How to use ZFS on FreeBSD
• Provide as much detail as possible
• Document commands and how you use them
• More points when including information that is new to me
THANK YOU!

You might also like