Azure Windows 

Powershell: How to connect to Microsoft Cloud Services like Az, AzureAD, Exchange, Teams

When I was working with Microsoft Azure Services, I started listing important commands which can be handy using PowerShell, so here I am publishing in my blog article below. Prerequisites before starting: Tools needed: Run the below commands in PowerShell to install the tool. Az: Install-Module Az -Force -AllowClobber AzureAD: Install-Module AzureAD -Force -AllowClobber ExchangeOnlineManagement: Install-Module ExchangeOnlineManagement -Force -AllowClobber Microsoft Teams: Install-Module MSTeams -Force -AllowClobber step #1: Before proceeding further Check weather required modules are installed using below command: Step #2: Store account credentials in a variable Below are the…

Read More
MS SQL Server Windows Server 

Powershell script to check SQL service status and send email

In windows server we can create a PowerShell script to trigger an email on the basis of SQL service status. Solution Below The solution for checking the status of SQL Server service can be achieved by using the “Get-Service” cmdlet. In the below example we are using some common naming conventions of SQL server like MSSQL$, MSSQLSERVER, and SQL Server, etc. below code is to get the server status. Note: please check your SQL server name and replace them “MSSQLSERVER” in below code To send email we will use some…

Read More