Remote Desktop Connection Manager, or RDC Man, is a wonderful piece of software that I’ve been using for the past eight years. RDC Man is one of those applications, like Outlook, that I open almost every single day and although not directly applicable to EOP or Exchange Online, it is applicable to most operations type folks and so I wanted to share it here. One example, this could be used to manage remote connections to all the servers in your on-premises Exchange environment.
RDC Man is a single application to manage your remote desktop connections all in a single view. Servers are organized into named groups and you can connect or disconnect to all servers in a group with a single command. Servers can inherit their logon settings from a parent group or a credential store. Thus when you change your lab account password, you only need to change the password stored by RDCMan in one place. Personally I use RDC Man to manage my Azure virtual machines, my local Exchange labs, and the servers that I run in my basement at home.
My current setup of Remote Desktop Connection Manager
RDC Man was an internal Microsoft tool for a long time and was first released publically a couple of years ago. The recently published version (published three weeks ago) brings the tool up from version 2.2 to version 2.7. If you have never used this tool before and use RDP, I would highly recommend you take a look.
Download Remote Desktop Connection Manager 2.7 at the Microsoft Download Center.
New features• Virtual machine connect-to-console support • Client size options come from the application config file (RDCMan.exe.config) rather than being hard-coded. • View.Client size.Custom menu item shows the current size • View.Client size => From remote desktop size • Option to hide the main menu until Alt is pressed. Hover over the window title also shows the menu. • Added Smart groups • Support for credential encryption with certificates • Better handling of read-only files • Added recently used servers virtual group • New implementation of thumbnail view for more predictable navigation • Thumbnail view remembers scroll position when changing groups, etc. • Performance improvements when loading large files • Allow scale-to-fit for docked servers (Display Settings.Scale docked remote desktop to fit window) • Allow scale-to-fit for undocked servers (Display Settings.Scale undocked remote desktop to fit window) • "Source" for inheritance in properties dialog is now a button to open the properties for the source node. • Focus release pop up => changed to buttons, added minimize option. • Added command-line "/noconnect" option to disable startup “reconnect servers” dialog • Session menu items to send keys to the remote session, e.g. Ctrl+Alt+Del • Session menu items to send actions to the remote session, e.g. display charms • Domain="[display]" means use the display name for the domain name.
Bugs fixed• Application is now DPI aware • Undocking a server not visible in the client panel resulted in the client not being shown in undocked form. • Ctrl+S shortcut didn’t work at all. It now works and always saves, even if there are no detected changes to the file. • Shortcut keys didn’t work when focus was on a thumbnail. • Add/delete profile in management tab. In same dialog instance, profiles are not updated. Similarly adding a new profile from combo doesn’t update the tab. • Window title was not updated when selected node is removed and no new node selected (open a file, close the file.) • Connect via keyboard didn’t always give focus when it should. • Connected Group would always show itself upon connecting to a machine, regardless of setting. • Selecting a built-in group then hiding via menu option didn’t work properly. • Editing server/group properties did not always mark a file as changed. • Non-changes could result in save prompts at exit. This should no longer happen. • Activating the context menu via the keyboard button was not always operating on the correct node. • Changing a server/group name doesn’t change window title if the server/group is currently selected. • ALT+PAGEUP and ALT+PAGEDOWN hotkeys were switched. This is fixed for new installs—for existing files you’ll want to change on the [Tools.Options.Hot Keys] tab. • /reset command line option wasn’t resetting all preferences • “Server Tree” option from “Select server” focus release dialog didn’t show the server tree if it was hidden. • New file directory now defaults to “Documents”. • ListSessions dialog sometimes popped up in a weird location. Now placed within the main window.
Update, Dec 11/14: Exchange Server 2010 SP3 Update Rollup 8 has been temporarily pulled due to a problem.
Update, Dec 15/14: Exchange Server 2010 SP3 Update Rollup 8 v2 has been posted
While I mainly target Exchange Online Protection with this blog, a lot of customers use EOP to protect on-premises Exchange environments. As such I wanted to touch on the Exchange updates that were released today which cover Exchange Server 2007 SP3, Exchange Server 2010 SP3, Exchange Server 2013, and UM Language Packs.
Today the Exchange team announced the availability of the following updates.
Exchange Server 2013 Cumulative Update 7 (Version 15.00.1044.025) UM Language Packs for Cumulative Update 7 (Version 15.00.1044.025) Exchange Server 2010 SP3 Update Rollup 8 (Version 14.03.0224.002) - Version 2 Exchange Server 2007 SP3 Update Rollup 15 (Version 08.03.0389.002)
Also available today, MS14-074, which contains security updates for Exchange Server 2007 SP3, Exchange Server 2010 SP3, Exchange Server 2013 SP1 and Exchange Server 2013 CU 6.
For complete details, please see the notes on the above download links as well as the announcement posting over on the Exchange Team Blog.
From my experience, a very small number of people actually choose PowerShell over the GUI (Graphical User Interface, ie. The Office 365 Portal). But once you get a grasp of PowerShell and write some scripts, you’ll see the light and going back to your old ways will be very hard. PowerShell has two big advantages. First, once you are proficient you’ll be able to pull and modify data much faster with PowerShell than going into the portal. Second, most managers aren’t PowerShell experts, so when you are working and have your PowerShell window open they will be extra impressed with you! Don’t worry, you can thank me later.
In this article I’m going to focus on using PowerShell to obtain message trace results within the past seven days. For messages older than seven days we need to run an extended message trace, or Start-HistoricalSearch.
Let’s start by running a typical message trace in EOP which returns all results for the past 48 hours.
In this view we can sort based on the columns presented to us and can double click for additional information. Now let’s look at how PowerShell can improve upon this experience.
You’ll see below that I’m going to be piping my results to Out-GridView. If you have not used this cmdlet before, it essentially will launch a new interactive window where you can view the results. Let’s take a look.
The following script will return the message trace results of the last 48 hours.
$dateEnd = get-date $dateStart = $dateEnd.AddHours(-48)
Get-MessageTrace -StartDate $dateStart -EndDate $dateEnd | Select-Object Received, SenderAddress, RecipientAddress, Subject, Status, ToIP, FromIP, Size, MessageID, MessageTraceID | Out-GridView
Here is what the results look like.
Just like with the portal message trace, we can sort by clicking the column headers. Moving onto the differences, the first difference you’ll notice here is that there are more columns presented to us, and even nicer is that we can sort and filter on these extra columns which is something you can’t do in the portal message trace. For example, in the above screenshot, I have set a filter to only show me the messages that were larger than 12 MB, something that is not possible with the portal based message trace. Yes… now we are seeing some of the power!
Next let’s look for messages from the past 48 hours that have a Status of “Failed.” Here is our script.
Get-MessageTrace -StartDate $dateStart -EndDate $dateEnd | Select-Object Received, SenderAddress, RecipientAddress, Subject, Status, ToIP, FromIP, Size, MessageID, MessageTraceID | Where {$_.Status -eq "Failed"} | Out-GridView
This shows that we have five failed messages from the last 48 hours. Now let’s pipe our results to Get-MessageTraceDetail to find out more information on the failed messages. Here’s our next script to do this.
Get-MessageTrace -StartDate $dateStart -EndDate $dateEnd | Where {$_.Status -eq "Failed"} | Get-MessageTraceDetail | Select-Object MessageID, Date, Event, Action, Detail, Data | Out-GridView
And this will return the following:
Here I can see the status of those failed messages. “Hop count exceeded – possible mail loop.” In this situation, a message was destined for a mailbox that didn’t exist in the cloud, because of a connector problem the message kept looping around Exchange Online before it was finally rejected.
Also notice the Data column above. Here we can see a lot of extra information that is not present in the portal message trace.
<root><MEP Name="ConnectorId" String="To_DefaultOpportunisticTLS"/><MEP Name="DeliveryPriority" String="Normal"/><MEP Name="OutboundProxyTargetIPAddress" String="207.46.XXX.XXX"/><MEP Name="OutboundProxyTargetHostName" String="contoso.mail.protection.outlook.com"/><MEP Name="RecipientStatus" String="[{LRT=};{LED=554 5.4.6 Hop count exceeded - possible mail loop};{FQDN=};{IP=}]"/></root>
What’s highlighted in yellow is all the portal message trace will show. The rest of the data can only be obtained with PowerShell, or through an Extended Message Trace. We can see the IP that issued the 500 error, the connector that was used, and even the MX record where Exchange Online was trying to deliver the message to.
Let’s take a look at another example. This time we want to track a particular message based on its Message ID. An end user told us that a sent message resulted in an NDR so we already know it failed. The NDR provides us with the MessageID. Let’s run the following to get directly to the message trace details for this particular message.
Get-MessageTrace -MessageId c857c16bf46d4586a198ec089a710706@BN1AFFO11FD033.protection.gbl | Get-MessageTraceDetail | Select MessageID, Date, Event, Action, Detail, Data | Out-GridView
Right away we can see the error “Unable to relay.” We can also see this message was tried to be delivered using TLS. What we are seeing here is most likely a connector problem.
Of course, you don’t have to use Out-GridView, I just find it sometimes handy for quick filtering of the results.
Lastly, the searches I have provided above are fairly open ended. The tenant I used has a very low number of message coming through it. If you are finding that Get-MessageTrace is taking too long to run or timing out, I would suggest making your search stricter. For example, here is how you would search for messages coming from joe@contoso.com between a particular time range.
Get-MessageTrace -SenderAddress john@contoso.com -StartDate “12/15/2014 21:00” -EndDate “12/15/2014 22:00”
Note that the time specified must be in UTC.
PowerShell can be set to run automatically. One example would be to create a script which checks for messages with a status of “Failed.” Have a server run this script every hour and if you see a large number of results, have the script or the Scheduled Task send you an alert.
For those that have never used PowerShell before it can look a little scary. There are a lot of great tutorials online to get you started and once you get your feet wet you’ll start moving fast. Script once, run many times.
On the personal side, I have a PowerShell script to automatically log me into my tenant. Once connected, I have scripts that pull Transport Rules, Message Trace results, Connector information, and much more. This is often faster than logging directly into the portal.
Finally, I'd like to thank Brian, one of my customers, who gave me the idea for this post.
Happy scripting!
Connect to Exchange Online using remote PowerShellExchange Online cmdletsConnect to Exchange Online Protection using remote PowerShellExchange Online Protection cmdletsRun a Message Trace and View ResultsGet-MessageTrace cmdletGet-MessageTraceDetail cmdlet
I only began this blog in June of this year and so it’s hard to believe that it is already six months old! Looking back over the past six months I have had a blast writing and sharing articles with the community and have received a lot of positive feedback. I have a long list of articles in the hopper that I haven’t got to yet and many more ideas for future posts. Please continue to leave comments on articles as I will always try to leave a reply, it just may not be immediate.
With that being said, I wanted to share the top 10 articles from this blog from this past year. I used to love watching David Letterman’s top 10 list, and if I had more of a budget I’d put together a list Letterman style. Alas, here‘s the list, TechNet style..
I hope that you have a wonderful holiday season and keep up with me in the New Year!
Cheers!
Andrew
This is typically a slow week for people, so what better time than to post something fun about Exchange Online Protection!
Back in May I presented a session on EOP at TechEd North America 2014 which took place in Houston. To be a little different, I wrote a poem about EOP which I read to kick the presentation off. I have always enjoyed poetry and thought I'd try something different by beginning my EOP session with some rhymes. Here's that poem.
Hello to you my TechEd friends,Thank you for joining me here.Today we will learn of a wondrous service,And you'll see, there's nothing to fear. Email can sometimes come with spam,And if you're not careful, a computer infection.Lucky for you, we can prevent those two,With Exchange Online Protection. EOP is a breeze to deploy,There's really nothing to it.Listen closely and don't leave early,You'll soon learn how to do it. Add one domain or up to nine hundred,Then create a connector or two.Now point your MX over to us, And like that, we're protecting you. Now let's begin this break out session,Silence those phones in your pocket.And next time you log in to O365,You'll really be able to rock it.
If you are interested in watching the session, which covers configuration and some interesting tidbits about EOP, it can be viewed on Channel 9.
See you in the new year!