Windows PowerShellComments (0)

Windows PowerShell® is a task-based command-line shell and scripting language designed especially for system administration. Built on the .NET Framework, Windows PowerShell helps IT professionals and power users control and automate the administration of the Windows operating system and applications that run on Windows.

Windows PowerShell commands, called cmdlets, let you manage the computers from the command line. Windows PowerShell providers let you access data stores, such as the registry and certificate store, as easily as you access the file system. In addition, Windows PowerShell has a rich expression parser and a fully developed scripting language.

Windows PowerShell includes the following features:

  • Cmdlets for performing common system administration tasks, such as managing the registry, services, processes, and event logs, and using Windows Management Instrumentation (WMI).

  • A task-based scripting language and support for existing scripts and command-line tools.

  • Consistent design. Because cmdlets and system data stores use common syntax and naming conventions, data can be shared easily and the output from one cmdlet can be used as the input to another cmdlet without reformatting or manipulation.

  • Simplified, command-based navigation of the operating system, which lets users navigate the registry and other data stores by using the same techniques that they use to navigate the file system.

  • Powerful object manipulation capabilities. Objects can be directly manipulated or sent to other tools or databases.

  • Extensible interface. Independent software vendors and enterprise developers can build custom tools and utilities to administer their software.


You need sign in to comment! Sign up today!

Bulk create Active Directory usersComments (0)

This is an example of how to create multiple users using a csv file:

Create a csv file like contact.csv

Name, lias
Jack Bauer, jbauer
Alex Westwood, awestwood
Ken Smith, ksmith

Run the following cmdlet to execute the creation of users:
Import-csv contact.csv | foreach {Get-MailContact - Identity $_.Name | Set-MailContact -Alias $_.Alias}


You need sign in to comment! Sign up today!

List inactive users in Active DirectoryComments (0)

To find users who have not logged in for 90 days:
Get-Aduser -Filter * -Properties LastLogonDate | Where-Object {$_.Enabled -eq "True"-And $_.LastLogonDate -lt (Get-Date).Adddays(-90)}

To find the users and disable the accounts:
Get-Aduser -Filter * -Properties LastLogonDate | Where-Object {$_.Enabled -eq "True"-And $_.LastLogonDate -lt (Get-Date).Adddays(-90)} | Set-Aduser -Enabled $False


You need sign in to comment! Sign up today!