Software

Exchange 2007: Get used to the command line

With the Exchange Management Shell, there are some things that you can do only from the new command line interface.

Like it or not, Microsoft has put a whole ton of effort into making Exchange 2007 completely manageable via a Windows PowerShell-based management interface. In fact, there are some things that you can do only from the new command line interface--not even the GUI can handle these tasks. The Exchange Management Shell, as it's called, is based on Windows PowerShell, which started with the code name Monad. The shell includes very good help features, but, with the complexity of Exchange itself, can get pretty complicated to use. I’m not going to get into providing shell examples in this tip (I will in future tips, though), but will share with you some things that may make using the shell easier.

To get started in the shell, go to Start > All Programs > Microsoft Exchange Server 2007 > Exchange Management Shell. This opens a window that looks a lot like a normal command window but, instead of using the old cmd.exe in the background, this is the new, rather plain-looking PowerShell.

To get a list of Exchange specific commands in the shell, type get-excommand. For a quick guide to getting started with the shell, use the command quickstart instead.

As I mentioned, the command shell can be fairly complex, but Microsoft tries to ease this complexity by, for some functions in the GUI command tool (Exchange Management Console), providing you with the complete command line syntax that would have performed the same job. For example, when you use the new mailbox wizard in the GUI, the summary page of the process outputs the command shell syntax. This can be incredibly useful if you want to ultimately be able to script Exchange events.

The new command shell is a very welcome addition to the Exchange tools family and makes Exchange management very flexible while providing administrators with a way to automate important functions.

6 comments
storm3d
storm3d

Microsoft makes the things much more complicated and useless. Vista, shell, etc. As a microsoft administrator makes me these steps sick and I really wish to see Microsoft sink as a Titanic. Please God do it for us...

rapell
rapell

this functionality to its basic shell. I don't have access to exchange 2007 but wouldn't it be more fun if every powershell installation added this exchange functionality? or are there some tools i can install to provide for this?

Tachyon
Tachyon

To think of all the years that Microsoft has been trashing on Linux and UNIX for it's command line interface, while touting their GUI. Meanwhile, most professional Linux distros now have better GUI admin tools than Windows, and Exchange is going to a CLI? What next, cats sleeping with dogs, fire from the sky?!

techrepublic
techrepublic

There's a learning curve that has to be followed for most people. Basic functions lead to more advanced ones. I think the idea was to introduce it in an environment that was disconnected from the Server to facilitate learning. Once the new Exchange hits, there should be enough aquired skills to manage tasks. Rudementary skills come before practical application. There's a reason why they renamed it Powershell. It can do powerful things, as well as create a disaster for someone unskilled.

fer
fer

Microsoft Learns from experienced ones! Congratulations!

rapell
rapell

sure most admins would not go testing on their production networks. And when you talk of the 'Power' in powershell, don't ask me about the changes I once made to a registry and forgot what they were.....and why I had done it in the first place. That aside my major need was to integrate scripting in exchange management. Am sure VBScript can accomplish most of the tasks, but let's go powershell, it's easier to learn and not verbose.(Though dangerous)