Library Table of Contents Index Previous Next Comments

Creating LUNs with the lun setup program

What the lun setup program does  Top

The lun setup program prompts you for information needed for creating a LUN and an initiator group, and for mapping the LUN to the initiator group. When a default is provided, you can press Enter to accept the default.

If you did not create volumes and qtrees to store LUNs in prior to running the lun setup program, you must terminate the program and create volumes and qtrees, if you want to use them.

If you did not create initiator groups, you can create them during the lun setup program.

Running the lun setup program  Top

To run the lun setup program, complete the following steps. The answers given are an example of creating LUNs using FCP in a Solaris environment.

Step

Action

1

On the filer command line, enter the following command. If you press Enter, to select y, the lun setup program provides instructions and prompts you to enter your values, as shown in the remaining steps. If you press n, the program terminates.

lun setup
Result

The lun setup program displays the following instructions:

  This setup will take you through the steps needed to create LUNs
  and to make them accessible by initiators. You can type ^C (Control-C)
  at any time to abort the setup and no unconfirmed changes will be made 
  to the system.
Do you want to create a LUN? [y]:
2

Specify the operating system that will be accessing the LUN by responding to the next prompt:

OS type of LUN (default/solaris/windows) [default]:
Example
solaris

If you press Enter to select default, the contents of the LUN are not specified. Typing solaris indicates that the LUN will store a Solaris raw disk in a single-slice partition. Typing windows indicates that the LUN will store a raw disk device in a single-partition Windows disk.

3

Specify where the LUN will be located by responding to the next prompt:

    A LUN path must be absolute. A LUN can only reside in a volume
    or qtree root. For example, to create a LUN with the name "lun0" 
    in the qtree root /vol/vol/q0, specify the path as "/vol/vol1/q0/lun0".
Enter LUN path: 
Example

If you previously created /vol/vol1/, you would enter /vol/vol1/lun0.

Caution
Do not create LUNs in /vol/vol0. This is the root volume used for filer administration.

Result

lun0 is created in the root of /vol/vol1 if the configuration information is accepted later in this program.

4

Specify whether you want the LUN created with space reservations enabled.

    A LUN can be created with or without space reservations being enabled.
    Space reservation guarantees that data writes to that LUN will never fail.
Do you want the LUN to be space reserved? [y]: 
Example

Press Enter to accept the default.

5

Specify the size of the LUN by responding to the next prompt:

    Size for a LUN is specified in bytes. You can use single-character
    multiplier suffixes: b(sectors), k(KB), m(MB), g(GB) or t(TB).
Enter LUN size: 
Example
5g
Result

A LUN with 5 GB of raw disk space is created if the configuration information is accepted later in this program. The amount of usable disk space by the host varies depending on the operating system type and the application using the LUN.

6

Create a comment or a brief description about the LUN by responding to the next prompt:

    You can add a comment string to describe the contents of the LUN.
    Please type a string (without quotes), or hit ENTER if you don't 
    want to supply a comment.
Enter comment string:
Example

5 GB Solaris LUN for finance records

If you do not want to provide a comment at this time, press Enter. You can add a comment later with the lun comment command or a description by using FilerView.

7

Create an initiator group by responding to the next prompt:

    The LUN will be accessible to an initiator group. You can use an
    existing group name, or supply a new name to create a new initiator
    group. Enter `?' to see existing initiator group names.
Name of initiator group[]: 

Example 1:

?

Result 1

If you did not create any initiator groups yet, the following message is displayed:

    No existing initiator groups
Name of initiator group[]:
Result 2

If you already created one or more initiator groups, they are displayed. If you created two initiator groups, solaris-igroup1 and solaris-igroup2, they appear as follows:

Name of initiator group[]: ?
    Existing initiator groups:
    solaris-igroup1
    solaris-igroup2
Name of initiator group[solaris-igroup1]:

Press Enter to accept the default for the last initiator group used; otherwise, enter the name of the initiator group that contains the initiator you want to allow access to the LUN you are creating. When you enter the name of an existing initiator group, it is displayed, along with the WWPNs it contains, as shown in the following message:

    solaris-igroup1
          10:00:00:00:c9:2c:43:a0
          10:00:00:00:c9:2c:46:60
          The LUN will be accessible to all initiators in the 
          initiator group. Enter `?' to display the LUNs already in use
          by one or more initiators in group "solaris-igroup1".

