Search for Disabled Users and Move to Disabled Ou using PowerShell
| | | | | |

Search for Disabled Users and Move to Disabled Ou using PowerShell

Search for Disabled Users and Move to Disabled Ou using PowerShell Created this script to search a ‘OU’ for disabled users and move them to a different ou . I have added the ‘WhatIf’ option by default . Once you run the script it will prompt for ‘Search OU’ and ‘Target OU’ . #Created to ease…

Bulk add users to Distribution Group
| | | | | | | | |

Bulk add users to Distribution Group

Bulk add users to Distribution Group I was ask recently to simplify a task for support staff to bulk add users to a distribution group. So i created the following script to add user from csv. The script will ‘prompt’ for ‘Distribution Group’ name and will add users accordingly. The script has the ‘WhatIf’ added…

Bulk export Mailbox to .PST using PowerShell
| | |

Bulk export Mailbox to .PST using PowerShell

Bulk export Mailbox to .PST using PowerShell I recently received a request to bulk export mailboxes to .pst , to help mysef i have created this small script to import from csv and then kick off the export request. file can be downloaded Here Code: #Created By: Shaun Hardneck #http://thatlazyadmin.com #Freebies 🙂 Add-PSSnapin Microsoft.Exchange.Management.PowerShell.SnapIn; Import-Csv…

Set UPN Suffix using PowerShell
| | | | | | |

Set UPN Suffix using PowerShell

To Prepare for Office 365 Migration you need to add the missing ‘UPN Suffixes’. The following example demonstrates how to create a new UPN suffix for the users in the ThatLazyAdmin forest: Lets Start by running: Import-Module ActiveDirectory   Then run : Get-AdForest | Set-ADForest -UPNSuffixes @{Add=”ThatLazyAdmin.com”}   Lets verify the new UPN in Active Directory…

Set Exhange 2010 /2013 OWA ‘LogonFormat’ using PowerShell
| | | | | |

Set Exhange 2010 /2013 OWA ‘LogonFormat’ using PowerShell

Set Exhange 2010 /2013 OWA ‘LogonFormat’ using PowerShell   Quick look at the curent setting using the ‘GUI’. Exchange Admin Center – Servers – Virtual Directory select OWA virtual directory.     Now lets change the LogonFormat to ‘User name only’ using PowerShell   Set-OwaVirtualDirectory -LogonFormat ‘UserName’ -DefaultDomain ‘ThatLazyAdmin.local’ -Identity ‘LazyEX-01\owa (Default Web Site)’  …

Get all Failed Move-Requests (Exchange 2013)
| | | |

Get all Failed Move-Requests (Exchange 2013)

To quickly get all ‘Failed Move-Requests’ you can run the following one liner. Get-MoveRequest | Where-Object {$_.Status -eq “failed”} To Remove all ‘Failed Move-Requests’ you can run the following:   Get-MoveRequest | Where-Object {$_.Status -eq “failed”} | Remove-MoveRequest   #ThatLazyAdmin    

Express installation of Azure AD Connect
| | | | | |

Express installation of Azure AD Connect

Express installation of Azure AD Connect Tool Can be downloaded from Here Sign in as a local administrator to the server you wish to install Azure AD Connect on. You should do this on the server you wish to be the sync server. Navigate to and double-click AzureADConnect.msi. On the Welcome screen, select the box agreeing…

Installing Exchange 2016
| | | | |

Installing Exchange 2016

Windows Server 2012 and Windows Server 2012 R2 prerequisites The prerequisites that are needed to install Exchange 2016 on computers running Windows Server 2012 or Windows Server 2012 R2 depends on which Exchange role you want to install. Read the section below that matches the role you want to install. Role: Mailbox server role. Let’s…

Enable Remote Desktop Using PowerShell
| | | |

Enable Remote Desktop Using PowerShell

Enable Remote Desktop Using PowerShell Open an elevated Windows PowerShell session and run the following commands. This first one creates the fDenyTSConnections value and sets it to 0 (off). This makes sense, because we don’t want to deny Terminal Services (TS) connections. Set-ItemProperty -Path ‘HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server’ -Name fDenyTSConnections -Value 0 Set Network Level Authentication for…

Exchange 2010 Mail User still Associated with a Move Request
| | | | | |

Exchange 2010 Mail User still Associated with a Move Request

Exchange 2010 Mail User still Associated with a Move Request Mail User Object in Exchange still showing as if it is listed to a Move Request To verify if we have any Move requests currently in progress or completed we can start by Opening the Exchange Shell. Once the EMS is open type the following…

Exchange 2010 MessageTrackingLog:  Failed to write log..Error Access Denied
| | | | | |

Exchange 2010 MessageTrackingLog: Failed to write log..Error Access Denied

Exchange 2010 MessageTrackingLog: Error Access Denied Message Tracking in Exchange 2010 Stopped and you received the following Error in EventViewer. “MessageTrackingLogs: Failed to write logs because of the error: Access to the path ‘MSGTRK20170329-8.LOG’ is denied..” Let’s Start by reviewing the Current configuration for Message Tracking. Get-TranSportServer |ft Name,MessageTrackingLogEnabled,MessageTrackingLogPath,MessageTrackingLogMaxAge,MessageTrackingLogMaxDirectorySize, MessageTrackingLogMaxFileSize,MessageTrackingLogSubjectLoggingEnabled Now that you have your…

Exchange Deployment Assistant Quick Overview
| | | | | | | | |

Exchange Deployment Assistant Quick Overview

Exchange Deployment Assistant Quick Overview Exchange deployment tool creates a custom step by step checklist to help you deploy Exchange in different types of scenarios. The tool can be found Here. Click on Launch the Deployment Assistant. From the next screen you will have 3 different options to choose from On-Premises ,Hybrid ,Cloud Only. Details…