You are here: Windows OS Hub » Powershell

Archive for the 'Powershell' Category

Hyper-V PowerShell Direct in Windows Server 2016

Posted on January 19th, 2017 · Posted in Powershell, Windows Server 2016
Managing Hyper-V 2016 VMs using PowerShell Direct

PowerShell Direct is a new PowerShell feature in Windows Server 2016 and Windows 10 that allows to create a direct local PowerShell session with any virtual machine run on a Hyper-V host, meanwhile the connection is established not via the network, but  through the internal VM bus. Thus, a Hyper-V.. read more

Checking TCP Port Response Using PowerShell

Posted on December 2nd, 2016 · Posted in Powershell
Test-NetConnection check remote tcp port

From time to time, any administrator has to check service availability on a remote server  by testing remote TCP port response. Meanwhile, everybody got used to doing it quickly using telnet command. For example, to make sure the SMTP service is response on a mail server (by default, it responds.. read more

How to Import User Photo to Active Directory Using PowerShell

Posted on November 18th, 2016 · Posted in Active Directory, Powershell
import user photo to ad

Among user attributes starting from the version of Active Directory schema in Windows Server 2000, there is a special attribute thumbnailPhoto, in which a user photo (or any other images) can be stored as binary data. Outlook since 2010, Lync, SharePoint (and other applications) can use the data contained in.. read more

Auditing Users Password Strength in AD

Posted on October 5th, 2016 · Posted in Active Directory, Powershell
Active Directory Password Quality Report

The complexity of a user password in Active Directory domain is one of the key security elements both for user data, and the entire domain. As a rule, users prefer to use weak, easy-to-remember passwords. Thus, they significantly reduce the level of protection against hackers for their accounts. In this.. read more

Tracking Files Deletion using Audit Policy and MSSQL

Posted on August 31st, 2016 · Posted in Powershell, Windows Server 2012 R2
select file deletion event from mysql db

Any Windows administrator has come across the situation when angry users want to know who has deleted a very important file of the annual report from the share on the file server. This information can be obtained only if you have enabled the audit of the deleted files and folders.. read more

Run MySQL Queries from PowerShell

Posted on August 22nd, 2016 · Posted in Powershell
posh: select query from mysql

One of the useful PowerShell features is the opportunity to connect to databases on remote servers, including MySQL ones. Thus, you can address MySQL tables to access data directly from PowerShell console. In this article, we’ll deal with the examples of connection to MySQL DB from PowerShell script and some.. read more

Generating Random Password with PowerShell

Posted on August 11th, 2016 · Posted in Powershell
PoSh Script to Generate Random password

It is not easy to think a secure password, so that it meet certain requirements to the length and complexity. There are many programs and online services in the Internet to generate passwords, but why using third-party programs if you can do with the tools that already exist in your system… read more

How to Measure Disk IOPS Using PowerShell

Posted on June 15th, 2016 · Posted in Powershell, Windows Server 2012 R2
test iops

One of the main metrics, which allows to estimate the performance of the existing or developed storage system is IOPS (Input/Output Operations Per Second). In simple terms, IOPS is the number of blocks read from or written to a media or a file system in a time unit. The larger.. read more

How To Create Self-Signed Certificate with PowerShell

Posted on April 8th, 2016 · Posted in Powershell, Windows 10
New-SelfSignedCertificate cmdlet

Most Windows administrators who are familiar with PKI know about the utility MakeCert.exe , which allows to create a self-signed certificate. This tool is included in Microsoft .NET Framework SDK and Microsoft Windows SDK. In Windows 8 and Windows Server 2012, a self-signed certificate can be created using PowerShell 3.0 or.. read more

PSReadLine – useful Powershell module

Posted on April 6th, 2016 · Posted in Powershell
powershell auto suggestion

In Windows 10 PowerShell has got a lot of new features, some of which are offered by PSReadLine module. PSReadLine is a third-party PowerShell module that allows to expand PowerShell command line experience. This module makes using the console easier and more comfortable.