You are on page 1of 8

how to resize LUN lun resize <lun path> <size> lun resize /vol/tradvol1/lun1 75m lun

NAME lun - Commands for managing LUNs SYNOPSIS lun command argument ... DESCRIPTION The lun command is used to create and manage luns, and their mappings using SAN protocols. USAGE The following commands are available in the lun suite : clone help online share comment map resize show config_check maxsize serial snap create move set stats destroy offline setup unmap LUN cloning allows the user to create a copy of a LUN, which was initially creat ed to be backed by a LUN or a file in a snapshot ( that is, using lun clone create ). LUN cloning cre ates a complete copy of the LUN and frees the snapshot, which can then be deleted. The following command s can be used to manage this feature: lun clone create clone_lunpath [ -o noreserve ] -b parent_lunpath parent_snap The lun clone create command creates a lun on the local filer that is a clone of a "backing" lun. A clone is a lun that is a writable snapshot of another lun. Initially, the clone and it s parent share the same storage; more storage space is consumed only as one lun or the other changes. The parent_snap is locked in the parent volume, preventing its deletion until th e clone is either destroyed or split from the parent using the lun clone split start command. The lun clone create command fails if the chosen parent_lunpath is currently inv olved in a lun clone split operation. lun clone split start [-d] lun_path This command begins separating clone lun_path from its underlying parent. New st orage is allocated for the clone lun that is distinct from the parent. This process may take some time and proceeds in the background. Use the lun clon e split status command to view the command s progress.

Displays the cloning status of the lun in terms of percentage complete. lun clone stop lun_path Stop the cloning of the lun at the given lun_path. Upon completion. Usage of lun clone stop has been deprecated. lun comment lun_path [ comment ] . disables space-efficient splitting in favor of the legacy style of splitting clones. lun clone status lun_path Display the status of the cloning of the lun at the given lun_path. lun clone show [ lun_path ] If no lun_path is given. Only LUNs backed by a snapsh ot can be cloned.Both clone and parent luns remain available during this process of splitting the m apart. Usage of lun clone start has been deprecated. All of the blocks that were formerly shared between lun_path and its backing lun that have already been spli t apart by the lun clone split start will remain split apart. information about all luns being cloned is shown. Volume 1 lun With the -d option supplied. the snapshot on which the clone was based will be unlocked in the pa rent vol. Please use lun show -v or lun clo ne split status to display cloning status. Usage of lun clone status has been deprecated. Instead. Instead. lun clone start lun_path Start the cloning of the lun at the given lun_path. 312 Data ONTAP 8. Usage of lun clone show has been deprecated. lun clone split stop lun_path This command stops the process of separating a clone from its parent lun. lun clone split status [ lun_path ] This command displays the progress in separating clone luns from their underlyin g parent luns. please use lun clone spli t start. please use lun clone split stop. This gives d etails about number of blocks processed until now. please use lun clone split status. Instead.1 Commands: Manual Page Reference for 7-Mode.

