Azure Stack and Monitoring Virtual Disk Health and Storage Jobs Using the Privileged Endpoint.

This last week I had been asked about being able to see the health of the storage on the Azure Stack multi-nodes systems that we will manage.  I have built a good number of Storage Spaces Direct clusters and know how important it is to see the health of the virtual disks, the storage subsystem, and also to see what storage jobs are running.  The same goes with Azure Stack since the underlying storage infrastructure is Storage Spaces Direct (S2D).   Now, those familiar with Azure Stack know that we do not have the ability to access the internal infrastructure.  Microsoft has provided an API we could use to monitor the Azure Stack infrastructure and they also have provided the Privileged Endpoint (PEP).  The PEP is locked with PowerShell JEA (Just Enough Administration).  Which means that those Azure Stack Operators only have about 48 PowerShell cmdlets available to them.

When you log on to the PEP, two of those available cmdlets are Get-VirutalDisk and Get-StorageJob.  These two cmdlets can help with monitoring the health of the underlying virtual disk and any storage jobs running. So how do you run these commands in an environment that is using JEA to view the status of storage that is in a locked down environment?

https://docs.microsoft.com/en-us/azure/azure-stack/azure-stack-privileged-endpoint

The answer is pretty easy but I will be honest, it took me an hour of trying to do it my way until I finally Binged a solution that worked in seconds  First, remember that the Microsoft Documentation provided by the Microsoft Docs team is very well done.  Always go there first and look, it would have saved me about an hour of my day.

NOTE:  This can be done in the ASDK (Azure Stack Development Toolkit) as well.  In fact, I highly recommend you use the PEP in the ASDK as well.

First, you will need to make a remote connection to one of your PEP’s in your Stack.  The rest of this blog I have basically taken from Microsoft Documentation online.  Once again, this is a great resource for everything Azure Stack.  This is something that can be done with a host is rebooted, during updates, when a disk is replaced, etc.

https://docs.microsoft.com/en-us/azure/azure-stack/azure-stack-replace-disk#check-the-status-of-virtual-disk-repair

1.  Open a PowerShell session and connect to one of the 3 privileged endpoints in your Stack.  If you are doing this in your ASDK there is only one PEP.  You should have the IP addresses and the hostnames in the JSON file your OEM provided. A majority of the time the names would be AzS-ERCS01, 02, and 03.  Depending on what prefix you gave your OEM to use for the infrastructure VM’s.

To get the health of the virtual disk run the following command:

Get-VirtualDisk –CimSession s-cluster

To get the storage jobs run the following command:

Get-VirtualDisk –CimSession s-cluster | Get-StorageJob

Tagged with: , , , ,
Posted in Azure Stack

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Follow Kristopher Jon Turner on WordPress.com
Categories
Archives
Follow me on Twitter
%d bloggers like this: