You all definitely helped! Thx agn. I want my end result to look like b/c all I need is one hdisk string b/c they are all different logical paths to the same LUN. I don't need the 'state=enabled' part and tried using (split)[0] but failed.
Once I have this I will then integrate another system command (or a 2nd hash value) on the value hdisk368 for example to get its serial number.
END_RESULT
$VAR1 = {
'SAN_VC0_42' => {
'hdisk368' => 'state=enabled',
}
};
I was playing with, but was side-tracked.
print ((<DATA>)[-1]);
__DATA__
Device: SAN_VC0_42
devicetag: SAN_VC0_42
type: auto
info: format=none
flags: online ready private autoconfig invalid
pubpaths: block=/dev/vx/dmp/SAN_VC0_42 char=/dev/vx/rdmp/SAN_VC0_42
Multipathing information:
numpaths: 8
hdisk35 state=enabled
hdisk100 state=enabled
hdisk303 state=enabled
hdisk368 state=enabled
hdisk571 state=enabled
hdisk636 state=enabled
hdisk839 state=enabled
hdisk904 state=enabled
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.