IRIX™ Admin: Disks and Filesystems Document Number 007-2825-001 CONTRIBUTORS Written by Susan Ellis Illustrated by Dany Galgani Production by Gloria Ackley Cover design and illustration by Rob Aguilar, Rikk Carey, Dean Hodgkinson, Erik Lindholm, and Kay Maitz © Copyright 1996, Silicon Graphics, Inc.— All Rights Reserved The contents of this document may not be copied or duplicated in any form, in whole or in part, without the prior written permission of Silicon Graphics, Inc. RESTRICTED RIGHTS LEGEND Use, duplication, or disclosure of the technical data contained in this document by the Government is subject to restrictions as set forth in subdivision (c) (1) (ii) of the Rights in Technical Data and Computer Software clause at DFARS 52.227-7013 and/or in similar or successor clauses in the FAR, or in the DOD or NASA FAR Supplement. Unpublished rights reserved under the Copyright Laws of the United States. Contractor/manufacturer is Silicon Graphics, Inc., 2011 N. Shoreline Blvd., Mountain View, CA 94043-1389. Silicon Graphics, the Silicon Graphics logo, and IRIS are registered trademarks, and IRIX, XFS, Extent File System, Indy, CHALLENGE, IRIS InSight, and REACT are trademarks of Silicon Graphics, Inc. UNIX is a registered trademark in the United States and other countries, licensed exclusively through X/Open Company, Ltd. Network License System and NetLS is trademarks of Apollo Computer, Inc., a subsidiary of Hewlett-Packard Company. NFS is a registered trademark of Sun Microsystems. NetWorker is a registered trademark of Legato Systems, Inc. EXABTYE is a trademark of EXABTYE Corporation. IRIX™ Admin: Disks and Filesystems Document Number 007-2825-001 Contents List of Examples xi List of Figures xiii List of Tables xv IRIX Admin Manual Set xvii About This Guide xix What This Guide Contains xix Conventions Used in This Guide xxi How to Use This Guide xxii Product Support xxiii Additional Resources xxiii 1. Disk Concepts 1 Disk Drives Supported by IRIX 1 Physical Disk Structure 3 Disk Partitions 4 System Disks, Option Disks, and Partition Layouts 6 Partition Types 11 Volume Headers 12 Device Files 14 Block and Character Devices 15 Device Permissions and Owner 16 Major and Minor Devices 16 Device Names 16 iii Contents 2. Performing Disk Administration Procedures 19 Listing the Disks on a System Withhinv 20 Formatting and Initializing a Disk Withfx 21 Adding Files to the Volume Header Withdvhtool 22 Removing Files in the Volume Header Withdvhtool 24 Displaying a Disk’s Partitions Withprtvtoc 25 Repartitioning a Disk Withxdkm 27 Repartitioning a Disk Withfx 27 Before Repartitioning 27 Invokingfx From the Command Monitor 28 Invokingfx From IRIX 30 Creating Standard Partition Layouts 31 Creating Custom Partition Layouts 32 After Repartitioning 36 Creating Device Files WithMAKEDEV 36 Creating Device Files Withmknod 37 Creating Mnemonic Names for Device Files Withln 38 Creating a System Disk From the PROM Monitor 38 Creating a New System Disk From IRIX 44 Creating a New System Disk by Cloning 48 Adding a New Option Disk 50 Adding a Disk on an Integral SCSI Controller 51 Adding a Disk on a Non-Integral SCSI Controller or a VME Controller 52 3. Filesystem Concepts 53 IRIX Directory Organization 54 General Filesystem Concepts 56 Inodes 58 Types of Files 59 Hard Links and Symbolic Links 59 Filesystem Names 61 EFS Filesystems 61 iv Contents XFS Filesystems 63 Network File Systems (NFS) 64 Cache File Systems (CacheFS) 65 /proc Filesystem 65 Filesystem Creation 66 Filesystem Mounting and Unmounting 66 Filesystem Checking 68 Filesystem Reorganization 69 Filesystem Administration From the Miniroot 69 How to Add Filesystem Space 70 Mount a Filesystem as a Subdirectory 70 “Steal” Space From Another Filesystem 70 Grow a Filesystem Onto Another Disk 71 Disk Quotas 71 Filesystem Corruption 72 4. Creating and Growing Filesystems 75 Planning for XFS Filesystems 75 Prerequisite Software 75 Choosing the Filesystem Block Size and Extent Size 76 Choosing the Log Type and Size 77 Checking for Adequate Free Disk Space 78 Disk Repartitioning 80 Dump and Restore Requirements 81 Making an XFS Filesystem 82 Making an EFS Filesystem 84 Making a Filesystem Frominst 85 Growing an XFS Filesystem Onto Another Disk 86 Growing an EFS Filesystem Onto Another Disk 87 Converting Filesystems on the System Disk From EFS to XFS 89 Converting a Filesystem on an Option Disk From EFS to XFS 96 v Contents 5. Maintaining Filesystems 99 Routine Filesystem Administration Tasks 99 Mounting and Unmounting Filesystems 100 Manually Mounting Filesystems 100 Mounting Filesystems Automatically With the/etc/fstab File 101 Mounting a Remote Filesystem Automatically 103 Unmounting Filesystems 103 Managing Disk Space 104 Monitoring Free Space and Free Inodes 105 Monitoring Key Files and Directories 106 Cleaning Out Temporary Directories 107 Locating Unused Files 108 Identifying Accounts That Use Large Amounts of Disk Space 110 Running Out of Space in the Root Filesystem 112 Imposing Disk Quotas 113 Monitoring Disk Quotas 114 Copying XFS Filesystems Withxfs_copy 114 Checking EFS Filesystem Consistency Withfsck 115 Checking Unmounted Filesystems 115 Checking Mounted Filesystems 116 Checking XFS Filesystem Consistency Withxfs_check 117 6. Logical Volume Concepts 119 Introduction to Logical Volumes 120 vi Contents XLV Logical Volumes 122 Composition of Logical Volumes 123 Volumes 125 Subvolumes 126 Plexes 127 Volume Elements 130 XLV Logical Volume Names 133 XLV Daemons 133 XLV Error Policy 134 XLV Logical Volume Planning 134 Don’t Use XLV When ... 134 Decide Which Subvolumes to Use 134 Choose Subvolume Sizes 135 To Plex or Not to Plex? 135 To Stripe or Not to Stripe? 136 Concatenate Disk Partitions or Not? 136 Real-Time Subvolumes 137 Files on the Real-Time Subvolume and Commands 137 File Creation on the Real-Time Subvolume 137 Guaranteed-Rate I/O and the Real-Time Subvolume 138 lv Logical Volumes 138 7. Creating and Administering XLV Logical Volumes 141 Verifying That Plexing Is Supported 141 Creating Volume Objects Withxlv_make 142 Example 1: A Simple Logical Volume 142 Example 2: A Striped, Plexed Logical Volume 145 Example 3: A Plexed Logical Volume for an XFS Filesystem With an External Log 146 Displaying Logical Volume Objects 148 Adding a Volume Element to a Plex (Growing a Logical Volume) 149 Adding a Plex to a Logical Volume 150 vii Contents Detaching a Plex From a Logical Volume 153 Deleting an XLV Object 154 Removing and Mounting a Plex 155 Creating Plexed Logical Volumes for Root 158 Booting the System Off an Alternate Plex 160 CHALLENGE L, CHALLENGE XL, and CHALLENGE DM 160 All Other Models 160 Configuring the System for More Than Ten XLV Logical Volumes 162 Convertinglv Logical Volumes to XLV Logical Volumes 163 Creating a Record of XLV Logical Volume Configurations 164 8. Creating and Administeringlv Logical Volumes 167 Creating Entries in the/etc/lvtab File 168 Creating New Logical Volume Withmklv 169 Checking Logical Volumes Withlvck 170 Creating a Logical Volume and a Filesystem on Newly Added Disks 171 Increasing the Size of a Logical Volume 173 Shrinking a Logical Volume 174 9. System Administration for Guaranteed-Rate I/O 175 Guaranteed-Rate I/O Overview 176 GRIO Guarantee Types 178 Hard and Soft Guarantees 179 Per-File and Per-Filesystem Guarantees 179 Private and Shared Guarantees 179 Rotor and Non-Rotor Guarantees 180 An Example Comparing Rotor and Non-Rotor Guarantees 180 Real-Time Scheduling, Deadline Scheduling, and Nonscheduled Reservations 181 GRIO System Components 182 Hardware Configuration Requirements for GRIO 183 Configuring a System for GRIO 185 viii Contents Additional Procedures for GRIO 188 Disabling Disk Error Recovery 188 Restarting theggd Daemon 191 Modifying/etc/grio_config 191 Runningggd as a Real-time Process 192 GRIO File Formats 192 /etc/grio_config File Format 193 /etc/grio_disks File Format 196 /etc/config/ggd.options File Format 198 A. Repairing EFS Filesystem ProblemsWithfsck 199 Initialization Phase 200 General Errors 201 Phase 1 Check Blocks and Sizes 201 Phase 1 Error Messages 201 Phase 1 Responses 204 Phase 1B Rescan for More Bad Dups 204 Phase 2 Check Pathnames 205 Phase 2 Error Messages 205 Phase 2 Responses 207 Phase 3 Check Connectivity 207 Phase 3 Error Messages 208 Phase 3 Responses 209 Phase 4 Check Reference Counts 209 Phase 4 Error Messages 210 Phase 4 Responses 212 Phase 5 Check Free List 213 Phase 5 Error Messages 213 Phase 5 Responses 214 Phase 6 Salvage Free List 214 Cleanup Phase 214 Cleanup Phase Messages 215 Index 217 ix
Description: