Tuesday, February 10, 2015

How to count the number of DC's in your forest and individual domains with PowerShell

For some reason, with all the power of the internets, this answer was nowhere to be easily found.

I needed to be able to count the number of (Domain Controllers) DC's in our forest, and also for a specific domain. It's a simple PowerShell script ... here is what I used


$domains = (Get-ADForest).Domains;

foreach ($domain in $domains)


    Write-Host $domain
    (Get-ADDomain -Identity $domain | select -ExpandProperty ReplicaDirectoryServers).Count;
    Write-Host "";
    $totalCount = $totalCount + (Get-ADDomain -Identity $domain | select -ExpandProperty ReplicaDirectoryServers).Count;

Write-Host "Total domain controller count is: "$totalCount

Friday, January 16, 2015

5 Tips for Exchange Server 2013 Administrators

Are you thinking about deploying Exchange Server 2103 or have you already done it? Microsoft released the Exchange Server 2103 Preview  in July 2012 and the Release to Manufacturing (RTM) build for Exchange Server 2013 in October 2012. Exchange Server 2013 is now up to cumulative Update(CU) 7 released in December 2014.  In this new blog series, we will be sharing some helpful tips that we know will help you as an Exchange 2013 Administrator.

5 Tips for Exchange Server 2013 Administrators
  1. Learn PowerShell and the Exchange Management Shell.
  2. PowerShell (formerly Monad), a management framework that combines a command line shell with a scripting language. PowerShell has been around since 2006 and is currently up to version 5. Exchange Management Shell (EMS) is an extensible command line interface for Exchange Server Management that sits on top of PowerShell. Learning how to use PowerShell and EMS are important to our jobs as Exchange Server 2013 Administrators. Unlike in Microsoft Exchange Server 2007, where local Windows PowerShell is used, a Windows PowerShell snap-in for Exchange isn't loaded for Exchange 2013. PowerShell connects to the closest Exchange 2013 server using a required component called Windows Remote Management 3.0, performs authentication checks, and then creates a remote session for you to use. There are plenty of resources available online for you to learn more about PowerShell.

  3. Know the hardware Exchange Server 2013 is deployed on.
  4. If you are deploying Exchange Server 2013 at your location on purchased servers, you need to evaluate the following: Memory, CPU and disk space. You will need to purchase Client Access Servers and Mailbox servers. Investing in an Uninterruptible Power Supply (UPS) is highly recommended to allow you to properly shutdown the Exchange servers in case of a power outage.  If you are going with  Exchange Online and Office 365, the data center provides the hardware and will have the ability to scale out and scale up as needed. They will also have UPS for the servers in the data center.

  5. Review and Use the new Exchange Server Role Requirements Calculator(formerly Exchange Storage Calculator)
  6. This tool from Microsoft is essential in giving us recommendations for:
    • Deploying dedicated server roles, the minimum number of Client Access Processor Cores, minimum number of Client Access Servers and memory in each server.
    • Deploying Multi-role servers(Client Access and Mailbox) The Client Access Role will be accounted for in the memory and CPU recommendations.
    New to the tool is transport sizing and database sizing and better utilization of disks for Just a Bunch of Disks (JBOD) scenarios for Exchange 2013 installations. The calculator will recommend multiple databases in each volume and supports single datacenter deployments and multi-datacenter deployments like ours.
    Download the latest version of the Exchange 2103 Server Role Requirements Calculator here.

  7. Have a test lab for your Exchange Server 2013 Environment
  8. This is a critical step in preparation for deploying any version of Exchange Server. Before you begin you should review the Exchange 2013 Prerequisites.  For an Exchange Server 2013 test lab environment, we would suggest domain controller(s), a root Certification Authority (CA) Server, DNS and DHCP Servers, Exchange Server 2013 Mailbox and Client Access Servers and workstations for client testing running Office 2010 or 2013 depending on what is being used in your environment.

  9. Learn how Role Based Access Control (RBAC) works
  10. RBAC is the permission model used in Exchange Server to control what Administrators and users can do based on their roles within your company. Microsoft references the Triangle of Power that addresses The Where, The What and The Who. The Where is where will the permissions be needed. This is also known as the scope. The What is what the person needs to be able to do within The Where. These can be customized to meet your company needs. This is also known as the Role. Finally The Who is the person(s) (administrator or user) that needs to be able to do The What in The Where they have been allowed to do it. This is known as a role group. Finally the Glue or Role Assignment is how all the parts work together. For more information reference "Understanding Role Based Access Control".

We will be publishing an additional group of tips for Exchange Server 2013 Administrators so look out for it soon. If you have any thoughts, opinions or comments feel free to share them below.

Friday, October 31, 2014

Why are some attachments different places in Outlook messages?

Have you ever wondered why some messages with attachments in Outlook have the attachment in the body of the message and why some messages have the attachment at the top of the message below the Subject? This post will tell  you why that happens and how to fix it. I had a user ask me today why this was like this. He wanted the attachment at the top only not in the body of the message.

The reason this happens is due to the format of the message. In Rich Text format,(Supported since Outlook 97) it does in-line attachments in the body of the e-mail message as shown below.

In HTML Format and Plain Text Format the attachment is at the top of the message. HTML Format is shown below (from Office 2013)

Did you notice the attachment to the message sent in HTML format also has the size of the file (26 KB) while the message in Rich Text Format has the same attachment but no indication of file size?

So how do you change the format of the message from Rich Text to HTML? You can do it two ways. You can change it per message by opening a new message then going to FORMAT TEXT in Outlook and choosing HTML as shown below (applies to Office 2010 and Office 2013)

If you want to only send HTML Messages and have attachments be at the top of the message and not embedded in the body you can change it in the Outlook Client settings By going to FILE then OPTIONS then Mail and select HTML as shown below from Office 2103.

This will cause all messages from that point on to be sent in HTML Format. Please note that replies to messages will be sent in the original format of the message because Outlook preserves the format. Also in my testing the Rich Text Formatted message with the attachment in the body was slightly larger than the HTML Formatted and Plain Text messages. I am sure that will make your Exchange Administrators happy when you can send smaller messages with the same content. Microsoft recommends sending messages in HTML Format.  Rich Text format supports in-line attachments and the attachments are in the body of the message. HTML and Plain Text formats do not support in-line attachments.
BONUS TIP:You can also change the message format for all messages sent to an Outlook Contact
  1. Open the contact card for the recipient.
  2. In the E-mail box, double-click the recipient's e-mail address.
  3. In the Internet Format list, select the format that you want to use for messages to this recipient.
I hope this post has helped with understanding why attachments are different in your Outlook client. Feel free to leave comments.

Tuesday, September 30, 2014

Why you should upgrade Distribution groups moving to Exchange Server 2013

If you previously migrated from Exchange Server 2003 to Exchange Server 2007 and now moving to Exchange Server 2013, Group owners will not be able manage distribution groups created in Exchange Server 2003 or Exchange Server 2007 anymore. They can get the following error message when trying to make changes to a group from Outlook: 

In helping a user who could not manage a mail-enabled security group that she was the owner of and had all the correct rights and RBAC roles assigned, we saw that the Exchange Version for the problem group was 6.5 which was an old 2003 group that was not upgraded when our organization migrated to Exchange 2007 a few years ago.

When checking the group we were able to see the Exchange Version Number as shown below:
To upgrade the group using the Exchange Management Shell:
Set-DistributionGroup -id "Name of the group" -Forceupgrade -bypassSecuritygroupManagerCheck
After the group was upgraded we checked the Exchange Version number. It was now Version 14 as shown below. The user was able to manage the group after Active Directory (AD) Replication had occurred.
If you want to upgrade all your groups at the same time you can use the following from the Exchange Management Shell :
Get-DistributionGroup -ResultSize unlimited | Set-DistributionGroup -forceupgrade -bypassSecuritygroupManagerCheck
If you want to get list of the groups with their Exchange Versions in a report that can be shared with management before you begin to upgrade them, you can run the following from the Exchange Management Shell:

$groupdata = Get-DistributionGroup -ResultSize unlimited | select displayname, exchangeversion
$groupdata | export-csv c:\groups_exchversion.csv 

If you want to see the Exchange versions of your groups and get a count by Exchange versions, run the following in the Exchange Management Shell:
$groupdata | group ExchangeVersion
 Get-DistributionGroup -ResultSize Unlimited | Group ExchangeVersion if you had not done the previous CSV export like the example above.
The output should be similar to the following that I got running this in our environment today 

As you can see we have some work to do with upgrading our groups so let me get back to that. If you upgrade the distribution groups to Exchange 2013 but the owners/managers are still on Exchange 2007 they will no longer be able to manage the groups. This happens because the Exchange trusted subsystem cannot modify the legacy (2003 and 2007) objects. If you migrate the users to Exchange 2013 but the groups are not upgraded they will also not be able to manage the group. You should be following the guidance of using Exchange 2007 administrative tools to manage Exchange 2007 objects and using Exchange 2013 administrative tools to manage Exchange 2013 objects.  
Our current approach is to migrate the user mailboxes to Exchange Server 2013 and upgrade the groups for that specific OU to the Exchange 2103 version after the user migration. This way we can ensure that the groups are upgraded in the same timeframe as the user migration to avoid the support ticket that generated this blog post. 
Good luck to those of you moving to Exchange 2013. Please share your feedback and thoughts in the comments.

Friday, August 29, 2014

Why Can't I find a mailbox using Exchange Admin Center (EAC) in Exchange 2013?

Why Can't I find a mailbox using Exchange Admin Center (EAC) in Exchange 2013?

The answer: You may be looking in the wrong place in the Exchange Admin Center(EAC). In older versions of Exchange using the Exchange Management Console (EMC) or the Exchange Control Panel (ECP), you were able to find mailboxes when searching by just entering the name or part of the name and you would get results. Using the Exchange Admin Center (EAC) which is the new web based management console in Exchange 2013, is bit different and I will go through the options to help you get what you want when searching for a mailbox. Please note that with each of the options outlined in this post you need to wait for the data to finish loading before you start searching using the search box.

If you are searching for a User Mailbox be sure you have the mailboxes option selected.

If you are searching for a distribution group you have to have the groups option selected.
If you are searching for a resource mailbox you need to have the resources option selected
If you are searching for a shared mailbox you need to have Shared option selected
I hope this post has helped and made it easier for you when searching for a mailbox using the Exchange Admin Center in Exchange 2013. Please share your comments and feedback on this post.

Friday, August 1, 2014

A possible fix for Calendar Meeting Requests showing up as email messages on a BlackBerry Device

A few weeks ago we started getting reports of users on Exchange Server 2007 with BlackBerry devices getting calendar meeting requests on their BlackBerry device as an email with no option to accept or decline the meeting. We discovered that the problem was due to the
-AutomateProcessing attribute of the impacted mailbox being set to None. The default should be AutoUpdate.
 To see the setting for a single user open the Exchange Management Shell on Exchange 2007and type Get-MailboxCalendarSettings user alias | FL
press enter and look at what the attribute -AutomateProcessing is set to:
 replace user alias with the appropriate alias for the mailbox you are checking.
To fix the issue, type Set-MailboxCalendarSettings user alias -AutomateProcessing AutoUpdate and press Enter. After it is complete you can check again using Get-MailboxCalendarSettings user alias | FL 
and you should see the following: 
replace user alias with the appropriate alias for the mailbox you are checking.

The users were then able to see Calendar Meeting Requests correctly on the BlackBerry device.

If you want to see of all the user Mailboxes that are set to None, you can type the following in the Exchange Management Shell:

Get-Mailbox -Resultsize Unlimited -RecipientTypeDetails UserMailbox | Get-mailboxCalendarSettings | Where {$_.automateprocessing -eq "None"} | FL Identity, automateprocessing > c:\usermbcalsettings.txt

If you want to change the ones that are found you can type the following in the Exchange Management Shell: Get-Mailbox -Resultsize Unlimited -RecipientTypeDetails UserMailbox | Get-mailboxCalendarSettings | Where {$_.automateprocessing -eq "None"} | Get-MailboxCalendarSettings -AutomateProcessing AutoUpdate

  1. For Exchange Server 2010/2013 you will use Get-CalendarProcessing instead of Get-MailboxCalendarSettings and Set-CalendarProcessing instead of Set-MailboxCalendarSettings.

  2. You can only apply Set-CalendarProcessing to Resource Mailboxes. It cannot be used on User Mailboxes like was done for Exchange 2007 users as mentioned in this post. Additionally in Exchange 2103, Exchange ignores the -AutomateProcessing attribute on the user mailbox. So if it is set to None or AutoUpdate, Exchange treats the message the same way, which is to auto update the meeting.

Refer to RIM KB31558 for more information from RIM about this issue.

If this has helped you fix Calendar Meeting requests showing up as email messages on BlackBerry devices please share in the comments or if you have any additional insights in to this issue, it would be appreciated.

Thursday, March 6, 2014

Fun With PowerShell (Make it Speak)

In my downtime, I wanted to have some fun with PowerShell and make it speak using Add-Type -AssemblyName System.Speech. I have always written an age calculation script in every scripting language I have learned and I realized I had never done one in PowerShell. So I wrote one and decided to have it speak to you. Here it is:

# Funscript.ps1                        # 
# http://imjustanengineer.blogspot.com #
# Written by DJ 3/2014                 #

Add-Type -AssemblyName System.Speech
$synthesizer = New-Object -TypeName System.Speech.Synthesis.SpeechSynthesizer

Write-Host This script will tell you how old you will be in $year and will speak to you. Make sure your speakers are on.;
$synthesizer.Speak("This script will tell how old you will be in ($year) and will speak to you. Make sure your speakers are on. ") | Out-Null
$name = Read-Host 'What is your name?';
$synthesizer.Speak("Hello, ($name) ,!") | Out-Null
$yb = Read-Host 'What year were you born?';
$synthesizer.Speak("Thank you, ($name) ,") | Out-Null
$date = Get-Date;
$year = + $date.Year;
$today = Get-Date -Format D;
$span = $year - $yb;
Write-Host Hello, $name. Today is $today. You will be $span years old this year. When is the party?;
$synthesizer.Speak("Hello, ($name). Today is ($today). You will be ($span) years old this year. When is the partee? ") | Out-Null


I would like to see what you can come up with. Be sure to leave your comments and suggestions below.

Friday, January 17, 2014

Have you ever needed to keep the mouse moving? MouseMover can help.

After looking around the Internet a little and not finding a decent mouse moving program, I decided to write my own. I wanted something that had an adjustability to how fast or slow the mouse would oscillate back and forth as well as over all oscillation time, instead of one that just oscillates every second making it ridiculous.

If you have improvements or suggestions, just comment and mention them.

Download link for MouseMover

Friday, May 10, 2013

How to have a single instance app that minimizes to the system tray, as well as restores from the tray and any duplicate instance bring the original to the foreground

For a recent project, I wanted to minimize my application to the system tray, as to not inhibit the precious toolbar space for an application that is accessed at the beginning of the workday and the end of it. I also wanted to be able to restore the application from the system tray, as well as not allow more than 1 instance of the application to be opened and if the user attempted to do that, to bring the original application into the foreground before closing the duplicate app.

This proved to be much more convoluted and difficult then I had originally expected. I found a ton of different suggestions on the internet as to how to do this, but nothing straight forward and plug and play, so this blog post will be all about adding code into an existing project that is plug and play as well as giving a simplistic example application to cherry pick from or build off of. I tried to be as detailed as possible, if I missed a step please comment so I can explain a step or add a step into this.

Create a form in Visual studio, go to the toolbox and add a notify icon to the form1, then choose your icon and the icon name. You'll need to modify the third entry below named this.nofityIcon1.Icon to whatever you name your icon by going into the solution explorer, right clicking on the project name, clicking on the resources menu tab and then add a resource/add existing file. At this point that file will now reside in your resources and be accessible via Properties.Resources .

You can add the following to the Form1_Load method if you would like, it is optional

