.\" Automatically generated by Pod::Man 2.25 (Pod::Simple 3.16) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .ie \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . nr % 0 . rr F .\} .el \{\ . de IX .. .\} .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "NetApp::Volume 3pm" .TH NetApp::Volume 3pm "2008-11-26" "perl v5.14.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" NetApp::Volume \-\- OO class for creating and managing NetApp filer volumes .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 2 \& use NetApp::Filer; \& use NetApp::Aggregate; \& \& my $filer = NetApp::Filer\->new({ .... }); \& \& my @volume_names = $filer\->get_volume_names; \& \& my @volumes = $filer\->get_volumes; \& \& my $volume = $filer\->get_volume( \*(Aqvolname\*(Aq ); .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" This class encapsulates a single NetApp filer volume, and provides methods for querying information about the volume and it's sub-objects (eg. qtrees), as well as methods for managing the volume itself. .SH "INSTANCE METHODS" .IX Header "INSTANCE METHODS" .SS "get_filer" .IX Subsection "get_filer" Returns the NetApp::Filer object representing the filer on which the aggregate exists. .SS "get_name" .IX Subsection "get_name" Returns the name of the volume as a string. .SS "get_states, get_statuses, get_options" .IX Subsection "get_states, get_statuses, get_options" Each of these methods returns a list of strings, each of which represents a single state, status, or option for the volume. .PP .Vb 3 \& NOTE: All you English grammar pluralization rules fanatics can \& give up trying to convince the author to call that one method \& get_stati. .Ve .ie n .SS "get_state( $state ), get_status( $status ), get_option( $option )" .el .SS "get_state( \f(CW$state\fP ), get_status( \f(CW$status\fP ), get_option( \f(CW$option\fP )" .IX Subsection "get_state( $state ), get_status( $status ), get_option( $option )" Each of these methods returns the value for the specified state, status or option. If that particular key wasn't present, then this method will return undef. This makes it easy to tell the difference between a key that doesn't exist, and one that has a false value. .ie n .SS "set_option( $option => $value )" .el .SS "set_option( \f(CW$option\fP => \f(CW$value\fP )" .IX Subsection "set_option( $option => $value )" This method sets a single option to the specified value. It always returns true, and raises a fatal exception if it can not set the option. .SS "get_aggregate_name" .IX Subsection "get_aggregate_name" Returns the name of the aggregate on which the volume lives. For a \&\*(L"traditonal\*(R" volume, this will be a false value. .SS "get_aggregate" .IX Subsection "get_aggregate" Returns the NetApp::Aggregate object representing the aggregate on which the volume lives. For a \*(L"traditonal\*(R" volume, this will be a false value. .SS "get_qtree_names" .IX Subsection "get_qtree_names" Returns a list of strings, each of which is the name of a qtree on the volume. .SS "get_qtrees" .IX Subsection "get_qtrees" Returns a list of NetApp::Qtree objects, each of which represents a single qtree on the volume. .ie n .SS "get_qtree( $name )" .el .SS "get_qtree( \f(CW$name\fP )" .IX Subsection "get_qtree( $name )" Returns a single NetApp::Qtree object for the specified qtree name. The name must in the form of a pathname, for example: .PP .Vb 1 \& /vol/volume_name/qtree_name .Ve .PP The qtree_name is optional if querying the object for a volume's qtree. This method simply returns nothing if the specified qtree doesn't exist on the volume. .SS "get_language" .IX Subsection "get_language" Returns a string representing the language code for the volume. .ie n .SS "set_language( $language )" .el .SS "set_language( \f(CW$language\fP )" .IX Subsection "set_language( $language )" Set the language code to the specified value. Always returns a true value, or raises a fatal exception if the language code can not be set. .SS "get_size" .IX Subsection "get_size" Returns the size of the volume as a string. .ie n .SS "set_size( $size )" .el .SS "set_size( \f(CW$size\fP )" .IX Subsection "set_size( $size )" This method sets the size of the volume to the specified value. In all cases, the \f(CW$size\fR value is of the same form accepted by the \&\fIcreate()\fR method, and the underlying \s-1ONTAP\s0 \s-1CLI\s0 command: .PP .Vb 1 \& [+|\-] k|m|g|t .Ve .SS "get_maxfiles" .IX Subsection "get_maxfiles" Returns the maxfiles value for the volume. .ie n .SS "set_maxfiles( $maxfiles )" .el .SS "set_maxfiles( \f(CW$maxfiles\fP )" .IX Subsection "set_maxfiles( $maxfiles )" Sets the maxfiles value for the volume. .SS "is_clone" .IX Subsection "is_clone" Returns true if the volume is a clone, false otherwise. .SS "get_parent_name" .IX Subsection "get_parent_name" Returns a string representing the name of the parent volume, if this volume is a clone. .SS "get_parent" .IX Subsection "get_parent" Returns a NetApp::Volume object representing the parent volume, if this volume is a clone. .SS "get_snapshot_name" .IX Subsection "get_snapshot_name" Returns a string representing the snapshot name, if the volume is a clone. .SS "get_snapshot" .IX Subsection "get_snapshot" \&\s-1NOT\s0 \s-1YET\s0 \s-1IMPLEMENTED\s0. This will return a NetApp::Snapshot object, once the \s-1API\s0 is extended to support snapshots (\s-1RSN\s0, I'm sure...) .SS "get_snapmirrors" .IX Subsection "get_snapmirrors" Returns a list of NetApp::Snapmirror objects, each of which represents a snapmirror relationship for this volume. .ie n .SS "offline( %args )" .el .SS "offline( \f(CW%args\fP )" .IX Subsection "offline( %args )" Takes the volume offline. The arguments are as follows: .PP .Vb 4 \& $volume\->offline( \& # Optional arguments \& cifsdelaytime => $cifsdelaytime, \& ); .Ve .ie n .SS "online( %args )" .el .SS "online( \f(CW%args\fP )" .IX Subsection "online( %args )" Bring the volume online. The arguments are as follows: .PP .Vb 4 \& $volume\->online( \& # Optional arguments \& force => 1, \& ); .Ve .ie n .SS "rename( %args )" .el .SS "rename( \f(CW%args\fP )" .IX Subsection "rename( %args )" Renames the volume to the specified newname. Always returns a true value, and raises a fatal exception if the name can not be changed. The arguments are as follows: .PP .Vb 4 \& $volume\->rename( \& # Required arguments \& newname => $newname, \& ); .Ve .ie n .SS "restrict( %args )" .el .SS "restrict( \f(CW%args\fP )" .IX Subsection "restrict( %args )" Puts the volume into the restricted state. The arguments are as follows: .PP .Vb 4 \& $volume\->restrict( \& # Optional arguments \& cifsdelaytime => $cifsdelaytime, \& ); .Ve .SS "Snapshot Specific Methods" .IX Subsection "Snapshot Specific Methods" \fIget_snapshots\fR .IX Subsection "get_snapshots" .PP Returns a list of NetApp::Snapshot objects for each of the snapshots of the volume. .PP \fIget_snapshot( \f(CI$name\fI )\fR .IX Subsection "get_snapshot( $name )" .PP Returns a single NetApp::Snapshot object matching the specified name, if it exists for the volume. .PP \fIcreate_snapshot( \f(CI$name\fI )\fR .IX Subsection "create_snapshot( $name )" .PP Creates a snapshot of the volume with the specified name. .PP \fIdelete_snapshot( \f(CI$name\fI )\fR .IX Subsection "delete_snapshot( $name )" .PP Deletes a snapshot of the volume with the specified name. .PP \fIget_snapshot_deltas\fR .IX Subsection "get_snapshot_deltas" .PP Returns a list of NetApp::Snapshot::Delta objects for each snapshot delta for the volume. .PP \fIget_snapshot_reserved\fR .IX Subsection "get_snapshot_reserved" .PP Returns a string representing the amount of reserved space, as a percentage. This string does \s-1NOT\s0 include the % sign. .PP \fIset_snapshot_reserved( \f(CI$percentage\fI )\fR .IX Subsection "set_snapshot_reserved( $percentage )" .PP Sets the snapshot reserved space to the specified percentage, which should also \s-1NOT\s0 include the % sign. .PP \fIget_snapshot_schedule\fR .IX Subsection "get_snapshot_schedule" .PP Returns a NetApp::Snapshot::Schedule object representing the snapshot schedule for the volume. .PP \fIset_snapshot_schedule( \f(CI%args\fI )\fR .IX Subsection "set_snapshot_schedule( %args )" .PP Sets the snapshot schedule for the volume based on the arguments passed. The argument syntax is: .PP .Vb 8 \& $volume\->set_snapshot_schedule( \& weekly => $weekly, \& daily => $daily, \& hourly => $hourly, \& hourlist => [ \& $hour1, $hour2, $hour3, .... \& ], \& ); .Ve .PP \fIenable_shapshot_autodelete\fR .IX Subsection "enable_shapshot_autodelete" .PP This method turns on snapshot autodelete for the volume. .PP \fIdisable_snapshot_autodelete\fR .IX Subsection "disable_snapshot_autodelete" .PP This method turns off snapshot autodelete for the volume. .PP \fIreset_snapshot_autodelete\fR .IX Subsection "reset_snapshot_autodelete" .PP This method resets snapshot autodelete for the volume to the filer defaults. .PP \fIset_snapshot_autodelete_option( \f(CI$name\fI => \f(CI$value\fI )\fR .IX Subsection "set_snapshot_autodelete_option( $name => $value )" .PP Sets the specified snapshot autodelete option ($name) to the specified \&\f(CW$value\fR. .PP \fIget_snapshot_autodelete_option( \f(CI$name\fI )\fR .IX Subsection "get_snapshot_autodelete_option( $name )" .PP Returns the value of the specified autodelete option ($name). Note that if the prefix is \*(L"(not specified)\*(R", then the value returned is the empty string. .SH "UNIMPLEMENTED COMMANDS" .IX Header "UNIMPLEMENTED COMMANDS" The following \s-1ONTAP\s0 vol commands are not implemented, because the same functionality and information is provided through this \s-1API\s0 via some other means. .SS "container" .IX Subsection "container" The aggregate containing the volume can be obtained using: .PP .Vb 1 \& $volume\->get_aggregate; .Ve .PP which will return the NetApp::Aggregate object for it. .SH "TO BE IMPLEMENTED" .IX Header "TO BE IMPLEMENTED" All other commands will be implemented in a future release of this \&\s-1API\s0. Commands for flexible volumes will most likely have preference over traditional volumes. .SS "autosize" .IX Subsection "autosize" It's not yet clear just how this one should be implemented, since the command does several things. It enables and disables the autosize feature, or resets it to defaults, and it also sets the maximum and incremental sizes to autosize to. .PP This could be implemented a few different ways, for example: .PP .Vb 9 \& $volume\->autosize( \& # Optional arguments \& maximum => $maximum, \& incremental => $incremental, \& # Optional, but mutually exclusive: \& on => 1, \& off => 1, \& reset => 1, \& ); .Ve .PP That seems a little clumsy, though. Perhaps a better interface would be to have methods to control the state of the feature: .PP .Vb 3 \& $volume\->enable_autosize; \& $volume\->disable_autosize; \& $volume\->reset_autosize; .Ve .PP and then methods to set/get the autosize values: .PP .Vb 5 \& $volume_set_autosize( \& # Required but mutually exclusive options \& maximum => $maximum, \& incremental => $incremental, \& ); \& \& $volume\->get_autosize; .Ve