certificate

PowerShell Tip of the Week: Get certificate remotely

Get certificate details from remote machines. In this post I wanted to share simple script which check certificates expiration date. Get certificate details To get certificates details we can use Get-ChildItem command and provide cert path Cert:\LocalMachine\My. In this example I was looking for certificates which subject contains my computer name: As you can see above we get Thumbprint and Subject properties as default. In this case expiration date is …

Event ID's

PowerShell Tip of the Week: Query multiple event ID’s remotely

In my daily work I often need to look for specific event ID’s on all computers. As my environmnet contains mostly server core machines I always use PowerShell script for checking that. Multiple event ID’s Get-WinEvent cmdlet gets events from event logs, including classic logs, such as the System and Application logs, and the event logs that are generated by the Windows Event Log technology.  It also allows you to …

Test multiple ports on remote servers using PowerShell script

Some time ago I added articles about testing connection on several ports. In one of them I was explaining how to format PortQry results and other was about PowerShell function. This time I wanted to speed up things a little bit 🙂 Testing connection We can test connection in several ways. In this case I wanted to make a test on lots of remote machines in fast way. In this …

Remove function from Azure Function

In todays article I want to share with you script for remove function from Azure function. I was looking for some ready Powershell command for removing function, but AzureRM module is very limited in this area. The only thing which I found was information that most of operation on Azure function is available via API (however is still very limited). You can find Kudu documentation on https://github.com/projectkudu/kudu/wiki/REST-API. How script works? …

Get Azure logs using PowerShell script

Today I wanted to show you one of the method for getting Azure logs. In this case I was looking for information about start and stop action. Azure logs To connect to Azure resources and be able to check logs you need few things: Azure Credentials Environment TenantID Subscription Resource Group Name Below you can find example for converting your password to secure string and adding it with account ID …

PowerShell Tip of the Week: SQL Server Native Client version

Recently I had to extract SQL Server Native Client version from all of my SQL machines. I would like to share simple script for extracting that information remotely from registry. SQL Server Native Client To find version using PowerShell we need to know where is it located. Easiest way for me was extracting this from registry: SQL Server 2008/2008 R2:– HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\SQLNCLI10\CurrentVersion SQL Server 2012/2016:– HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\SQLNCLI11\CurrentVersion You …