de-DEen-GB
 
rss

Just can't get enough of IT

This blog is about mostly anything in IT. But the primary focuses are Microsoft Technologies like Exchange, Office 365, Azure and Cloud Security.

Exchange Server 2013Exchange Server 2016Description

This scripts helps to suspend all messages in an Exchange transport queue and to export all suspended messages to a given target folder.

The script uses the AssembleMessage cmdlet to properly export queued messages as .eml files.

Optionally, all exported messages can be removed from the transport queue. 

Note

This script requires the GlobalFunctions module for logging.

Examples

# EXAMPLE 1
# Export messages from queue MCMEP01\45534 to D:\ExportedMessages and do not delete messages after export
.\Export-MessageQueue -Queue MCMEP01\45534 -Path D:\ExportedMessages

# EXAMPLE 2
# Export messages from queue MCMEP01\45534 to D:\ExportedMessages and delete messages after export
.\Export-MessageQueue -Queue MCMEP01\45534 -Path D:\ExportedMessages -DeleteAfterExport

Version History

  • 1.0, Initial community release
  • 1.1, Some PowerShell hygiene 

 

As always: Test and familiarize yourself with the script in a test or development environment.

Links

Follow

 

Read More »
Last updated: 2016-11-28

Description

The script sends a given number of test email to a configured SMTP host for test purposes (primarily Exchange queues, transport agents or anti-virus engines).

Do not forget to adjust script variables to suit your local Exchange infrastructure.

Examples

# EXAMPLE 1
# Send 10 normal emails
.\Send-TestMail.ps1 -Normal -MessageCount 10

# EXAMPLE 2
# Send an Eicar test email
.\Send-TestMail.ps1 -Eicar

Version History

  • 1.0, Initial community release

Links

Follow

 

Read More »

Description

Add remote IP address ranges to an Exchange Server 2013 receive connctor.

Create a new text file containing the new remote IP address ranges

Example:

192.168.1.1
192.168.2.10-192.168.2.20
192.168.3.0/24

The script creates a new sub folder named ReceiveConnectorIpAddresses and saves the currently configured remote IP address ranges first.

While adding the new remote IP address ranges, the script checks, if the new ranges already exist.

Examples

# Add IP addresses from ip.txt to MYCONNECTOR

.\Add-ReceiveConnectorIpAddress.ps1 -ConnectorName MYCONNECTOR -FileName D:\Scripts\ip.txt

.\Add-ReceiveConnectorIpAddress.ps1 -ConnectorName REMOTECONNECTOR -FileName .\ip-new.txt -ViewEntireForest $true

Version History

  • 1.0, Initial community release

Links

Follow

Read More »