this.notifyIcon1.BalloonTipIcon = System.Windows.Forms.ToolTipIcon.Info; //Shows the info icon so the user doesn't thing there is an error.
                this.notifyIcon1.BalloonTipText = "[Balloon Text when Minimized]";
                this.notifyIcon1.BalloonTipTitle = "[Balloon Title when Minimized]";
                this.notifyIcon1.Icon = ((System.Drawing.Icon)(Properties.Resources.alarm_clock_face_s)); //The tray icon to use
                this.notifyIcon1.Text = "[ApplicationName] application, double click to restore program";

Inside of Form1() you'll need to capture 2 events via the event handlers and have two corresponding functions to handle those events as well as add a new warning message form. Under solution explorer, right click on the solution, then add, then windows form. Name the form (I called it the default name of form2.cs) and then add a label and a checkbox to it for this code, or anything else you would like to customize it with.

this.Resize += new EventHandler(form1_Resize);
            notifyIcon1.DoubleClick += new EventHandler(notifyIcon1_DoubleClick);

       private void form1_Resize(object sender, EventArgs e)
            if (FormWindowState.Minimized == WindowState)
                Form2 warningForm = new Form2();
                    RegistryKey key = Registry.CurrentUser.OpenSubKey("Software", true);
                    if (key.OpenSubKey("TimeKeeper") == null)

                    RegistryKey subKey = key.OpenSubKey([KeyName], true);
                    string regValue = subKey.GetValue("minimizeWarningHide").ToString();

                    if (regValue == "true")
                        // continue on

                catch (Exception ex)
                    MessageBox.Show(ex.Message + System.Environment.NewLine + ex.Source + System.Environment.NewLine + ex.TargetSite + System.Environment.NewLine + ex.StackTrace + System.Environment.NewLine + System.Environment.NewLine);



      private void notifyIcon1_DoubleClick(object sender,System.EventArgs e)
            WindowState = FormWindowState.Normal;

In the new form2 you'll want to paste the following code after adding checkBox1 (which I renamed to ckbxMinimizeWarning), again be sure to change the [KeyName] value to your registry key name that you've chosen. You also want to add the include using Microsoft.Win32; to the top. You'll also want to disable the minimizebox and maximizebox buttons for this warning message, they aren't necessary and could confuse your user.

private void checkBox1_CheckedChanged(object sender, EventArgs e)
                RegistryKey key = Registry.CurrentUser.OpenSubKey("Software", true);
                if (key.OpenSubKey([KeyName]) == null)

                RegistryKey subKey = key.OpenSubKey([KeyName], true);

                if (ckbxMinimizeWarning.Checked == true)
                    subKey.SetValue("minimizeWarningHide", "true", RegistryValueKind.String);

                if (ckbxMinimizeWarning.Checked == false)
                    subKey.SetValue("minimizeWarningHide", "false", RegistryValueKind.String);
            catch (Exception)

At this point you'll want to put this code into your Form1_Load() method, ensure to change [KeyName] to the name of the key you want to house your registry settings in, inside of hkcu\software. Also don't forget to add the registry include, using Microsoft.Win32; at the top of your project.

RegistryKey key = Registry.CurrentUser.OpenSubKey("Software", true);
                if (key.OpenSubKey([KeyName]) == null)

                RegistryKey subKey = key.OpenSubKey([KeyName], true);

                string[] subKeys = subKey.GetValueNames();

                if (!(subKeys.Contains("minimizeWarningHide")))
                    subKey.SetValue("minimizeWarningHide", "false", RegistryValueKind.String);

Lastly go into the program.cs code and we will use pin invoke.

The first thing to do is add the pininvoke include as well as threading include at the top of program.cs
using System.Runtime.InteropServices; and using System.Threading; This part of the code allows you to identify existing windows and to bring a window to the foreground as needed. Be sure to change the Mutex value of ExampleMinimizeToTrayProject per your own needs. This is a unique value and needs to be unique for each application you write, or else the applications will all think they are the same application (no matter the code) when the open. Mutex stands for Mutually Exclusive.

Here is the program.cs code