k (1024). The -w flag checks if dup licate WWPNs are present on the HA pair. with initially zero contents. lun create -s size -t ostype [ -o noreserve ] [ -e space_alloc ] lun_path This usage of the lun create command should be employed to create a new lun of g iven size. lun config_check [ -S | -w ] [ -s | -v ] config_check performs several checks on the lun/igroup/fcp configuration of the filer. it should be enclosed in double quotes. windows (the lun will be used to store a raw disk devic e in a single-partition Windows disk using the MBR (Master Boot Record) partitioning style). g (k*m). Optionally. w (2). hpux (the l un will be used to store HP-UX data). The size of the lun actually created is reported if it is different from that sp ecified in the command. in order to get an integral number of cylinders while reporting the geometry using SAN protocols. The lun is created at the lun_path given. linux (the lun will be used to store a Linux raw disk without any partitio n table). No file shoul d already exist at the given lun_path. vld (the lun co ntains a SnapManager VLD). The -S flag runs the SSI checks when not running in that c fmode.This command is used to display or change a comment string associated with the l un. Volume 1 313 lun Compatibility of initiator group ostype and the fcp cfmode setting FCP HBAs which are not online FCP cfmodes are set to the same thing on each filer in the HA pair Initiator names which are members of initiator groups with different ostype sett ings The SSI checks test for lun maps that conflict with maps on the partner. The directory specified in the lun_path must be a qtree root directory . a number followed by a one-character multiplier suffix can be used: c (1).1 Commands: Manual Page Reference for 7-Mode. If the comment string to be supplied has white space. t (m*m). The -v flag enables verbose output which lists the tests being done. The size is specified in bytes. The mandatory ostype argument is one of: solaris (the lun will be used to store a Solaris raw disk in a single-slice partition). vmware (the lun will be used to store V Mware data). windows_gpt (the lun will be used to store Windows data using the GPT (GUID Part . aix (the lun will be used to store AIX data). netware (the lun will be used to store NetWare data). The -s flag runs the co mmand in a silent mode and disable all output unless problems are discovered. and fcp nodenames that are different between the local and partner filer. b (512). m (k*k). The specific checks are as follows: Data ONTAP 8. The size of the created lun could be larger than the size specified.

The optional -f argument forces the lun(s) to be destroyed regardless of being m apped or online. This operation will fail if the lun is currently mapped and is online. lun destroy [ -f ] lun_path. lun help [ subcommand ] With no arguments. at the given lun_path (which must be at a qtree root). solaris_efi (th e lun will be used to store Solaris_EFI data). Provisioning threshold events can be enabled by specifying -e space_alloc option. make sure that the file does not have any space reservations enabled using the file r eservation command. xen (the lun wi ll be used to store Xen data). o noreserve can be specified. The file contents are not co pied or changed.. The specified lun(s) are destroyed. openvms (the lun will be used to store Open-VMS data). Provisioning threshold events can be enabled by specifying -e space_alloc option . lun create -f file_path -t ostype [ -o noreserve ] [ -e space_alloc ] lun_path Create a lun from an existing file. The lun has the same initial content s as the referenced snapshot copy of an existing lun. When a subcommand name is supplied. hyper_v (the lun will be used to store Hyper-V data). A new lun is created.. please use lun clone create . lun lun create -b snapshot_lun_path [ -o noreserve ] lun_path A lun is created in the active file system. the lun is space-reserved. detailed help for the specific subcommand is displayed. Using this option will create a LUN without any space being reserved. If the -o nores erve option is used. Instead. By default. available subcommands are listed with brief help texts.iton Type) partitioning style). This option has to be used in conjunction with -o noreserve. To manage space usage manually instead. lun map [ -f ] lun_path initiator_group [ lun_id ] . rounding up to a cylinder boundary. All reads to the new lun would be served by the latest content of the lun. (Note that no copy of the data is made.) Any subsequent writes to this new lun would not affect the lun in the snapshot. Usage of lun create -b has been deprecated. The file can be resized to a larger size. windows_2008 (the lun will be used to store Windows data fo r Windows 2008 systems). This option has to be used in conjunction with -o noreserve. A hard link is created to the existing file. The data container and the configuration inf ormation are discarded.

