Archive for category V2
Quick modification of the Compare-Command.ps1 script
Posted by Karl Mitschke in Uncategorized, V2, V3 on August 8, 2012
I found a few issues with my Compare-Command script, and have resolved them. If you have already downloaded it from TechNet, thanks, and you can just modify the following two lines: Line 72 becomes:$V3Detailed |select -ExpandProperty Parameters |ForEach-Object -Process {$V3Paramaters += (“$($_.Name)=$($_.ParameterType.name)=$($V3ModuleName[0])“)} Line 82, likewise, becomes:$V2Detailed |select -ExpandProperty Parameters |ForEach-Object -Process {$V2Paramaters += (“$($_.Name)=$($_.ParameterType.Split(“.”)[-1])=$($V2ModuleName[0]))”)} While […]
Quickly compare PowerShell V2 and V3 cmdlets
Posted by Karl Mitschke in V2, V3 on August 7, 2012
Recently, I was looking for the difference between the Get-ChildItem cmdlet in Version 2 and Version 3 of Windows PowerShell. Although you can Bing “PowerShell Get-ChildItem v3” and get an accurate listing of the new parameters from TechNet, that’s not true for all cmdlets, so I wrote a quick little script to find the information. […]
PowerShell WMI Gather DNS settings for all Servers
Posted by Karl Mitschke in PowerShell, V2, WMI on December 23, 2011
A question came up on TechNet: “I am new to PowerShell and need a wmi script to query all the servers on my network for there dns settings and dump it out to a text file. Would someone be able to help me get started?” This was a fairly long script, so I decided to […]
PowerShell rename a mailbox folder using Exchange Web Services API
Posted by Karl Mitschke in EWS, Exchange, V2 on October 14, 2010
A question came up on the Exchange Server Forum on powershellcommunity.org: ‘Is it possible to use PowerShell with a COM access to connect to a remote outlook mailbox and change the name of a folder, especially a custom folder not a system folder like inbox,sent items,contact…etc? I have a project where I need to change […]
PowerShell EWS Managed API Get Calendar Booked Time
Posted by Karl Mitschke in 2007, 2010, EWS, V2 on September 14, 2010
As part of our Full-Cost Maturity Model (FMM), my management chain took the number of employees and created a SWAG of our billable time – they then took these billable hours, and in my case divided them by the number of mailboxes in our organization. – That’s how much it costs for 1 Exchange Administrator […]
PowerShell Search AD by GUID
Posted by Karl Mitschke in PowerShell, V2 on July 1, 2010
A question was posted on http://social.technet.microsoft.com/Forums/en/ITCG/thread/728c6aed-a3ef-4b6f-b5bc-28024251d5eb “I have GUID’s from event log’s and such that I need to be able to take and convert to a human readable name” PowerShell can do this with the RSAT tools or the Quest AD cmdlets have this functionality built in, but I like doing things the hard way. […]
Exchange 2007 / 2010 Database Reporting Script
Posted by Karl Mitschke in 2007, 2010, Exchange, V2 on June 6, 2010
In a previous post (https://unlockpowershell.wordpress.com/2010/01/27/exchange-2007-mailbox-database-reporting-script/) I provided a script that we use to report on Our Exchange 2007 mailbox servers. That post garnered a lot of comments because it didn’t work with mount points. We now have a mix of Exchange 2007 and 2010, and I have updated my script – We also now use […]
Exchange 2010 Find Database White Space
Posted by Karl Mitschke in 2010, V2 on June 3, 2010
In Exchange 2007 and earlier, after online defragmentation occurred, you could find your database whitespace by examining the application logs and viewing event ID 1221. This is a pain to do, but luckily for us, Shay Levy posted an excellent article with a PowerShell function for Exchange 2007: http://blogs.microsoft.co.il/blogs/scriptfanatic/archive/2009/08/13/exchange-white-space.aspx That works great for 2007, but […]
PowerShell find all Server 2008 boxes in a domain
Posted by Karl Mitschke in PowerShell, V1, V2 on March 30, 2010
This script will find all Server 2008 (and Server 2008 R2) machines on your domain: 001 002 003 004 005 006 007 008 009 010 011 012 013 $objDomain = [ADSI]” $objSearcher = New-Object System.DirectoryServices.DirectorySearcher $objSearcher.SearchRoot = $objDomain $objSearcher.Filter = "(&(objectCategory=computer)(operatingsystem=*Server 2008*))" $objSearcher.PageSize = 1000 $colProplist = "*" foreach ($i in $colPropList){$objSearcher.PropertiesToLoad.Add($i)} $colResults = $objSearcher.FindAll() $Server2008 = @() foreach ($objResult in $colResults) { $Server2008 += $objResult.Properties.name } You can change the operatingsystem= line to gather the OS you are interested […]
Exchange 2007 Mailbox Database Reporting Script
Posted by Karl Mitschke in 2007, Exchange, PowerShell, V2 on January 27, 2010
We use the following script to report on Exchange 2007 Mailbox Database usage. I will be modifying it for 2010 soon – watch this space 🙂 001 002 003 004 005 006 007 008 009 010 011 012 013 014 015 016 017 018 019 020 021 022 023 024 025 026 027 028 […]