static class Program
        /// The main entry point for the application.
        /// </summary>
        static void Main()
            if (IsSingleInstance())
                Application.Run(new Form1());
                bringToFront("Time Keeper");

        static private Mutex _instanceMutex = null;

        [DllImport("USER32.DLL", CharSet = CharSet.Unicode)]
        public static extern IntPtr FindWindow(String lpClassName, String lpWindowName);

        public static extern uint GetWindowThreadProcessId(IntPtr hWnd,
            IntPtr ProcessId);

        public static extern IntPtr GetForegroundWindow();

        public static extern uint GetCurrentThreadId();

        public static extern bool AttachThreadInput(uint idAttach,
            uint idAttachTo, bool fAttach);

        [DllImport("user32.dll", SetLastError = true)]
        public static extern bool BringWindowToTop(IntPtr hWnd);

        [DllImport("user32.dll", SetLastError = true)]
        public static extern bool BringWindowToTop(HandleRef hWnd);

        public static extern bool ShowWindow(IntPtr hWnd, uint nCmdShow);

        public static void bringToFront(string title)
            IntPtr hWnd = FindWindow(null, title);
            uint foreThread = GetWindowThreadProcessId(GetForegroundWindow(), IntPtr.Zero);
            uint appThread = GetCurrentThreadId();
            const uint SW_SHOW = 5;

            if (foreThread != appThread)
                AttachThreadInput(foreThread, appThread, true);
                ShowWindow(hWnd, SW_SHOW);
                AttachThreadInput(foreThread, appThread, false);

        static Mutex _m;
        static bool IsSingleInstance()
                // Try to open existing mutex.
                // If exception occurred, there is no such mutex.
                Program._m = new Mutex(true, "ExampleMinimizeToTrayProject");

                // Only one instance.
                return true;
            // More than one instance.
            return false;
Then add an image to form2 by going to the tool box and adding a picturebox and browsing to an image under the solution explorer for the picturebox, showing the system try and what the icon looks like placed in it by importing it. Then add the label (if you would like) as well as text to the label on form2 explaining to them the minimizing process. I use the following text

This program will be minimized to the system tray by the clock as pictured above. To restore it, look for the alarm clock icon inside of the system tray icon list and double click it.</blockquote>
Also add the following text to the form2 checkbox explaining its usage

Select this not to see this warning again.</blockquote>
Lastly, make sure the bringToFront("[texthere]"); in program.cs is looking for the name of your form, whatever text name you've given it in your project. In this project you'll see it is named ExampleMinimizeToTrayProject.

Project for download: (the second link should be a direct link)



References I used:






single instance app application
system tray minimize restore from tray

Monday, May 6, 2013

How to fix Lync Server Error "An unhandled exception was encountered in Service service"

We recently encountered an error with a Microsoft Lync server "An unhandled exception was encountered in Service service" that impacted users who were trying to expand a Distribution Group in Microsoft Office Communicator 2007 that had a simple fix. Read more about this error message and how we fixed it.

From the log files:

Log Name:      Lync Server
Source:        LS Web Components Server
Date:          4/30/2013 11:39:41 AM
Event ID:      4096
Task Category: (1074)
Level:         Error
Keywords:      Classic
User:          N/A
Computer:      DC-FEC-22.dc.ad.contoso.com
An unhandled exception was encountered in Service service.
Exception Details. System.Runtime.InteropServices.COMException (0x8007203A): The server is not operational.
   at Microsoft.LiveServer.DLExpansion.Service.ThrowSoapFault(Exception e)
   at Microsoft.LiveServer.DLExpansion.Service.QueryADGetDistributionListInfo(String mail, DirectorySearcher dSearcher)
   at Microsoft.LiveServer.DLExpansion.Service.ProcessADRequest(OCSPrincipal user, String key, DlxGroup& result)
   at Microsoft.LiveServer.DLExpansion.Service.ExpandDistributionList(String groupMailAddress)
   at SyncInvokeExpandDistributionList(Object , Object[] , Object[] )
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage4(MessageRpc& rpc)
   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)