Example 2

solaris-igroup3

Result

The initiator group solaris-igroup3 is created.

Note
The name of the initiator group that you create is independent of the name of the host that is used by the host operating system, host files, or DNS.

8

Specify which protocol will be used by the host in the initiator group by responding to the next prompt. Press Enter to accept the default.

Type of initiator group solaris-igroup3 (FCP/iSCSI)[FCP]: 
Result

The initiator unique identifiers (FCP WWPNs) in this initiator group use the FCP protocol.

9

Add the unique identifiers (iSCSI node names or FCP WWPNs) of the hosts that will be in the initiator group by responding to the next prompt:

    A Fibre Channel Protocol (FCP) initiator group is a collection of 
    initiator port names. Each port name (WWPN) is 16 hexadecimal digits,
    separated (only) by optional colon (:) characters. You can separate 
    port names by commas. Enter `?' to display a list of connected 
    initiators. Hit ENTER when you are done adding port names to this 
    group. 
Enter comma separated portnames:

Example 1

?

Result

The following output is a sample of what is displayed.

Initiators connected on adapter 4a
Portname                             Group
10:00:00:00:c9:2b:cc:51
10:00:00:00:c9:2b:dd:62
10:00:00:00:c9:2b:ee:5d
Adapter 4b is running on behalf of the partner.
Initiators connected on adapter 5a:
      None connected.
Enter comma separated portnames: 

Example 2
10:00:00:c9:2b:cc:51
Result

The initiator identified by this WWPN is added to the initiator group that was specified in Step 8. You are prompted for more portnames until you press Enter.

Note
To determine which WWPN is associated with a host, use the NetApp-supplied commands you downloaded from the CD-ROM in the HBA kit, such as sanlun for Solaris or lputilnt for Windows hosts. See the HBA installation and setup guide for your host for instructions about how to use the commands.

10

Specify the operating system type that will be accessing the LUN by responding to the next prompt:

OS type of initiator group "solaris-igroup3" (default/solaris/windows) 
[default]:
11

Specify the LUN ID that the host will map to the LUN by responding to the next prompt. Press Enter to accept the default.

    The LUN will be accessible to all the initiators in the 
    initiator group. Enter `?' to display LUNs already in use 
    by one or more initiators in group "solaris-igroup3".
LUN ID at which initiator group "solaris-igroup3" sees "/vol/vol1/lun0" [0]:
Result

If you press Enter to accept the default, Data ONTAP issues the lowest valid unallocated LUN ID to map it to the initiator, starting with zero. Alternatively, you can enter any valid number. See the HBA installation and setup guide for your host for information about valid LUN ID numbers.

Note
Network Appliance recommends that you accept the default value for the LUN ID.

After you press Enter, the lun setup program displays the information you entered:

LUN Path                : /vol/vol1/q0/lun0
OS Type                 : default
Size                    : 5g (5368709120)
Comment                 : 5 GB Solaris LUN for finance records
Initiator Group         : solaris-igroup3
Initiator Group Type    : FCP
Initiator Group Members : 10:00:00:00:c9:2b:cc:51
Mapped to LUN-ID        : 0
12

Commit the configuration information you entered by responding to the next prompt:

Do you want to accept this configuration? [y]
Result

If you type y, the LUNs are mapped to the specified initiator group. All changes are committed to the system and Ctrl-C cannot undo these changes. The LUN is created and mapped. If you want to modify the LUN, its mapping, or any of its attributes, you need to use individual commands or FilerView. See Chapter 3, Managing LUNs.

13

Either continue creating LUNs, or terminate the program by responding to the next prompt. Press Enter to terminate or type y to continue:

Do you want to create another LUN? [n]

Library Table of Contents Index Previous Next Comments