Xsan Administrator’s Guide for Xsan 1.
K Apple Computer, Inc. © 2006 Apple Computer, Inc. All rights reserved. Intel and Intel Core are trademarks of Intel Corp. in the U.S. and other countries. Under the copyright laws, this manual may not be copied, in whole or in part, without the written consent of Apple. PowerPC and the PowerPC logo are trademarks of International Business Machines Corporation, under license therefrom. The Apple logo is a trademark of Apple Computer, Inc., registered in the U.S. and other countries.
Contents 11 About This Book 12 What’s New in Xsan 1.
28 Metadata and Journal Data 29 Striping at a Higher Level 30 Security 30 Expanding Storage 31 Xsan Capacities 33 33 34 34 35 36 37 38 39 41 50 51 51 52 52 52 52 53 4 Chapter 2: Setting Up a Storage Area Network Hardware and Software Requirements Supported Computers Supported Storage Devices Fibre Channel Fabric Ethernet TCP/IP Network Directory Services Outgoing Mail Service Planning Your SAN Planning Considerations and Guidelines Connecting Computers and Storage Devices Preparing LUNs Using the Xsan Adm
3 54 74 75 75 SAN and Volume Setup Summary Setting Up an Xsan Volume on a Storage Area Network Renaming a SAN Removing a SAN Setting Up Additional SANs 77 78 79 79 80 82 84 86 87 89 90 91 92 92 94 95 96 97 Chapter 3: Managing SAN Storage Adding Storage Restoring the Previous Volume Configuration After Changes About Rearranging Fibre Channel Connections Adding LUNs to a Storage Pool Adding a Storage Pool to a Volume Adding a Volume to a SAN Assigning a Storage Pool Affinity to a Folder Assigning an Affin
99 Setting the Volume Allocation Strategy 100 Enabling or Disabling Access Control Lists 101 Choosing the Windows ID Mapping Method 101 Checking Volume Fragmentation 102 Defragmenting a Volume 103 Checking the Integrity of a Volume 104 Repairing a Volume 105 106 107 108 109 109 110 110 110 111 111 112 114 115 117 119 6 Chapter 4: Managing Clients and Users Adding a Client Adding a Client to a StorNext SAN Mounting a Volume on a Client Controlling Client and User Access Controlling Access to Folders on Vol
120 Creating Local Home Folders for Network Accounts 121 122 123 124 Chapter 5: Managing Metadata Controllers Adding a Controller Setting Controller Failover Priority Switching to a Standby Controller 125 127 128 129 130 Finding Out Which Controller Is Hosting a Volume Listing the Volumes Hosted by a Controller Changing a Controller’s IP Address Upgrading Controller Software Monitoring Controller Status 131 132 133 134 135 136 136 136 137 138 139 139 Chapter 6: Monitoring SAN Status Locking Xsan Admin
140 Checking Volume Clients 141 Checking for Fibre Channel Connection Failures 141 Checking the State of Xserve RAID Systems 143 Chapter 7: Solving SAN Problems 143 A Dialog on a Client Reports That a LUN Is Unreadable 143 144 144 144 145 145 146 147 147 148 148 149 149 149 149 150 150 151 8 You’re Unable to Connect to a Computer Using Xsan Admin You’re Unable to Install the Xsan Software Some Computers Aren’t Listed in Xsan Admin You’re Unable to Mount a Volume on a Client Xserve RAID LUNs Aren’t Accessi
152 You’re Unable to Add LUNs to a Storage Pool 153 The Capacity of a Larger LUN is Listed as 2 Terabytes 155 Appendix A: Combining Xsan and StorNext Clients and Controllers 155 Terminology 156 Compatible Software Versions 156 Licensing 157 Adding Macintosh Clients to a StorNext SAN 159 Using Xsan Controllers with StorNext Clients 161 161 162 162 163 164 164 168 171 172 173 174 175 176 Appendix B: Using the Command Line Using the Shell Commands Sending Commands to Remote Computers Viewing the Man Pages Not
176 Starting a Volume Controller (fsm) 177 Starting a Port Mapper Process (fsmpm) 177 Defragmenting a File, Folder, or Volume (snfsdefrag) 179 Mounting an Xsan Volume 180 Unmounting an Xsan Volume 181 Viewing Logs 181 The Configuration Files 181 Examples 183 Glossary 187 Index 10 Contents
Preface About This Book Use this guide to learn how to set up and manage Xsan volumes on a storage area network. This guide shows how to use Xsan to combine Xserve RAID arrays and slices into large, easy-to-expand volumes of storage that clients use like local disks but are actually shared over a high-speed Fibre Channel fabric. Chapter 1 provides an overview of Xsan and how you can use it to organize RAID arrays into shared volumes of storage.
Chapter 7 lists solutions to common problems you might encounter. Appendix A contains information to help you combine Xsan controllers or clients with ADIC StorNext controllers or clients on the same SAN. Appendix B describes command-line utilities and configuration files you can use to manage an Xsan SAN using Terminal. What’s New in Xsan 1.4 Xsan 1.4 offers these new features and capabilities: Â You can use access control lists (ACLs) to manage user access to Xsan volumes.
Controller Client Compatible Xsan 1.4 Xsan 1.4 Yes Xsan 1.3 (Mac OS X v10.4) Yes Xsan 1.3 (Mac OS X v10.4) Xsan 1.3 (Mac OS X v10.3) Yes, for LUNs < 2 TB Xsan 1.2 or earlier No StorNext 2.8 No StorNext FX 1.3 or 1.4 Yes StorNext 2.6 or 2.7 Yes StorNext 2.5 or earlier No Xsan 1.4 No Xsan 1.3 (Mac OS X v10.4) Yes Xsan 1.3 (Mac OS X v10.3) Yes StorNext FX 1.3 or 1.4 Yes StorNext 2.6 or 2.7 Yes StorNext 2.5 or earlier No StorNext 2.8 Xsan 1.4 or 1.3 Yes StorNext 2.7 Xsan 1.
Upgrading from an Earlier Version of Xsan For more information about migrating your SAN storage to Xsan 1.4 from an earlier version of Xsan, including tips for upgrading with the least impact on existing storage, see the Xsan Migration Guide at www.apple.com/server/documentation/. For More Information For more information about Xsan, consult these resources: Read Me documents—important updates and special information. Look for them on the Xsan installation disc. Xsan website (www.apple.
Notation Conventions The following conventions are used in this book wherever shell commands or other command-line items are described. Notation Indicates fixed-width font A command or other terminal text $ A shell prompt [text_in_brackets] An optional parameter (one|other) Alternative parameters (type one or the other) underlined A parameter you must replace with a value [...
1 Overview of Xsan 1 This chapter gives you an overview of Xsan and storage area networks. Read this chapter for an overview of Xsan and how you can use it to set up a storage area network (SAN) to provide fast, shared storage. What Is Xsan? Xsan is a storage area network file system and a management application (Xsan Admin) that you can use to provide users or applications on client computers with shared high-speed access to expandable storage.
Mac OS X San Volume Xsan lets you combine RAID arrays into volumes clients use like local disks.
Xsan Storage Area Networks A storage area network is a way of connecting computers to storage devices that gives users very fast access to files and gives administrators the ability to expand storage capacity as needed without interrupting users.
Metadata controller Ethernet - TCP/IP (Private) Ethernet - TCP/IP (Public) Clients Standby controller Fibre Channel switch Xserve RAID storage Intranet/ Internet 20 Chapter 1 Overview of Xsan
Shared SAN Volumes Users and applications see shared SAN storage as local volumes. Xsan volumes are logical disks made up of groups of RAID arrays. The elements you combine to create an Xsan volume are described under “How Xsan Storage Is Organized” on page 23. Controllers and Clients When you add a computer to an Xsan SAN, you specify whether it will play the role of client, controller, or both. Controllers When you set up an Xsan SAN, you assign at least one computer to act as the controller.
SAN Connections Xsan uses independent networks to connect storage devices, metadata controllers, and client computers: a Fibre Channel network and one or two Ethernet networks. User Data Over Fibre Channel User data is transferred over high-speed Fibre Channel connections. Controllers also use a Fibre Channel connection to move metadata to and from the volume.
How Xsan Storage Is Organized Users use an Xsan volume the same way they use a local disk. What they don’t see is that the SAN volume actually consists of numerous physical disks combined on several levels using RAID techniques. The following illustration shows an example of how disk space provided by the individual drive modules in several Xserve RAID systems is combined into a volume that users see as a large local disk.
The following paragraphs describe these storage elements and how you organize them to create shared Xsan volumes. LUNs The smallest storage element you work with in Xsan is a logical storage device called a LUN (a SCSI logical unit number). In most storage area networks a LUN represents a group of drives such as a RAID array or a JBOD (just a bunch of disks) device. In Xsan, LUNs are Xserve RAID arrays or slices. You create a LUN when you use the RAID Admin application to create an Xserve RAID array.
Storage Pools LUNs are combined to form storage pools. A storage pool in a small volume might consist of a single RAID array, but storage pools in many volumes consist of multiple arrays. Xsan distributes file data in parallel across the LUNs in a storage pool using a RAID 0 (striping) scheme. So, you can improve a client’s access speed by distributing available storage over several LUNs in a storage pool.
Volumes Storage pools are combined to create the volumes that users see. From the user’s perspective, the SAN volume looks and behaves just like a large local disk, except that:  The size of the volume can grow as you add underlying arrays or storage pools  Other users on the SAN can access files on the volume at the same time In the illustration on page 23, two storage pools are combined to create a single shared volume.
The following screen image shows how LUNs, storage pools, and volumes appear as you organize them in Xsan Admin. This example shows a SAN named “Editing SAN” with a single shared volume named “SanVol.” Storage for the volume is provided by two storage pools, “Meta” and “Data,” the first based on a single LUN and the second on two. Each of the LUNs is a 3-disk RAID 5 array on an Xserve RAID using 115 GB drive modules.
Folders with Affinities To control which storage pool is used to store specific files (for example, to provide different levels of service for different users or applications), you can associate a folder on an Xsan volume with one of the storage pools that make up the volume. If, for example, you set up storage pools with different balances of performance and data redundancy, users can choose between faster and safer storage by putting files in the appropriate folder.
These files are managed by the Xsan metadata controller, but are stored on SAN volumes, not on the controller itself. By default, metadata and journal data are stored on the first storage pool you add to a volume. You can use Xsan Admin to choose where these files are stored when you add storage pools to a new volume. Striping at a Higher Level When you write a file to a RAID array using RAID 0 (striping), the file is broken into segments that are spread across the individual disk drives in the array.
Security As the SAN administrator, you can control access to shared volumes in several ways. First, users cannot browse or mount SAN volumes. Only a SAN administrator can specify which volumes are mounted on which client computers. One way you can control access to data is to mount a volume only on appropriate client computers. To prevent users from modifying data on a volume, you can mount the volume with read-only access.
Xsan Capacities The following table lists limits and capacities for Xsan volumes.
2 Setting Up a Storage Area Network 2 This chapter lists requirements, suggests planning tips, and gives instructions for setting up an Xsan SAN.
Supported Computers You can use Xsan 1.4 on computers that meet these minimum requirements: Systems  Macintosh computers with an Intel or PowerPC G5 processor Memory  Clients should have a minimum of 256 MB of RAM.  Controllers should have a minimum of 512 MB of RAM. For optimum performance, add an additional 512 MB of RAM for each SAN volume hosted by the controller. Supported Operating Systems You can install Xsan 1.4 only on computers running  Mac OS X or Mac OS X Server v10.4.
Fibre Channel Fabric Unlike file system metadata, which controllers and clients exchange over Ethernet, actual file content in an Xsan SAN is transferred over Fibre Channel connections (as is metadata that controllers access on a volume).
Fabric Configuration You must connect the computers, storage devices, and switches in your Fibre Channel network to form a Fibre Channel “fabric.” In a fabric, Fibre Channel cables connect node ports (F or N_Port). See the documentation that came with your Fibre Channel switches for more information. Note: If you are using a Vixel 355 switch, you must connect Xserve RAID systems to an FL (arbitrated loop) port on the switch.
IP Addresses and Domain Names Assign fixed, non-routed IP addresses to all clients, controllers, and storage devices connected to the SAN Ethernet network. Don’t use DHCP to assign addresses to SAN devices. You can use the following ranges of IP addresses on your private (non-routed) subnet: Private address range Associated subnet mask 10.0.0.0 – 10.255.255.255 255.0.0.0 Comments 10/8 172.16.0.0 – 172.31.255.255 255.240.0.0 172.16/12 192.168.0.0 – 192.168.255.255 255.255.0.0 192.
If you don’t have access to a directory service, you can use the directory services in Mac OS X Server to set up an LDAP directory of SAN users and groups. Note: If you do create your user accounts in a centralized directory, be aware that some applications running on SAN client computers, such as Final Cut Pro, for example, work better when users have local home folders.
Planning Your SAN It’s easy to add storage to an existing Xsan SAN, but reorganizing a SAN after you set it up is not so simple. So, it’s important to plan the layout and organization of your SAN and its storage before you set it up.
Preliminary Planning Questions  How much storage do you need?  How do you want to present available storage to users?  What storage organization makes the most sense for user workflow?  What levels of performance do your users require?  How important is constant availability?  What are your requirements for security? Your answers to the above questions will help you decide the following:  What RAID schemes should you use for your RAID arrays?  How many SAN volumes do you need?  How should individua
Planning Considerations and Guidelines The following paragraphs might help you make some of your SAN design decisions. How Much Storage? Because it’s easy to add storage to an Xsan SAN, you only need to decide on an adequate starting point. You can then add storage for user data as needed. You can’t expand a storage pool that is used to store volume metadata and journal data.
Performance Considerations If your SAN supports an application (such as high resolution video capture and playback) that requires the fastest possible sustained data transfers, design your SAN with these performance considerations in mind: Â Set up the LUNs (RAID arrays) using a RAID scheme that offers high performance. See “Choosing RAID Schemes for LUNs” on page 44. Â Group your fastest LUNs in storage pools reserved for the application.
 Use a router to isolate the Ethernet network used by the SAN from a company intranet or the Internet, or better, use a second Ethernet network (including a second Ethernet card in each SAN computer) for the SAN.  If your SAN uses directory services, mail services, or other services on a separate server, use a second, separate Ethernet network to connect SAN computers to that server.
Security Considerations If your SAN will support projects that need to be completely secure and isolated from each other, you can create separate volumes for each project to eliminate any possibility of the wrong client or user accessing files stored on a volume. As the SAN administrator, you control which client computers can use a volume. Clients can’t browse for or mount SAN volumes on their own. You use Xsan Admin to specify which clients a volume is mounted on.
Xserve RAID supports all popular RAID levels. Each RAID scheme offers a different balance of performance, data protection, and storage efficiency, as summarized in the following table.
For a more typical balance of security and shared access, a flexible compromise is to create a single volume and use folder access privileges or access control lists in Mac OS X Server’s Workgroup Manager to control access. Deciding How to Organize a Volume You can help users organize data on a volume or restrict users to specific areas of the volume by creating predefined folders. You can control access to these folders by assigning access permissions using Xsan Admin.
Creating storage pools from LUNs that are hosted on different drive modules and different RAID controllers increases performance by increasing the parallelism of data transfers. For example, a storage pool consisting of two LUNs, each a single drive module on the left side of an Xserve RAID, will not be as fast as a similarly sized storage pool made up of two LUNs that are single slices across all seven drives, one slice on each controller.
If you have a small number of clients or if performance is not critical you can use a single computer as both controller and client. You can even set up a SAN consisting of a single storage device and a single computer that acts as both controller and client (to provide network attached storage, for example). If high availability is important, you should use at least two controllers, one as the primary controller and one as a standby.
Combining Clients and Controllers The same computer can function as both a metadata controller and a client. It’s possible, for example, to set up a SAN consisting of a single Xserve RAID and one computer that acts as both controller and client. Any computer you specify as a controller can also act as a client.
Estimating Metadata and Journal Data Storage Needs To estimate the amount of space required for Xsan volume metadata, assume that 10 million files on a volume require approximately 10 gigabytes of metadata on the volume’s metadata storage pool. Choosing an Allocation Strategy The allocation strategy you choose for a volume determines the order in which its storage pools are filled with data. You can choose round robin, fill, or balance.
Preparing LUNs Xserve RAID systems usually come preconfigured with two RAID 5 arrays, one on each side (on each controller). So, out of the box, each Xserve RAID provides two LUNs. If this suits your needs, no other preparation is needed. If you want to set up some other combination of RAID arrays or slices, you need to do so using the RAID Admin application before you can add the resulting LUNs to your SAN’s storage pools. For help using RAID Admin, see Using RAID Admin 1.
Installing Just the Xsan Admin Application Xsan Admin is included when you install the Xsan software on SAN controller and client computers. You can also install just Xsan Admin on any other computer you want to use to manage the SAN. For help, see page 55. Connecting Through a Firewall If there is a firewall between the SAN and the computer you’re using to run Xsan Admin, you need to open port 311 in the firewall so Xsan Admin can communicate with the SAN computers.
Using the Command Line If necessary, you can perform many Xsan setup and management tasks from a shell command prompt. For more information, see Appendix B. SAN and Volume Setup Summary You’ll perform the following tasks to set up your first Xsan storage area network. Details for each task are on the indicated pages.
Setting Up an Xsan Volume on a Storage Area Network Step 1: Set Up the Fibre Channel Network m Connect controller computers, client computers, and Xserve RAID storage systems to a Fibre Channel network. Be sure to configure the switch and make the connections so that you create a Fibre Channel fabric. For more information, see the guidelines and requirements under “Fibre Channel Fabric” on page 35.
Step 4: Set Up LUNs m New Xserve RAID systems are usually preconfigured as two RAID 5 arrays that are ready to use as LUNs.To set up some other configuration of LUNs, use the RAID Admin application to create RAID arrays or slices on your Xserve RAID systems. For help choosing other RAID schemes, see “Choosing RAID Schemes for LUNs” on page 44. Important: If you set up a LUN that is larger than 2 terabytes (TB), be aware that older clients (those running Xsan on Mac OS X 10.3 Panther or Xsan 1.
To install Xsan on a computer that has no keyboard or monitor: 1 Log in to a computer that does have a keyboard and monitor, and then insert the Xsan disc. 2 Open the Terminal application (in /Applications/Utilities/). 3 In Terminal, copy the Xsan installer package to the remote computer: $ scp -r /Volumes/Xsan/Install_xsan.mpkg user@remotehost:/tmp/ where user is an administrator user on the remote computer and remotehost is the IP address or DNS name of the computer you want to install on.
Step 6: Open Xsan Admin and Log In to the SAN 1 Open Xsan Admin on any computer connected to the SAN. Xsan Admin is in /Applications/Server/. You can open Xsan Admin on any computer attached to the SAN, or on any remote computer that can reach the SAN’s TCP/IP subnet. 2 When the login dialog appears, use an administrator account to log in to a SAN computer that will be used as a controller. 3 Click Setup.
4 In the Computers pane, type a name for the SAN and click Save. The SAN name you type appears in the SAN Components list instead of the controller name or address. To list the controller instead, deselect “Use SAN name in list” in Xsan Admin Preferences. Step 7: Set Up Controllers and Clients All computers on the local network that have Xsan installed are listed in the Computers pane. In this step you choose at least one computer to act as metadata controller and set up the others as clients.
1 In the Computers pane, select a computer in the list. If the computer you’re looking for is not listed, make sure the Xsan software is installed on it, that it is connected to the SAN’s Ethernet subnet, and that it is turned on and not set to sleep. 2 If the Authenticate button appears, click it and type an administrator user name and password for the computer you are adding to the SAN. 3 Click Edit. 4 Choose whether the computer will function as a controller or a client.
You can find the serial number for a single copy of Xsan on the Xsan installation disc sleeve. If you’re using individual licenses for each copy of Xsan, make sure each serial number in the SAN is unique, and leave the “Registered to” and Organization fields blank. If you purchased a site-licensed serial number, you can find it on the documentation you received when you purchased the license.
Step 8: Label and Initialize LUNs Next, label and initialize the available LUNs for use with the Xsan file system. Each LUN represents one of the RAID arrays or slices you set up using RAID Admin. 1 In Xsan Admin, click LUNs in the Setup pane. Responding storage devices are listed by name and size. You should see one LUN for each RAID array or slice you created on Xserve RAID systems attached to the SAN’s Fibre Channel network.
If existing LUNs are not listed, particularly if they are LUNs you have used before as part of an old Xsan volume, try removing the old label from the LUN. For instructions, see “Some LUNs Aren’t Listed in Xsan Admin” on page 146. 2 Select a LUN and click Edit. (You can also just double-click the LUN in the list.) 3 Type a label for the LUN. 4 If the LUN is larger than 2 terabytes (TB) and will be part of a volume mounted only on clients running Xsan 1.3 or 1.4 on Mac OS X v10.
Step 9: Create Volumes Next, you’ll create the volumes your users will see. New Volume button 1 In Xsan Admin, click Storage in the Setup pane. 2 Click the New Volume button (next to the empty list). 3 Type a name for the volume. Use only uppercase letters (A–Z), lowercase letters (a–z), numbers (0–9), and underscores ( _ ). Don’t include spaces or hyphens. The maximum length is 70 characters.
4 Don’t adjust the block allocation size unless you have specific performance tuning needs. For more information, see “Choosing Block Allocation Size for a Volume” on page 98. 5 Choose an allocation strategy. This determines the order in which data is written to the storage pools that make up the volume. You can choose: Â Round Robin: New data is written to the next available storage pool in the volume. Â Fill: Data is stored on the first storage pool until it is full, and then on the next storage pool.
Step 10: Add Storage Pools to the Volumes New Storage Pool button 1 Select a volume in the list and click the New Storage Pool button (next to the list). 2 In the storage pool dialog, provide the following information. Â Storage Pool Name: Type a name for the storage pool. If the OK button is disabled after you type a name, the name is reserved. For a list of reserved names, see “You’re Unable to Add a Storage Pool” on page 151.
 Use for: Choose the type of data to store in the storage pool. Journal data is used by the controller to ensure the integrity of files in the volume. Metadata is file system information used by the controller. Journal data and metadata are always stored at least on the first storage pool in a volume. If this is not the first storage pool in the volume, you can choose “User data only.” To allow only files saved in a folder that has an affinity for this storage pool, enable “Only data with affinity.
Step 11: Add LUNs to Storage Pools The final step in preparing storage for the SAN is assigning LUNs to the storage pools in your SAN volumes: Click to open a drawer of unused LUNs. 1 Select a storage pool in the Storage pane and click Available LUNs. A drawer opens with a list of all the LUNs you initialized on page 61. 2 Drag LUNs from the drawer to the storage pool. If a new LUN is larger than the LUNs already in the storage pool, the usable size is shown next to the LUN in the list. 3 Click Save.
Step 12: (Optional) Set Up SAN Status Notifications Xsan can notify you by email or pager when the condition of the SAN changes. If you don’t want to set up notifications now, you can do it later. Click to add a new address. 1 In the Notification pane, click the Add button (+) next to the list to add a contact. 2 Type an email address or the address of a pager text-messaging account, and press Return. 3 If the entry is for a pager, select the checkbox in the Page column.
5 If the notification is to be sent to a computer that is not on the local SAN subnet, click SMTP Info and enter a sender name and the mail server address for the SMTP server that will relay the email. 6 To verify that notifications are set up correctly, click Send Test Notification. Step 13: (Optional) Assign Folders to Storage Pools If you want to force specific files to be stored in a specific storage pool of a volume, create a folder with an affinity for that storage pool.
1 In Xsan Admin, select a volume in the SAN Components list and click Start Volume. 2 With the volume still selected, click Clients. 3 Select the controller you’re connected to and click Mount Read & Write. 4 Click Affinities. 5 If the folder doesn’t already exist, click the Add (+) button next to the list. 6 In the dialog that appears, type a name for the folder, choose the storage pool where the folder (and all files placed in it) will be stored, and click OK.
Step 14: (Optional) Set User and Group Quotas You can set up quotas to control how much space on each SAN volume is used by each user or group. Click to add a new quota. 1 If the volume you want to set the quota for is not already started, select it in the SAN Components list and click Start Volume. 2 With the volume still selected, click Quotas.
3 Click the Add (+) button, and then drag a user or group from the drawer to the quotas list. If you don’t see the SAN users in the drawer, open Directory Access (in /Applications/ Utilities/) and make sure you’re using the correct directory for user authentication. 4 Select the user or group in the quotas list and adjust their quota settings in the lower half of the window. Â Soft Quota: The user’s recommended working maximum.
Step 15: Start the Volumes and Mount Them on Clients To make a volume available to a user or application on a client computer, you must use Xsan Admin to start the volume and mount it on the client. Users logged in to client computers can’t browse for or mount SAN volumes themselves. 1 In Xsan Admin, select each new volume in the SAN Components list and click Start Volume. If you already set up affinities or quotas on the volume, the volume is already started.
4 To allow the client to modify files on the volume, click Mount Read & Write. To prevent the client from modifying the volume, click Mount Read Only. Shift-click computers to mount on more than one at a time. An icon for the mounted volume appears in the Finder on each client computer. If you’re unable to mount volumes on a client, check your Fibre Channel switch configuration to be sure that the SAN’s clients, controllers, and storage devices are in the same Fibre Channel zone.
Removing a SAN Follow these steps to take a SAN out of service and remove it from Xsan Admin. To remove a SAN: 1 Open Xsan Admin (in /Applications/Server/). 2 Unmount the SAN’s volumes from client computers. Select each of the SAN’s volumes in the SAN Components list, click Clients, select each client that has the volume mounted, and click Unmount. 3 Stop the SAN’s volumes. Select each of the SAN’s volumes in the SAN Components list and click Stop Volume.
3 Managing SAN Storage 3 This chapter shows how to expand, modify, check, and repair SAN storage.
 Set the block allocation size (page 97)  Set the storage allocation strategy (page 99)  Enable or disable access control lists (page 100)  Set the Windows ID mapping method (page 101)  Check volume fragmentation (page 101)  Defragment a volume (page 102)  Check a volume (page 103)  Repair a volume (page 104) Adding Storage There are several ways you can add storage to a SAN:  Add RAID arrays (LUNs) to existing storage pools  Add storage pools to existing volumes  Add new volumes The first optio
The third option creates a new volume that must be explicitly mounted on client computers. Clients must then choose to save new files and folders on the new volume, or copy existing items there, so this option is more likely to disrupt user workflow. Restoring the Previous Volume Configuration After Changes If you have trouble with a volume after expanding it, you can restore its previous configuration so it can be used until you solve the problem.
Adding LUNs to a Storage Pool You can increase the capacity of a SAN volume by adding LUNs (RAID arrays or array slices) to a storage pool that belongs to the volume. Choosing Compatible LUNs Add LUNs that are similar in performance and capacity to the LUNs already in the storage pool. Mixing LUNs of different sizes or speeds in the same storage pool wastes capacity and can degrade performance.
Important: If you forget to unmount the volume (in step 3) before you stop it, be sure to click Disconnect in the “server no longer available” alert that appears on SAN computers. 5 Select the SAN in the SAN Components list, click Setup, and then click LUNs. 6 Select the new array or slice in the list of available LUNs and click Edit. 7 In the dialog that appears, type a label for the LUN. The label can’t contain spaces. Only SAN administrators, not users, will see this label. 8 Click OK, and click Save.
From the Command Line You can also add LUNs to a storage pool by modifying the associated volume configuration file and using the cvlabel command in Terminal. For more information, see the cvfs_config and cvlabel man pages or “The Configuration Files” on page 181 and “Labeling, Listing, and Unlabeling LUNs (cvlabel)” on page 172. Adding a Storage Pool to a Volume You can add free space to a SAN volume by adding a storage pool to the volume. Note: A volume can’t contain more than 512 storage pools.
 Use for: Choose the types of data that can be stored on the storage pool.  Stripe Breadth: Specify how much data is written to or read from each LUN in the storage pool before moving to the next LUN. This value can affect performance. If you’re not sure what value to use, use the default (256 blocks) or see “Choosing Stripe Breadth for a Storage Pool” on page 93.  Multipath Method: Choose Rotate to have Xsan alternate between the connections for maximum throughput.
Adding a Volume to a SAN A single Xsan SAN can provide multiple shared volumes. 1 Open Xsan Admin and select the SAN in the SAN Components list. 2 Click Setup, and then click Storage. 3 Click the Add Volume button next to the list. 4 In the dialog that appears, provide the following information and then click OK. Â Volume Name: Type a name for the volume. Use only uppercase letters (A–Z), lowercase letters (a–z), numbers (0–9), or underscores ( _ ). Don’t include spaces or hyphens.
5 Select the new volume and click the Add Storage Pool button. In the dialog that appears, provide the following information, and then click OK. Â Storage Pool Name: Type a name for the storage pool. If the OK button is disabled when you finish typing the name, the name is reserved; try another. For a list of reserved names, see Chapter 7. Â Use for: Choose the types of data that can be stored on the storage pool.
Assigning a Storage Pool Affinity to a Folder You can set up an affinity between a folder and a storage pool so that files saved in the folder are stored only on the specified storage pool. When you set up storage pools, you group devices with similar performance, capacity, and data protection schemes. Depending on the devices and the protection schemes you choose for them, you might end up with some storage pools that are larger, faster, or better protected than others.
5 Choose the storage pool (where the folder’s contents will be stored) from the Storage Pool Affinity pop-up menu in the dialog that appears. If the storage pool you want to use is not listed in the Storage Pool Affinity pop-up menu, it might not be set to allow user data. To check, select the SAN in the SAN Components list on the left, click Setup, and click Storage. Then select the storage pool, click the Edit button, and check which data types are enabled next to Use For. 6 Click OK, and then click Save.
3 In Terminal, type $ sudo cvmkdir -k affinity path where affinity is the affinity name of a storage pool in the volume and path is the full path to the folder on the volume. If the name of the storage pool is 8 characters or less, you can use the storage pool name for the affinity name. If the storage pool name is longer than 8 characters, you must use the affinity name instead of the storage pool name.
Removing an Affinity The way you remove an affinity depends on whether the affected folder is at the top level of the volume or inside another folder. To remove a storage pool affinity from a folder: 1 If the folder is at the top level of the volume (not within another folder), open Xsan Admin, select the volume, click Affinities, double-click the folder and choose Any Storage Pool from the Storage Pool Affinity pop-up menu. If the folder is inside another folder on the volume, continue with the next step.
Changing Storage Pool Settings The best way to set up a SAN is to plan its organization carefully before you set it up, including settings for the storage pools that make up its volumes. You can change some storage pool settings on an existing SAN, but other changes require the associated volume to be reinitialized. Edit button To view or change storage pool settings: m Select the SAN in the SAN Components list, click Setup, and click Storage.
Renaming a Storage Pool You can rename a storage pool, but doing so erases all data on the storage pool and the volume it belongs to. Warning: When you rename a storage pool, all data on the storage pool and the volume to which it belongs is lost. To rename a storage pool: 1 Unmount the associated volume from all clients. In Xsan Admin, select the volume, click Clients, select clients in the list, and click Unmount. 2 Stop the associated volume. With the volume still selected, click Stop Volume.
Choosing the Types of Files Stored on a Storage Pool You can limit the files that are stored on a particular storage pool to volume journal data and metadata, user data, user data with an affinity for that storage pool, or a combination of these. Warning: When you change the data type of a storage pool, all data on the storage pool and the volume to which it belongs is lost. Journal data and metadata are always stored on the first storage pool in a volume.
To set the stripe breadth: 1 In Xsan Admin, select the SAN that the storage pool belongs to, click Setup, and click Storage. 2 Double-click the storage pool in the list. 3 Next to Stripe Breadth, type the new value. 4 Click OK, and then click Save. Choosing Stripe Breadth for a Storage Pool Xsan uses the storage pool stripe breadth and volume block allocation size together to decide how to write data to a volume.
For Xserve RAID systems, which have an optimal transfer size of 1 MB, this becomes: stripe breadth = 1048576 / block allocation size If, for example, you are using an application such as Final Cut Pro to move large amounts of video data, choose the largest block allocation size (512KB) and use the equation to find the stripe breadth of 2 blocks. Then, Xsan writes 1 MB of data (two 512KB blocks), in turn, to each LUN in your video storage pool.
From the Command Line You can also set the multipath method using the cvadmin multipath command in Terminal. For more information, see the cvadmin man page or “Viewing or Changing Volume and Storage Pool Settings (cvadmin)” on page 164. Changing Volume Settings You can change some settings for an existing volume, but other changes require the volume to be re-initialized (you’ll see a warning for these cases).
To view or change volume settings: m Select the SAN in the SAN Components list, click Setup, and click Storage. Then select a volume and click the Edit button (or double-click a volume). See the following pages for information about changing specific volume settings. Renaming a Volume You must use Xsan Admin to change the name users see when the volume is mounted on their computers. You can’t rename Xsan volumes using the Finder. Warning: Renaming a volume causes all data on the volume to be lost.
5 Mount the volume on clients. Select the volume and click Clients. Select clients and click Mount. Setting the Block Allocation Size The default file system block allocation size (4 KB) is adequate for most volumes. However, you can adjust this value along with the stripe breadth of the volume’s storage pools to tune performance for special applications. For help choosing a block allocation size, see “Choosing Block Allocation Size for a Volume,” below.
Choosing Block Allocation Size for a Volume Xsan uses the volume block allocation size and storage pool stripe breadth together to decide how to write data to a volume. For most SANs, the default values for volume block allocation size and storage pool stripe breadth result in good performance. However, in some cases you might be able to improve read and write performance by adjusting these values to suit a specific application.
Setting the Volume Allocation Strategy You can set the allocation strategy for a volume to determine the order in which data is written to the volume’s storage pools. To set the allocation strategy: 1 In Xsan Admin, select the volume in the SAN Components list, click Clients, and unmount the volume from all clients and controllers. 2 Click Stop Volume.
Enabling or Disabling Access Control Lists You can use Xsan Admin to specify whether the Xsan file system uses access control lists (ACLs) on a volume. To use ACLs, your SAN controller must be running Xsan 1.4. Only Xsan 1.4 clients and Windows StorNext clients recognize ACLs. (ACLs on Xsan volumes are ignored by UNIX clients as well as clients running Xsan 1.3 or earlier.
Choosing the Windows ID Mapping Method Use the Windows ID Mapping setting to specify how Windows clients map user and group information to Xsan-compatible user IDs (UIDs) and group IDs (GIDs), which they need in order to access Xsan volumes. For more information, see “Mapping Windows User and Group IDs” on page 112. Checking Volume Fragmentation When you create a file, Xsan breaks the file into pieces and distributes these pieces efficiently over the LUNs that make up one of the volume’s storage pools.
Defragmenting a Volume Defragmenting a file reassembles its pieces into the most efficient arrangement. You can use the snfsdefrag command to defragment a single file, a folder (directory of files), or an entire volume. To defragment a file, folder, or volume: 1 Open Terminal (in /Applications/Utilities/).
Checking the Integrity of a Volume If SAN users are having trouble accessing files, you can use the cvfsck command to check the integrity of a volume, its metadata, and files. To check a volume: 1 Open Terminal (in /Applications/Utilities/). 2 If you are not working at the SAN controller computer, use SSH to log in to the controller remotely: $ ssh user@computer where user is an administrator user on the controller computer and computer is the controller’s name or IP address.
Repairing a Volume If the cvfsck utility reveals problems with a volume, you can use the same command to repair the volume. To repair a volume: 1 Stop the volume. Open Xsan Admin, select the volume, and click Stop Volume. 2 Open Terminal (in /Applications/Utilities/). If you are not working at the SAN controller computer, use SSH to log in to the controller remotely: $ ssh user@computer where user is an administrator user on the controller computer and computer is the controller’s name or IP address.
4 Managing Clients and Users 4 This chapter shows how to add, control, and remove client computers and their users. Xsan clients are computers that have access to a SAN.
Adding a Client Before a computer can access a SAN volume, you need to set up that computer as a SAN client. To add a client computer to a SAN: 1 If you haven’t already, connect the client computer to the SAN’s Fibre Channel and Ethernet networks and install the Xsan software. 2 Open Xsan Admin, select the SAN in the SAN Components list, and click Setup. 3 Click Computers, select the new computer in the list, and click Edit.
4 Choose Client from the Role pop-up menu. You can choose Controller if you want the computer to be used as a client but want it also to be available as a standby controller for the SAN. 5 Type an Xsan software serial number. You can find the serial number for a single copy of Xsan on the Xsan installation disc sleeve. If you have purchased a site-licensed serial number, look on the paperwork you received when you purchased the license.
Mounting a Volume on a Client A user who is logged in to a client computer can’t mount a SAN volume. You or another SAN administrator must use Xsan Admin to mount the volume on the client computer. To mount an Xsan volume on a client: 1 Open Xsan Admin, select the volume in the SAN Components list, and click Clients. 2 Select the client computer in the list. 3 To allow the client to modify files on the volume, click Mount Read & Write. To prevent the client from modifying the volume, click Mount Read Only.
Controlling Client and User Access You can control access to information on SAN volumes at several levels: Â You can restrict user access to folders on a volume by specifying owner, group, and general access permissions using the Finder (folder level). Â You can restrict user access to folders on a volume or the entire volume using access control lists in Mac OS X Server’s Workgroup Manager (folder/volume level). Â You can unmount a SAN volume from selected client computers (volume level).
Setting Up Access Control Lists You can use Mac OS X Server’s Workgroup Manager to control access to SAN volumes and folders on those volumes using access control lists (ACLs). To set up the access control list for a volume or folder: m Make sure ACLs are enabled on the volume. For help, see “Enabling or Disabling Access Control Lists” on page 100. Then open Workgroup Manager and click Sharing. Select the SAN volume or folder, click Access, and drag user or group names to the access control list.
4 Click Mount Read Only. Removing a Client from a SAN You can remove a client computer from a SAN to prevent it from accessing SAN volumes. To remove a client from a SAN: m Physically disconnect the client computer from the SAN’s Ethernet and Fibre Channel networks or remove the Xsan software from the client. Removing Xsan Software from a Computer If you’re no longer using a computer on a SAN, you can remove the Xsan software from the computer.
Mapping Windows User and Group IDs You can use the Windows ID Mapping setting for a volume to specify how Windows clients map user and group information to Xsan-compatible user IDs (UIDs) and group IDs (GIDs), which they need in order to access Xsan volumes. Note: To use ID mapping, Windows clients must be running StorNext 2.7. Xsan controllers and clients must be running Xsan 1.3 or later.
To select the Windows ID mapping method: 1 In Xsan Admin, select the volume in the SAN Components list, click Clients, and unmount the volume from all clients and controllers. 2 Click Stop Volume. Important: If you forget to unmount the volume (in step 1) before you stop it, be sure to click Disconnect in the “server no longer available” alert that appears on any computer that has the volume mounted. 3 Select the SAN, click Setup, and click Storage. 4 Double-click the volume in the list.
Setting User and Group Quotas You can set quotas to manage the amount of storage available to a user or group. To set storage quotas for users and groups: 1 If the volume is not already started, start it. Open Xsan Admin, select the volume, and click Start Volume. 2 In Xsan Admin, select the volume and click Quotas. 3 If the user or group is not in the list, click the Add (+) button next to the list and drag users or groups from the drawer to the list.
If the user or group doesn’t appear in the drawer, open Directory Access and make sure the computer is using the correct directory for authentication. 4 Select the user or group in the list and type their hard quota, soft quota, and grace period in the fields below the list. 5 Click Save to enforce the specified quotas or Revert to restore the last saved values. From the Command Line You can also set user quotas using the cvadmin quotas set command in Terminal.
Hard Quota The hard quota is an absolute limit on the space a user or group can occupy. Users are prevented from using more space than specified by their hard quotas. A user who tries to exceed the hard quota sees a message containing the error code -1425. Grace Period A user or group can exceed the soft quota without penalty as long as each returns below the soft quota within the grace period you specify.
Define SAN Users Consistently for Accurate Quotas To be sure that Xsan user quota information is accurate, make sure user names and IDs are consistent on all computers on the SAN. For more information, see “Set Up SAN Users and Groups” on page 54. Checking User Quota Use You can use Xsan Admin to check file system quotas to see how much of their allotment users and groups are using.
To view quota utilization: m Open Xsan Admin, select a volume in the SAN Components list, and click Quotas. To be sure you’re seeing the latest information, click Refresh at the top of the window. Xsan Admin lists the following information for each user or group: Â Quota: The soft and hard quotas. For example, “75 – 100 MB” indicates a soft quota of 75 MB and a hard quota of 100 MB. Â Used: The amount of space the user’s files are occupying.
Helping Clients Check Their Own Quotas SAN users who work at client computers but don’t have access to Xsan Admin can use the Xsan User Quotas application to check their personal space quotas. To check your quota from a client computer: m Open the Xsan User Quotas application (in /Applications/Server/). Note: The Xsan User Quotas application is installed only on computers running Mac OS X or Mac OS X Server version 10.4 or later. You can’t use the application on earlier versions of Mac OS.
Creating Local Home Folders for Network Accounts Creating SAN user accounts in a centralized directory simplifies the job of managing user accounts for computers attached to the SAN. However, some applications, such as Final Cut Pro, work best when a user has a local home folder on the computer he or she is using. To create a local home folder for a network user account: 1 Open Workgroup Manager on the server that is acting as your Open Directory master.
5 Managing Metadata Controllers 5 This chapter shows how to add, switch, monitor, and upgrade Xsan metadata controllers. Every SAN volume you set up is managed by a metadata controller. To be sure that the volume is available to clients even if the active controller becomes unresponsive, you can set up standby controllers, one of which will assume control of the volume if the primary controller fails.
Adding a Controller You can add one or more standby controllers to a SAN so that volumes are still available if the primary controller fails. Any computer set to act as a controller can also function as a client. So, if you don’t want to dedicate a computer to act solely as a standby controller, you can use an existing client. To add a controller: 1 If you haven’t already, connect the new controller computer to the SAN’s Fibre Channel and Ethernet networks and install the Xsan software.
2 In Xsan Admin, select the SAN in the SAN Components list and click Setup. 3 Select the new controller in the computer list and click Edit. 4 Choose Controller from the Role pop-up menu. 5 Choose a failover priority and click OK. 6 Choose the Ethernet interface the controller will use to communicate with other devices on the SAN. 7 Type an Xsan software serial number. You can find the serial number for a single copy of Xsan on the Xsan installation disc sleeve.
Switching to a Standby Controller You can force an active metadata controller to turn over control of a volume to a standby controller using the cvadmin command or by stopping the file system manager process for the volume. To switch a volume to a standby controller: 1 Open Terminal (in /Applications/Utilities/) on any controller or client connected to the SAN. 2 In Terminal, type: $ sudo cvadmin -e ”fail volume“ where volume is the name of an Xsan volume.
Finding Out Which Controller Is Hosting a Volume Control of a particular volume can move from one controller to another as a result of controller failover. You can use Xsan Admin to find out which controller is currently hosting a particular volume.
To view a volume’s controller: m Open Xsan Admin, select the volume in the SAN Components list, and click Overview. From the Command Line You can also find out which controller is hosting a volume using the cvadmin command in Terminal. Open Terminal on the controller and type: $ sudo cvadmin -e select For more information, see the cvadmin man page or “Viewing or Changing Volume and Storage Pool Settings (cvadmin)” on page 164.
Listing the Volumes Hosted by a Controller You can use Xsan Admin or the cvadmin command to find out which SAN volumes are being hosted by a particular controller. A list of controllers on the selected SAN and the volumes they are hosting To list hosted volumes: m Open Xsan Admin, select a SAN in the SAN Components list, and click Overview. From the Command Line You can also find out which volumes are hosted by a controller using the cvadmin select command in Terminal.
Changing a Controller’s IP Address Follow these instructions if you need to change the IP address of an Xsan controller. Warning: To avoid losing all data on the volumes hosted by the controller, you must have a standby controller available. To change a controller’s IP address: 1 Make sure your standby controller is ready.
5 In Xsan Admin, change the role of the computer from Client back to Controller. If you want to switch control of the volumes back to the controller with the new IP address (they’re currently hosted by the standby controller), stop and restart them. You can also force the switch from the command line by typing: $ sudo cvadmin -e ”fail volume“ where volume is the name of an Xsan volume.
To upgrade controller software without interruption: 1 Switch all volumes to a standby controller. Go to the primary controller, open Terminal, and type: $ sudo cvadmin -e ”fail volume“ where volume is the name of an Xsan volume. To see a list of volumes hosted by the controller, type: $ sudo cvadmin -e select To see which controller is hosting a volume, open Xsan Admin, select the volume, and click Overview.
6 Monitoring SAN Status 6 This chapter shows how to check the condition of a SAN and its components.
Locking Xsan Admin Views for Secure Monitoring You can use the Lock View command to allow SAN monitoring without the risk of accidental or malicious configuration changes. For example, you might want to monitor a SAN from an unsecured computer or allow specific people to monitor a SAN without letting them change its configuration. To lock views: m Open Xsan Admin and choose View > Lock View.
Checking Overall SAN Status Xsan Admin can show you an overview of SAN status. To get a quick look at the status of a SAN: m Open Xsan Admin, select a SAN, and click Overview. To check the controller process for a particular volume, select the volume and click Overview.
Checking Overall Volume Status Xsan Admin can show you an overview of the status of a particular volume. To get a quick look at the status of a volume: m Open Xsan Admin, select a volume, and click Overview.
Checking Free Space on a Volume There are several ways to see how much space is available on a SAN volume. To see how much free space is available on a volume: m If you’re using a computer on which the volume is mounted, select the volume in a Finder window and look at the size information at the bottom of the window (in column or list view) or choose File > Get Info.
Checking Free Space on a Storage Pool In addition to checking free space on a volume, you can check free space on the individual storage pools that make up the volume. To see how much free space is available on a storage pool: 1 Open Xsan Admin and connect to a SAN controller. 2 Select the volume in the SAN Components list, click Overview, and look in the Storage Pools list at the bottom of the window. From the Command Line You can also check storage pool free space using the cvadmin show command.
3 Choose the type of data you want to graph from the Show pop-up menu and choose a computer from the On pop-up menu. Use the slider at the bottom of the window to adjust the time period displayed in the graph. To turn off mathematical smoothing of the graphs and see only data points, choose Xsan Admin > Preferences and disable “Smooth graphs under 12 hours.
Setting Up Status Notifications Xsan can send an email or dial a pager to notify you or other administrators when:  A controller switches to its backup  A Fibre Channel connection fails  Free space on a volume falls below a specific percentage  A user or group exceeds the designated soft quota  A serial number is about to expire To send email notifications outside the local network, the controller needs access to an SMTP server.
Checking the Status of File System Processes You can use Xsan Admin to see if Xsan file system processes are running. To see if Xsan processes are running: m To check the main controller process, open Xsan Admin, select a SAN, and click Overview. To check the controller process for a particular volume, select the volume and click Overview. From the Command Line You can also check to see if the file system processes are running using the cvadmin command in Terminal.
From the Command Line To see the log for a particular volume from the command line, look at the log file: /Library/Filesystems/Xsan/data//log/cvlog where is the name of the volume. Checking Volume Clients You can use Xsan Admin to see a summary of how many clients are using a volume or a complete list of those clients. To see the clients that are using a volume: m Open Xsan Admin, select the volume in the SAN Components list, and click Clients.
Checking for Fibre Channel Connection Failures Fibre Channel connection failures or errors are recorded in the system log. To view the system log: m Open Xsan Admin, select a SAN in the SAN Components list, and click Logs. Choose System Log from the Show pop-up menu and the computer you’re interested in from the On pop-up menu.
7 Solving SAN Problems 7 This chapter provides solutions to common problems you might encounter while working with a SAN. Look here for solutions to common problems you might encounter while setting up, managing, or using an Xsan SAN. A Dialog on a Client Reports That a LUN Is Unreadable Xsan volumes can now include LUNs larger than 2 terabytes (TB). However, older clients (those running Xsan on Mac OS X 10.3 Panther or Xsan 1.2 or earlier on Mac OS X 10.4 Tiger) cannot read these large LUNs.
You’re Unable to Install the Xsan Software If the installer says you can’t install the Xsan 1.4 software on a particular computer, make sure the computer has Mac OS X or Mac OS X Server version 10.4.7 or later installed. Some Computers Aren’t Listed in Xsan Admin If a computer you want to add to the SAN as a controller or client is not listed in Xsan Admin, make sure: Â You have installed the Xsan software on the computer. Â The computer is powered on.
Xserve RAID LUNs Aren’t Accessible over Fibre Channel  If you are using a Vixel 355 Fibre Channel switch, connect the Xserve RAID systems to an FL (arbitrated loop) port on the switch.  Try restarting the computer that doesn’t see the LUNs.  Check the configuration of the Fibre Channel switch to be sure the SAN components are in the same Fibre Channel zone.
Some LUNs Aren’t Listed in Xsan Admin If you reuse an array that was previously labeled for use in another Xsan storage pool, you might need to remove the old label before Xsan Admin will recognize the LUN as available. This can also happen if you slice a LUN you used previously, in which case you might need to relabel the first slice, which still has the old label. To see if a LUN is mounted using an old label, open Terminal and type: $ sudo cvlabel -l -s This will show the old label.
Some LUNs Are Listed Twice in Xsan Admin If you are using mismatched versions of Xserve RAID firmware and the RAID Admin application, you might see duplicate LUNs listed in the LUNs pane in Xsan Admin. To remove the duplicates: m Open RAID Admin, select the Xserve RAID system that is hosting the LUNs, and choose System > Repair LUN Map. If you don’t see the Repair LUN Map command, upgrade to the latest version of RAID Admin (available at www.apple.com/support/).
Problems Using Command-Line Tools  If you get the response “command not found” when you try to use an Xsan command-line tool, add /Library/Filesystems/Xsan/bin/ to your search path or switch to this folder before you type the command. For example, to use the cvadmin tool: $ cd /Library/Filesystems/Xsan/bin $ sudo ./cvversions  If you get the response “Cannot list FSS - reason -Bad file descriptor” when you run the cvadmin tool, make sure you are using the tool as the root user.
You’re Unable to Rename an Xsan Volume in the Finder Xsan doesn’t allow a mounted Xsan volume to be renamed using the Finder. If you try, you get a message saying the name you’ve typed can’t be used, even if the name you type is an acceptable Xsan volume name. To rename an Xsan volume, you must use Xsan Admin to reinitialize the volume. For instructions, see “Renaming a Volume” on page 96.
A Client is Unable to Use a Volume After a Fibre Channel Interruption If a client loses its Fibre Channel connection to the SAN (because a cable is unplugged, for example), the client might not recognize LUNs in an Xsan volume after the connection is restored. If this happens, restart the client to remount the volume. If problems persist, restart all SAN devices. Begin with Xserve RAID systems, continue with SAN controllers, and finally restart all clients.
You’re Unable to Add a Storage Pool There are some reserved names you can’t use to name a storage pool. If you type one of these names, the OK button in the storage pool sheet is disabled.
Reserved storage pool names DiskType MirrorReadMethod UnixNobodyUidOnWindows Enabled MultiPathMethod UnixNobodyGidOnWindows Exclusive No UnixFileCreationMode . . . ForcePerfectFit Node UnixDirectoryCreation . . .
To check the common LUN size for a storage pool: m In Xsan Admin, select the SAN or controller from the SAN Components list and click Setup. Click Storage, and then click the disclosure triangle next to the storage pool to see the sizes of the LUNs it contains. To check the size of the LUN you want to add: m In Xsan Admin, select the SAN or controller from the SAN Components list, click Setup, and then click Available LUNs.
4 If the capacity shown remains 2 TB or less, delete the current label (in the Label field), click OK, and click Save. Then select the unlabeled LUN, click Edit to reopen it, and select “Allow LUN to exceed 2 TB capacity.” The capacity shown should now match the actual size of the LUN. 5 Type a label and click Save.
Combining Xsan and StorNext Clients and Controllers A Appendix A This appendix shows how to add Macintosh clients to an existing StorNext File System SAN or connect Windows, Solaris, AIX, Irix, or Linux clients to an Xsan SAN.
Compatible Software Versions The following table shows which versions of Xsan and StorNext controllers and clients can be used on the same SAN. Controller Client Compatible Xsan 1.4 StorNext 2.8 No Xsan 1.3 (Mac OS X v10.4) StorNext FX 1.3 or 1.4 Yes StorNext 2.6 or 2.7 Yes StorNext 2.5 or earlier No StorNext FX 1.3 or 1.4 Yes StorNext 2.6 or 2.7 Yes StorNext 2.5 or earlier No StorNext 2.8 Xsan 1.4 or 1.3 Yes StorNext 2.7 Xsan 1.4 or 1.3 Yes StorNext 2.6 or earlier Xsan 1.4 or 1.
Adding Macintosh Clients to a StorNext SAN If you already have a StorNext File System SAN, you can add a Macintosh client using Xsan. To add a Macintosh Xsan client to a StorNext SAN: 1 Connect the Macintosh computer to the SAN’s Ethernet and Fibre Channel networks. 2 Install the Xsan software on the Macintosh computer. 3 License the Xsan software on the Macintosh client. Open Xsan Admin on the client (in /Applications/Server/) and connect to the local computer.
6 Delete or move the following files from /Library/Filesystems/Xsan/config/: automount.plist saninfo.plist notifications.plist .auth_secret Note: If you decide to move this computer to an Xsan SAN with Macintosh controllers, you need to restore these files to their original location (or reinstall Xsan) before adding the computer to the Xsan SAN. 7 Force the Xsan software on the Macintosh to read the new fsnameservers file.
Using Xsan Controllers with StorNext Clients You can use ADIC’s StorNext software to access an Xsan SAN from a Windows, UNIX, AIX, Irix, or Linux computer. 1 Connect the non-Macintosh client to the SAN’s Fibre Channel and Ethernet networks. 2 Install the StorNext File System software on the non-Macintosh client following the instructions that ADIC provides in the StorNext package. 3 Duplicate the Macintosh Xsan controller’s shared secret file on the non-Macintosh client. The shared secret file is named .
Using the Command Line B Appendix B This appendix describes Xsan shell commands and configuration files you can use to work with a SAN from the command line. You can use the shell commands and configuration files described here to access, set up, and manage Xsan SANs, LUNs, storage pools, and volumes from the command line. Using the Shell Commands The Xsan command-line utilities are located in /Library/Filesystems/Xsan/bin/, which is part of the default shell search path.
Sending Commands to Remote Computers To use commands on a remote computer, first use SSH to log in to the other computer: $ ssh user@computer where user is a user account on the remote computer and computer is its IP address or DNS name. Viewing the Man Pages UNIX-style man pages describing each of the commands are available in /Library/ Filesystems/Xsan/man/. If you get the response “No manual entry for . . .
Notation Conventions The following conventions are used throughout the command descriptions. Notation Indicates fixed-width font A command or other terminal text $ A shell prompt [text_in_brackets] An optional parameter (one|other) Alternative parameters (type one or the other) underlined A parameter you must replace with a value [...
The Commands Xsan includes the following command-line tools: Command Description cvadmin View or change volume and storage pool settings (page 164) cvcp Copy files or folders (page 168) cvfsck Check or repair a volume (page 171) cvlabel View, label, and initialize LUNs (page 172) cvmkdir Create a folder with an affinity (page 173) cvmkfile Create and preallocate a file (page 174) cvmkfs Initialize a volume (page 175) cvupdatefs Apply volume setup changes (page 176) fsm Start a volume cont
To execute commands from a file: $ sudo cvadmin [-H host] [-F volume] -f cmdfile To execute a single command and return to the shell prompt: $ sudo cvadmin [-H host] [-F volume] [”]-e command [cmdparam...“] Parameter Description -H host The metadata controller that is hosting the volume. If not provided, the local computer is assumed. host – the IP address or DNS name of a metadata controller other than the one on which you are logged in.
cvadmin Commands cvadmin command Description activate Choose the “active” volume that you want to work with interactively. volume – the name of the volume index – the numeric ID of the volume (to see a list of these, use the cvadmin select command without any parameters) [volume|index] [read|write] Prevent read or write access to a storage pool. pool – the name of a storage pool in the currently active volume. disks [refresh] List LUNs. down pool Disallow all access to a storage pool.
cvadmin command Description quotas [yes|no] Enable or disable quotas for the active (selected) volume. Use the command without any parameters to see the current setting for quotas. quotas get (user|group) name Display current quota information for a user or group. name – the name of the user or group quotas set (user|group) name hard soft grace Set quotas for user or group name.
cvadmin command Description show [pool] [long] List storage pool information for the active volume. start volume [on] [controller] Start the volume based on the information in its configuration file (/Library/Filesystems/Xsan/config/volume.cfg). controller – The address of the controller to start the volume’s FSM process on. stat Display information about the active volume. stop volume Stop the active volume and its FSM process. up pool Allow access to the specified storage pool.
cvcp Command Options Option Description -A Turn off preallocation. -b buffers Set the number of I/O buffers to use. buffers – the number of buffers to use for the copy -k size Set the copy buffer size. size – the buffer size (bytes) -l Copy the targets of symbolic links, not the links. -n Do not apply command to subfolders. -p prefix Only copy files with names that start with the specified prefix.
Examples Copy the file friday to /datasets/data1/july/: $ cvcp friday /datasets/data1/july Copy the folder /data1/ and all subfolders to /datasets/data1/, retaining all permissions and ownerships and displaying files as they are copied: $ cvcp -vxy data1 /datasets/data1 Perform a similar copy as above, but only copy files with names that begin “jul”: $ cvcp -vxy -p jul data1 /datasets/data1/july Copy the folder /datasets/ to a tar file named /transfers/data.tar: $ cvcp .
Checking or Repairing a Volume (cvfsck) You can use the cvfsck command to check or repair an Xsan volume. $ cvfsck [options] volume Parameter Description options See “cvfsck Command Options,” below. volume The name of the volume to check or repair. cvfsck Command Options Option Description -d Display extra debugging information. -e Display file extents statistics. -f Report fragmentation. -g Print journal recovery log. -j Perform journal recovery. -J Display raw journal data.
Labeling, Listing, and Unlabeling LUNs (cvlabel) You can use the cvlabel command to initialize LUNs so they can be added to storage pools. For additional details, see the cvlabel man page. To list available LUNs: $ cvlabel -l [-s] [-v] To list current LUN and label information you can paste into a label file: $ cvlabel -c To label a LUN: $ cvlabel [-v] [-f] [labelfile] To remove the existing label from a LUN: $ cvlabel -u lun 172 Parameter Description -l List available LUNs.
Creating a Folder with an Affinity (cvmkdir) You can use the cvmkdir command to create a folder (directory) with an affinity for a particular storage pool in an Xsan volume. $ cvmkdir [-k affinity] folder Parameter Description -k Optional parameter for specifying the name of the storage pool to be associated with the folder. If you omit this parameter, Xsan creates a folder without an affinity. affinity The name of a storage pool’s affinity key.
Creating and Preallocating a File (cvmkfile) You can use the cvmkfile command to allocate space for a file on an Xsan volume. $ cvmkfile [-k affinity] [-p] [-s] [-w] [-z] size(k|m|g) filename 174 Parameter Description -k affinity Allocate space for the file on the storage pool with the specified affinity key. affinity – the affinity key (in Xsan, the affinity key is the same as the name of the storage pool) You can use the cvadmin show long command to see a storage pool’s affinity key.
Example Allocate 2 GB of space for the file “data1” on the storage pool “datasets”: $ cvmkfile -k datasets 2g data1 Initializing a Volume (cvmkfs) You can use the cvmkfs command to initialize an Xsan volume based on the information in the corresponding configuration file for the volume (in /Library/Filesystems/Xsan/config/.cfg). Warning: Initializing a volume destroys all existing data on the volume.
Applying Volume Configuration Changes (cvupdatefs) You can use the cvupdatefs command to apply configuration file changes to a volume after you modify the volume’s configuration files. $ cvupdatefs [-f] volume [configdir] Parameter Description -f Update without prompting for confirmation or advising of errors in the configuration file. volume The volume to update. If you don’t specify a volume, available volumes are listed for you to choose from. configdir Location of the volume’s configuration (.
Starting a Port Mapper Process (fsmpm) You can use the fsmpm command to start a file system port mapper process on a client or controller. $ fsmpm For more information, see the fsmpm man page. Defragmenting a File, Folder, or Volume (snfsdefrag) You can use the snfsdefrag command to defragment a file by reallocating its data in a single extent. This can improve read and write performance for a file by increasing disk efficiency and reducing file metadata management overhead.
Parameter Description -c Display an extent count but don’t defragment target. -D Display debugging messages. -d Operate on files with other than the current depth. -e Report extents without defragmenting. -K affinity Only operate on files with the specified storage pool affinity. affinity – the affinity key (in Xsan, the affinity key is the same as the name of the storage pool) You can use the cvadmin show long command to see a storage pool’s affinity key.
Examples Count the extents in the file “datafile”: $ snfsdefrag -c datafile List the extents: $ snfsdefrag -e datafile Defragment the file “datafile”: $ snfsdefrag datafile Defragment the file “datafile” only if it has more than two extents: $ snfsdefrag -m 2 datafile Defragment every file in the folder /datafolder/ (or any folder within /datafolder/) that has more than one extent: $ snfsdefrag -r datafolder Recover unused preallocated disk space assigned to every file in folder /datafolder/: $ snfsdef
2 Create the mount point where the file system will be mounted: $ mkdir mountpoint where mountpoint is the directory where the file system is mounted (usually in / Volumes/; for example /Volumes/SanVol). 3 Mount the volume: $ sudo mount -t acfs volume mountpoint where volume is the name of the volume and mountpoint is the mount point you created in step 2.
Viewing Logs The system log to which Xsan writes information about SANs is in /var/log/system.log Volume logs are in /Library/Filesystems/Xsan/data//log/cvlog, where is the name of the specific volume. The Configuration Files Xsan stores its configuration information in the following files: File Contents /Library/Filesystems/Xsan/config/.
Glossary Glossary affinity A relationship between a folder on an Xsan volume and one of the storage pools that provide storage for the volume. The affinity guarantees that files placed in the folder are stored only on the associated storage pool. Storage pools can differ in capacity and performance, and affinities can be used to assure that data such as video, which requires high transfer speed, is stored on the fastest storage devices.
controller In an Xsan storage area network, short for metadata controller. See metadata controller. In RAID systems, controller refers to hardware that manages the reading and writing of data. By segmenting and writing or reading data on multiple drives simultaneously, the RAID controller achieves fast and highly efficient storage and access. failover In Xsan, the automatic process by which a standby metadata controller becomes the active metadata controller if the primary controller fails.
label (verb) Used by some sources (such as ADIC) to refer to the process of preparing a logical disk for use with a file system. In Xsan, however, use initialize to refer to preparing a disk for use in a storage pool. logical disk A storage device that appears to a user as a single disk for storing files, even though it might actually consist of more than one physical disk drive.
RAID array A group of physical disks organized and protected by a RAID scheme and presented by RAID hardware or software as a single logical disk. In Xsan, RAID arrays appear as LUNs, which are combined to form storage pools. round robin An Xsan storage pool allocation strategy. In a volume consisting of more than one storage pool, Xsan allocates space for successive writes to each available pool in turn. SAN Storage area network.
“command not found” message 148 “No manual entry for...” message 148 A access permissions for folders 109 read-only volumes 110 unmounting a volume 110 access control list.
D email notifications 138 error -1425 149 Ethernet guidelines 36 expanding storage 30, 78 volume allocation strategy 64, 99 firewall, and Xsan Admin 52 fragmentation 101 free space checking quota use 117 checking storage pool 136 checking volume 135 fsm command 176 fsmpm command 177 fsnameservers file 157 FSS.
limit per storage pool 31 limit per volume 31 maximum size 31 name length limit 31 overview 21 preparing 51 removing old label 146 size adjusted downward 148 N R naming limits 31 New Storage Pool button 65 New Volume button 63 notation conventions for commands 163 notifications mail service required 38 setting up 68, 138 RAID schemes for LUNs 44 read-only volumes 110 refresh interval, Xsan Admin 52 repairing a volume 104 role, choosing 59, 107 rotate multipath method 94 round robin volume allocation str
cvmkdir 173 cvmkfile 174 cvmkfs 175 cvupdatefs 176 fsm 176 fsmpm 177 installed location 161 listed in table 164 man pages 162 problems using 148 snfsdefrag 177 snfsdefrag command 177 defragmenting files 102 soft quota checking 117 defined 115 setting 72, 114 SSL, and Xsan Admin 52 static multipath method 94 storage, expanding 78 storage area network.
repairing 104 show clients using 140 starting 73 trouble mounting 144 unmounting 110, 180 X Xsan Admin application and firewalls 52 Index installing separately 52 overview 51 preferences 52 refresh interval 52 Xsan software compatibility with StorNext software 156 installing 55 removing (uninstalling) 111 serial number 60, 107, 123 upgrading controllers 129 version compatibility 12 Xsan User Quotas application 119 Xserve RAID systems checking state 141 191