Windows Insider

The Beauty of the MMC

The Microsoft Management Console—with its handy snap-ins—makes Windows 2000 management a breeze.

Last month, I discussed the overall architecture of the Microsoft Management Console and the history of its development. That discussion continues with MMC configuration and usage as the focal point of Windows 2000 administration. As I mentioned, the MMC is a COM container that hosts snap-ins, which plug into and take advantage of the common interface. The interface has a familiar Explorer look and feel, but it also has MMC-specific menu options. The best way to start is to bring up an empty container, as shown in Figure 1, by entering MMC at Start | Run or at the command prompt.

MMC Container
Figure 1. By entering MMC at Start | Run or at the command prompt, you get the MMC container with an empty console root that can be used to hold one or more COM administrative objects. (Click image to view larger version.)

The MMC container comes up with an empty console root that can be used to hold one or more COM administrative objects. The main container has several menu options on the top bar, with the Console menu as the most important. The Windows and Help menu options provide familiar functions. Windows allows you to tile, cascade or create additional root windows in the MMC. The Help menu is interesting because, as you add snap-ins, the help files of the snap-ins are linked to the Help file of the parent container.

Exercising Control
Under Console, the Options menu allows you to define the mode relating to how a specific instance of the resulting MMC tool will behave (Figure 2). These various modes control access to the modification of the MMC tool and how much information can be displayed after distribution. This is very useful when granting departmental administrative capability to non-technical people. Author mode permits full rights and is used to create and modify the MMC. There are three other user modes, each tightening what the user can do. “User mode-full access” gives complete access to the objects provided by the snap-ins in the provided tool; however, the user isn’t able to add or remove snap-ins. “User mode-limited access, multiple window” locks down the tool a bit more by only allowing access to the windows that were saved when the particular tool was saved. “User mode-limited access, single window,” narrows the field further by only allowing one window to open. The various modes control the scope of what the MMC tool can do, with the purpose of alleviating confusion when used by the targeted administrator.

Console Options
Figure 2. The Console Options menu allows you to define the mode to control users’ abilities to modify the MMC.

The other option on the Console menu is Add/Remove Snap-in, which is the entry point for the customization of the MMC tool. Selecting this option takes you to a pop-up window that displays an Add button. Clicking on this button brings you to a list box (Figure 3).

Adding snap-ins
Figure 3. Selecting the Add/Remove Snap-in brings up a pop-up menu with an Add button. Clicking on this button takes you to a listing of a variety of snap-ins.

Super Snap-ins
There’s a substantial list of snap-ins standard with Win2K. Third-party vendors can also easily create snap-ins for their products, which appear here once the parent applications are installed on the Win2K system. Usually a vendor will supply a customized MMC tool specifically designed for its product, similar to the default customized MMC tools that are part of the standard Win2K installation.

While all snap-ins follow the MMC architecture, each has its own characteristics. For example, some snap-ins can manage the local machine or a remote machine as shown in Figure 4. If you want to manage both a local machine and remote machines, you can specify each one independently and create granular management tools for a localized administrator. Some snap-ins, such as the Event Viewer, also provide an option to override the computer name when invoked from the command line (for example, mcpmag.msc /computer=namegoeshere).

Managing local and remote machines
Figure 4. Some snap-ins can manage local or remote machines. (Click image to view larger version.)

Another snap-in characteristic is the ability to add sub-components, called extensions. Not all snap-ins have extensions. You can determine if a snap-in has associated extensions by opening the Extensions tab and selecting a loaded snap-in. As each snap-in is loaded, a list of available extensions will be listed in the bottom display window. For example, the Computer Management snap-in comprises various extensions that allow individual control of various aspects of a computer. The default Computer Management snap-in in the Administrators menu has all the associated extensions loaded, but if you don’t want a localized administrator to deal with Users and Groups or run the Disk Fragmentation utility, you can remove these extensions to limit control.

Getting to the Root of the Matter
Once you’ve chosen the various snap-ins to add, you’ll have a series of name spaces hosted by the root console. Each console has its own menu and toolbar, separate from those of the main MMC window, that help a user perform tasks. This root console can be saved in the Administrative Tools menu (Figure 5) or anywhere in the file system. This parent console, which contains the root, is stored as an .MSC file that can also be brought up by running the named file. After a file is saved, you can distribute it to the administrators you want using it.

Root console
Figure 5. Root consoles—each with its own menu and toolbar—can be saved in the Administrative Tools folder, then distributed to administrators.

The resulting view of the MMC tool is shown in Figure 6, with the container file name at the top. The left pane holds each name space and can be expanded and collapsed as desired. On the right side, the contents (or details) pane displays the various components in each snap-in, as well as the related information for each item in the name space. The details pane can display many types of information, including Web pages, graphics, charts, tables and columns.

MMC details pane
Figure 6. The details pane of the MMC tool displays the various components in each snap-in.

The Joy of the Taskpad
There’s another way to control and display information in the MMC: the Taskpad view. This method provides another layer of abstraction between the system administrator and various localized administrators who may not understand the underlying technology, but still need to obtain certain information or make specific limited changes to the system.

The Taskpad view is created via a wizard by choosing the New Taskpad View option on the Action menu under the Root Console.

As you’d expect, the wizard is a series of screens, the most important of which gives you various self-explanatory options on how you’d like the results to be displayed (Figure 7). Since these views can be modified with an edit menu at any time, it’s best to try out different options and see which one best suits your needs. Another pertinent screen allows you to choose if the Taskpad view will apply to the currently selected container or to all similar containers in the MMC.

Customize TaskPad
Figure 7. A wizard allows you to customize the display for the Taskpad View. (Click image to view larger version.)

The next screen allows you to give the Taskpad view a particular name and description. The final screen is vital, as it gives you the opportunity to add tasks to this particular view. For example, Figure 8 is a Taskpad view that allows an administrator to view devices by type and connection. It also allows the admin to print the views. Be aware that this hides all other options in the regular Control Panel | System | Devices view.

Display devices
Figure 8. This Taskpad view displays devices by type and connection, as well as allows an administrator to print the views. (Click image to view larger version.)

More Cool Stuff
Examples of the flexibility and possibilities of the MMC architecture are found in some of the snap-ins. Two of the snap-ins have the ability to include Web sites and ActiveX controls in the MMC. ActiveX controls are useful to display information from supporting utilities or monitoring programs you may have running. The Web site snap-in simply installs a browser into the Contents pane.

While you can display any reachable Web site, this snap-in is commonly used to point to internal and external support sites that provide updated troubleshooting tips and service patches. By placing these types of Web sites here, you can distribute them to other administrators with the .MSC file and keep the sites within the context of the support efforts.

The best way to become familiar with the MMC is to play with it—productively, of course. It’s easy to modify an author-mode .MSC file once you’ve created it, so try the various options to see if the results are useful. The information in the help file is very useful and should be the first source of detailed information. Once you’ve created a series of MMCs, you’ll find it one of the most valuable tools in the Win2K arsenal.

Featured

comments powered by Disqus

Subscribe on YouTube