Cause: Application error. Please look through the exception details for more information.
Restart the server. If the problem persists contact product support.

Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
    <Provider Name="LS Web Components Server" />
    <EventID Qualifiers="50226">4096</EventID>
    <TimeCreated SystemTime="2013-04-30T15:39:41.000000000Z" />
    <Channel>Lync Server</Channel>
    <Security />
    <Data>System.Runtime.InteropServices.COMException (0x8007203A): The server is not operational.
   at Microsoft.LiveServer.DLExpansion.Service.ThrowSoapFault(Exception e)
   at Microsoft.LiveServer.DLExpansion.Service.QueryADGetDistributionListInfo(String mail, DirectorySearcher dSearcher)
   at Microsoft.LiveServer.DLExpansion.Service.ProcessADRequest(OCSPrincipal user, String key, DlxGroup&amp; result)
   at Microsoft.LiveServer.DLExpansion.Service.ExpandDistributionList(String groupMailAddress)
   at SyncInvokeExpandDistributionList(Object , Object[] , Object[] )
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]&amp; outputs)
   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc&amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc&amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage4(MessageRpc&amp; rpc)
   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)</Data>

• Affected Users: users trying to expand Distribution Groups in Office Communicator 2007 were affected.

• Fix: Restarted IIS on Lync servers. Please leave your thoughts in the comment section below this post.

Friday, February 8, 2013

Browse the registry just like a UNC path

Periodically I am searching for a registry path and I stumble upon something on the internet telling me to go 10+ subkeys into a hive to find a value. Although not terrible, it's kind of annoying to switch back and forth between regedit and the browser to follow the path down to the key that I need.

After some googling, I found that Mark Russinovich made a command line version of a tool for this, but I wanted a GUI so I decided to write my own registry jump browser tool. It's pretty simple to use, you plug the key into the input box and hit enter or click the browse registry button.

Format for the key path should look like

hklm\SOFTWARE\Microsoft\Test Key\Test Sub Key

and if the key is present, it will open the registry and navigate down to the key you've input. If the key does not exist, it will tell you that as well.

You may also use a command line version of this using the format below in the command prompt (remember to navigate to it)
regbrowser "hklm\software\microsoft"

You can only have 1 instance of the registry open when doing this, and it is designed for local registry browsing only, FYI.

Enjoy and leave a comment if it is useful for you, or if you have a suggested improvement.


^ new version with help file built in and minor added functionality


^ Sorry blogspot doesn't host .zip files

Tuesday, January 15, 2013

So you're getting Event Manager / Application Log code 9669

This event manager code is generated when your Exchange Server 2007 environment has run out of rows to write to in a database column, that hold unique mail header information, per each mail server. There are many posts on the internet as to how to raise the threshold for this table up to the max (database crashing) limit of 32768.

If you've temporarily raised the ceiling, just as congress keeps raising the debt ceiling, you probably realize just as congress does that eventually a limit is going to be reached and everything is going to then crash and burn.

Fortunately for you, Microsoft decided to build a way to monitor this ceiling/threshold.

Open up regedit and navigate to HKLM\System\CurrentControlSet\Services\MSEXchangeIS\Performance

• Modify the string value "Library" from (notice the dll name) [drive you have exchange program files on]\Program Files\Microsoft\Exchange Server\Bin\Perf\%Processor_Architecture%\mdbperf.dll


[drive you have exchange program files on]\Program Files\Microsoft\Exchange Server\Bin\Perf\%Processor_Architecture%\mdbperfx.dll

• Go to each server and apply the attached registry file change (rename the file extension appropriately)

• Open perfmon after registry change

• Right click and add counters and then select “MsExchangeIS Mailbox” under the counters and expand it

• Scroll down to “Rows in ReplidMap Table” and click once on it

• In the “Instances of selected object” window below, highlight each database individually and click add and then ok

• Next scale your counters and determine if any of them are approaching the 16383 out of the box limit

• Save the counter report as an html file so you can go back later, run the report again and calculate the rate of change each day, you can also export them as a .tsv (Tab Separated Value) file for sharing.

