Need to retreive LUN as well as RDM info per vcenter…

Welcome Forums General PowerShell Q&A Need to retreive LUN as well as RDM info per vcenter…

Viewing 1 reply thread
  • Author
    Posts
    • #260277
      Participant
      Topics: 4
      Replies: 3
      Points: 43
      Rank: Member

      Hi all,

      I know this is old hat stuff as I saw an earlier blog which revolved around what I am trying to achieve here

      So, I am trying to retrieve all RDM perennially reserved values per host per vcenter server

      I think I have managed to make the script work in regards to it pulling the RawPhysical and RawVirtual disktype per vm and grab the unique values of these and then export these values to a .csv file

      I have been asked however if I can also retrieve the LUN of each RDM, I have looked into how to get the LUN value however cannot see how I can place that within my current script

      basically as well as the raw naa ref ID I also would like the LUNid decimal value stored in vcenter

      I think the command to do this is something along the lines below,

      get-scsilun -vmhost *.vmhost -canonicalname *.hddisplayname

      *.runtimename.substring(*.runtimename.lastindexof(“L”)+1)

       

      This I borrowed from a previous article:

      https://communities.vmware.com/thread/514090

      Many thanks in advance!

    • #260367
      Senior Moderator
      Topics: 9
      Replies: 1373
      Points: 5,061
      Helping Hand
      Rank: Community MVP

      *.runtimename.substring(*.runtimename.lastindexof(ā€œLā€)+1)

      What does this line do ?

Viewing 1 reply thread
  • You must be logged in to reply to this topic.