. Mappings. lun online [ -f ] lun_path. If a serial numbe r is supplied. The LUN may be resi zed to a larger size than specified. lun maxsize path This command returns the maximum possible size of a lun on a given volume or qtr ee. Re-enables block-protocol accesses to the lun(s).can be used with size to increase or decrease the lun size by the given amount. or for an initi ator group. The lun must first be made offline using the lun offline com mand before changing the serial number. The serial number is a 12-character string formed of upper an d lower-case letters. The -f flag or manual confirmation is required to reduce the size of a LUN.] size Changes the size of the lun to the input value size. Disables block-protocol accesses to the lun(s). Once created.. lun resize [ -f ] lun_path [ + | . Optional + or .Maps a lun to all the initiators in the supplied group. the smallest number that can be used for the various initiators in the group is automatically picked .. lun offline lun_path. The optional -f argument disables checking with the HA partner for lun mapping c onflicts. If a LUN ID is not speci fied. it is used for the lun henceforth. rounding up to a cylinder boundary. Note that unless explicitly taken offline. No te that client-side operations may be needed to ensure that client software recognizes the changed s ize. lun The optional -f argument disables checking with the HA partner for lun mapping c onflicts. . Note that this command can be used multiple times to configure multiple maps for a lun.. if any. The comman d returns the maximum size for different types of luns and the possible maximum size with snapshots or without snapshots. See lun offline for further in formation. lun serial lun_path [ serial_number ] Displays the persistent serial number associated with the lun. Both lun_path and to_lun_path sh ould be in the same volume. configured for the lun are not altered. a lun is online. doing so prevents any potential problems on the host side. The user can pass the path to a volume or qtree in which the lun is to be created. lun move lun_path to_lun_path Moves the lun to a new path in the same volume. Although it is possible to resize the LUN without taking the LUN offline first. you can use lun show -m to list all the LUN mappings.

lun snap usage [ -s ] vol_name snap_name Displays information about all LUNs in active file system and snapshots that are backed by the given . With the -c flag supplied. online/offline state. lun set reservation lun_path [ enable | disable ] Enables or disables the space reservation on the LUN. LUNs. When a node is spe cified. With the -m flag supplied. in formation about lun_path to initiator_group mappings is displayed in a table format. A specific lun can be indicated by supplying its lun_path. status is reported for all luns that are mapped to the initiator group. lun setup Easy to use interactive mechanism for setting up initiator groups. and map ping configuration. When an initiator_gro up is specified. status is reported for all the luns in that volume. size. LUN mapping. lun set space_alloc lun_path [ enable | disable ] Enables or disables reporting of provisioning threshold events on the LUN. The dev_id value may be 1-9999. additional information (comment string. lun set svo_offset lun_path [ offset | disable ] Set the offset used by SnapValidator for Oracle to calculate block numbers in th e presence of a host volume manager on the lun. The offset specifies the number of bytes from the beg inning of the lun to the start of Oracle data. Setting the offset to disable will disable SnapValidat or checking on this lun. set the Device ID to none. all accesses are disallowed. With the -v flag supplied. lun share lun_path { all | none | read | write } Enables file system protocol-based access to a lun. Mapped luns are ones with at least one map definition. 316 Data ONTAP 8. When s taging is specified. then the space reservation status of the given lun_path is displayed. serial number . then the reporting status of the given lun_path is displayed . and the characters /-#$%&*+<=>?@[!]^~. A lun is online if it has not been explicitly made offline using the lun offline command. This is the default setting. lun set dev_id lun_path { dev_id | none } Sets the Device Identifier that is returned in response to a REPORT DEVICE IDENT IFIER SCSI command for the specified lun_path. status is reported for all luns that are mapped to initiator groups which contain that node. information about the temporary luns preserved in the staging area is reported. To remove th e Device ID. If no arguments are suppli ed after the lun_path.1 Commands: Manual Page Reference for 7-Mode. shared state) of the given lun or class of luns. HA Pair Shared Volume Information) is also displayed. information about lun cloning status is displayed. Volume 1 lun lun show [ -v | -m | -c ] [ all | mapped | offline | online | unmapped | staging | -g initiator_group | -n node | -l vol_name | lun_path ] Displays the status (lun_path.numbers. Note that file permissions and ACL entries still apply. When vol_name is specified. By default. If no arguments are supplied after the lun_path.

Volume 1 317 lun The -o output format is as follows: /vol/volname/lun (## hours. Normally only LUNs with non-zero statistics are displayed. With no lun_path specified. you can delete the snapshot s nap_name.## ###. if vol options snapshot_clone_dependency is not set. The -s option provides a summary view of the information.## ###. which are listed in the output . The -c argument will cause output to stop after the given number of iterations. The -o option will display extra statistics. If you wish to delete the given snapshot snap_name then you must first destroy all those LUNs in the active file system. Thereafter. lun stats [ -o ] [ -a | lun_path ] Displays or zeroes block-protocol access statistics for luns. ## minutes. Write Ops The total number of SCSI write operations. ## minutes. statistics for all the LUNs are displayed. you need to delete all the snapshots liste d in the output starting from the one listed at the top. The -a option will display all LUNs. ## seconds) Read (kbytes) Write (kbytes) Read Ops Write Ops ###### ###### ###### ###### Data ONTAP 8.1 Commands: Manual Page Reference for 7-Mode. QFull The number of SCSI Queue Full responses sent per second.## lun_path The -i -o output format is as follows: Read Write Other QFull Read Write Average Queue Partner Lun Ops Ops Ops kB kB Latency Length Ops kB ##### ##### ##### ##### ###### ###### ##. Write kB Kilobytes per second write traffic. The default output format is as follows: /vol/volname/lun (## hours. The statistics start zeroed at boot time. the -z option zeroes stati stics (but does not display them). statistic only for the specified LUN is displayed.## #### ##### lun_path where. Once this is done. otherwise . The default output format for -i is as follows: Read Write Read Write Average Queue Lun Ops Ops kB kB Latency Length #### #### ##### ##### ##. Other Ops The total number of other SCSI operations.snapshot This command displays all the LUNs in all the existing snapshots which are curre ntly backed by data in the given snapshot snap_name. ## seconds) Read (kbytes) Write (kbytes) Read Ops Write Ops Other Ops QFulls Partner Ops Par tner KBytes ###### ###### ###### ###### ###### ###### ##### ###### lun stats -i interval [ -c count ] [ -o ] [ -a | lun_path ] The -i option will report per LUN performance statistics at the per-second inter val given. Read kB Kilobytes per second read traffic. Average Latency Average in milliseconds to process a request for the LUN. Queue Length . Thereafter. The time since the stats were last zeroed is displayed for each lun. Read Ops The total number of SCSI read operations.

Lun The path to the LUN. and Other ops). . Partner Ops The number of SCSI operations received via the Partner path (included in the Rea d. 318 Data ONTAP 8. Write. lun unmap lun_path initiator_group Reverses the effect of a lun map command. Volume 1 lun lun stats -z [ lun_path ] zeroes the statistics for the given lun_path or all LUNs if no path is specified .1 Commands: Manual Page Reference for 7-Mode. Partner kB Kilobtyes per second of SCSI traffic via the Partner path (included in Read kB a nd Write kb).The average number of outstanding requests pending.