Category Archives: Powershell

Powershell Workflow for Runbooks, Inline Script

Powershell workflow is the best way to program parallel processing using Powershell and/or in Azure run books. Though the syntax is similar, there are few differences you need to be aware of. Start with below link when you create your … Continue reading

Posted in Azure, Powershell, Uncategorized | Tagged , , , , , , | Leave a comment

DBATools.IO – Powershell for SQL DBAs

DBATools.IO was one of the best things I started using in 2017 and I wanted to master this in 2018! https://dbatools.io/functions/ includes the list of all commands in dbatools module! Start using it if you have not started already.

Posted in Powershell, SQL, Uncategorized | Tagged , , | Leave a comment

Frequently used Azure powershell commands

Few of my frequently used powershell commands on Azure Ref: https://docs.microsoft.com/en-us/azure/search/search-manage-powershell

Posted in Azure, Powershell, Uncategorized | Tagged , , , | Leave a comment

Most common challenges and solution with Availability group listener and multisubnetfailover

Industry started using SQL availability groups on most of their environments, DBA is coming across multiple issues related to AGListener connectivity. This blog explains 2 major challenges and solutions in detail: https://blogs.msdn.microsoft.com/alwaysonpro/2014/06/03/connection-timeouts-in-multi-subnet-availability-group/ I recommend option-1 to enable client to use … Continue reading

Posted in Learn_Powershell, SQL, SQL Server, Uncategorized | Tagged , , , , , | Leave a comment

Azure Scripting errors after upgrading Powershell to V4 – Select-AzureRmProfile / Save-AzureRmProfile

After upgrading Powershell to V4, few of my scripts started failing. Few updated commandlets are missing backward compatibility, Select-AzureRmProfile/ Save-AzureRmProfile are couple of the broken commandlets. You can replace them with Import-AzureRmContext, and Save-AzureRmContext. Code block I use for reference: … Continue reading

Posted in Azure, Powershell, SQL Server, Uncategorized | Tagged , , , , , | Leave a comment

Powershell commands – my quick reference

Posted in Learn_Powershell, Powershell, Productivity, Uncategorized | Tagged | Leave a comment

Windows Server storage capacity and usage report using Powershell

Below Scrip generates list of all Drives and mount points configured, thery storage capacity and free space. Following Script to check the storage on a single server; If you want to calculate the storage to be added to maintain certain … Continue reading

Posted in Powershell, Productivity, Uncategorized, Windows Server | Tagged , , , , | Leave a comment