At this point you can spot check all other databases to see which are also approaching the replica id limit you've coded into the registry. You can also check these values with a powershell command after you've altered the registry key mentioned above.

The code for that is:

Get-mailboxserver | foreach {get-counter –counter “\MSExchangeIS Mailbox(*)\Rows in ReplidMap Table” –sampleinterval 2 –maxsamples 1}

Tuesday, January 8, 2013

My Top 10 Windows Phone Apps

This post is inspired in part by my friend Chip Diz├írd who is new to Windows Phone which has been out since 2010 and I have been an owner of a HTC Trophy Phone since July 2011 and the Windows Phone Marketplace now has over 100,000 apps, For those of you who are new to Windows Phone, I'd like to share My Top 10 Windows Phone apps that I like and that I find useful.(not listed in any order)

10. WeatherLive

WeatherLive is a great weather app with great Live Tile Support. Being able to quickly see the updated forecast for my location from the Live Tile pinned to my Start Screen, See the10 day outlook, radar and satellite views as well as view webcams is fantastic. Publisher: Hyperise
Cost: Free

9. Slacker Radio
Slacker Radio is a great way to listen to music. I am not one of those people who has 5,000 songs on my device. Slacker Radio gives me access to over 200 professionally programmed stations as well as letting me create a station based on my tastes in music. Publisher: Slacker, Inc. Cost: Free

8. Rowi [lite]
I know that there are quite a few choices for Twitter Apps in the Windows Marketplace but I find Rowi to be a great Twitter app for Windows Phone with a simple interface. I like being able to pin my @mentions to my start screen. There are ads in the [lite] version of the app.  Publisher: Hidden Pineapple, LLC Cost: Free and $1.49 (ad-free with push notifications)

7. FoodSpotting

The Foodspotting app makes finding food recomendations at restaurants easier. I use it to take photos of good foods & share where to find them. I always check it for recommendations when I travel and I add the places I visit so others can see what's great.
Publisher: Foodspotting 
Cost: Free

6. Betty Crocker

Solve the age old question of What's for dinner?  Get great recipes from the mobile version of the world-famous Betty Crocker cookbook. I use it to update my Evernote grocery shopping list for ingredients for the meal.
Publisher General Mills Inc.
Cost: Free

5. Open Table
For the times when I do not cook at home, I like being able to make restaurant reservations for free, instantly from my Windows phone with Open Table. There are more than 15,000 OpenTable-enabled restaurants in the United States, Canada and United Kingdom.
Publisher: OpenTable, Inc.
Cost: Free

4. GasBuddy

 When I need to know if gas is cheaper near my home, near my job or near me if I am out running errands or traveling, I click on Gas Buddy before I start driving. Gas Buddy also tells you in miles, how far away you have to drive to get it. As an added bonus, if you help report gas prices at stations if they are different, you can get a chance to win free gas.
Publisher GasBuddy.com 
Cost: Free
Evernote allows you to create notes, lists that can be accessed from anywhere and shared with anyone. I can create shopping lists on my iPad that I can view on my phone while I am at the store. Or I can create the list on my phone while looking at a recipe on the Betty Crocker app. You can also update your Evernote notes from your computer.
Publisher Evernote
Cost : Free

2. SBux

Though it is not the official Starbucks app, SBUX comes pretty close to matching what Starbucks has done for iOS and Android devices. Paying with the phone, finding the closest starbucks to your current location and adding multiple cards are some of the features I like.
Publisher Denham Software Solutions
Cost : Free

1. Vimeo
The Vimeo app allows you watch videos as well as manage your videos if you have any on the site. You can create pinned tiles with your videos or featured channels. Sharing videos using social media is easy.
Publisher: Vimeo
Cost: Free

While there are thousands of apps available for Windows Phone users to get including others that do similar things to my list of Top 10 Windows Phone apps, I hope you will check out the ones I have shared in this post. I like the features and functionality provided by apps and I invite you to share some of your favorite Windows Phone apps in the comments.

I was not compensated financially for mentioning any of the apps included in this post. I was, however, rewarded with satisfaction and enjoyment which allowed me to create this post about My Top 10 Windows Phone Apps.