Quantcast
Channel: THWACK: Popular Discussions - Orion SDK
Viewing all articles
Browse latest Browse all 3719

Orion SDK, Add network interface and Volumes

$
0
0

Hi,

First of all, thanks for the great SDK you provide :d). I'm using the powershell api, and it works fine.

I have several questions about how to add network interface and volumes for monitoring.

My problem is how to find the network interface index and name, and how to find the volumes index and caption; Is there a way to collect them using API as in the web interface when we click on List Resources?

My second question is about when I had a volume (I get the index and the name manually) and I'm using the API (following code), i have an error on Volume Polling Details : The "Volume Polling Details " resource threw an exception..
Specified cast is not valid.

 

powershell Code:

$newVolProps = @{
 NodeID=$nodeProps["NodeID"]; # NodeID on which the interface is working on
 VolumeIndex=[int]$VolumeIndex;
 Status=0;
 Type ="Fixed Disk";
 Icon ="FixedDisk.gif";
 Caption=$VolumeCaption;
 VolumeDescription=$VolumeDescription;

 }
 $newVolUri = New-SwisObject $swis –EntityType "Orion.Volumes" –Properties $newVolProps
 $VolProps = Get-SwisObject $swis -Uri $newVolUri
 # register specific pollers for the node
 # Disk Poller
 
 $poller = @{
 PollerType="Poller_VO";
 NetObject="V:"+$VolProps["VolumeID"]
 }
 $pollerUri = New-SwisObject $swis -EntityType "Orion.Pollers" -Properties $poller

 

thanks for your help


Viewing all articles
Browse latest Browse all 3719

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>