Windows IT Pro is the leading independent community for IT professionals deploying Microsoft Windows server and client applications and technologies.
  
  
  Advanced Search 


September 2000

Export and Import Mission: Possible


RSS
Subscribe to Windows IT Pro | See More Task Automation Articles Here | Reprints | Or get the Monthly Online Pass—only $5.95 a month!
SideBar    Know Your Options

Quick and easy ways to complete daunting tasks

[Editor's Note: Some material in this column was adapted from Chapter 5 of Managing Microsoft Exchange Server, ISBN 1565925459. The information appears here courtesy of the publisher, O'Reilly & Associates.]

In "Super Export and Import Tools," August 2000, I explored the basics of Microsoft Exchange Administrator's directory export and import features. Now for the big payoff: Learn how to overcome onerous tasks such as exporting the entire Global Address List (GAL), exporting and importing custom attributes, and batch-creating mailboxes and Windows NT domain accounts simultaneously.

Take the Command (Line)
You can use the admin.exe command-line tool to run Exchange Administrator; the tool's /e and /i options let you automate exports and imports, respectively. When you use this command-line tool instead of the process that I explained in "Super Export and Import Tools," you can easily export items for import into a non-Exchange Server directory or import data from such a directory. To use admin.exe, type the following at the command prompt:

admin {/e | /i} <csvfile> /d <dirservername>
 [/n] [/o <optionsfile>]

The /e and /i switches toggle between export and import mode. The csvfile variable specifies the full path to the Comma Separated Values (CSV) file that you want to export or import. (For more information about CSV files, see "Super Export and Import Tools.") In export mode, if the specified CSV file exists, Exchange Administrator uses that file's existing header; if the CSV file doesn't exist, Exchange Administrator uses the default set of export headers. In import mode, the specified CSV file must exist and contain a valid header, or Exchange Administrator will return an error.

In export mode, /d dirservername tells Exchange Administrator which Exchange directory server to contact to retrieve the data. (This server is the same one you selected from the MS Exchange server drop-down list in Exchange Administrator's Tools, Directory Export dialog box when you exported the CSV file.) In import mode, /d dirservername specifies which server will receive the imported data.

The optional /n switch forces Exchange Administrator to hide its progress dialog—a useful option when you're automating exports or imports as part of a scripted or scheduled operation. The optional /o optionsfile switch specifies the full path to an options file that you can use to control the exported or imported information. (To learn more about options files, see the sidebar "Know Your Options.") For example, the following command uses the gal.txt options file to control an export from my primary Exchange server (i.e., hawk), using the mailbox.csv file from the Exchange Server CD-ROM:

admin /e mailbox.csv /d hawk /o gal.txt

Mission 1: Conquer the GAL
People frequently ask me how to export the entire GAL: a useful trick when you have users (e.g., 3Com's PalmPilot users, Microsoft Outlook Web Access—OWA—users) who can't use the Outlook Offline Address Book (OAB) or when you want to give an outside organization access to your GAL's contents without exposing an Exchange server. (Beware: Exporting a large organization's GAL can take a long time, and the resulting file might be too large for a handheld device or Web page.)

To export the GAL, you need an export options file that specifies the correct starting point for the export operation. For example, I can use the following file to export the GAL from my organization (i.e., ra):

[export]
basepoint=/o=ra
exportobject=mailbox
informationlevel=full
subcontainers=yes
   Previous  [1]  2  Next 


Top Viewed ArticlesView all articles
WinInfo Short Takes: Week of November 23, 2009

An often irreverent look at some of the week's other news, including some post-PDC some soul searching, a Google Chrome OS announcement and a Microsoft response, Windows 7 off to a supposedly strong start, the Jonas Brothers and Xbox 360, and so much more ...

2009 Windows IT Pro Editors' Best and Community Choice Awards

Picking a favorite product from an impressive crowd of competitive offerings is never an easy task, and such was the case with our Editors' Best and Community Choice awards this year. ...

Command Prompt Tricks

One reader shares his tip for setting up the command prompt to reflect a remote path. ...


Task Automation Whitepapers From Development to Production: Streamlining SharePoint Deployment with DocAve Deployment Manager

Take Control of Your Email: Understand the Business Reasons for Email Storage Management

Related Events Deep Dive into Windows Server 2008 R2 presented by John Savill

Bail Out Your Exchange Environment

Check out our list of Free Email Newsletters!

Task Automation eBooks Spam Fighting and Email Security for the 21st Century

A Guide to Windows Certification and Public Keys

Keeping Your Business Safe from Attack: Patch Management

Related Task Automation Resources Introducing Left-Brain.com, the online IT bookstore
Looking for books, CDs, toolkits, eBooks? Prime your mind at Left-Brain.com

Discover Windows IT Pro eLearning Series!
Clear & detailed technical information and helpful how-to's, all in our trademark no-nonsense format


Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro DevProConnections IT Job Hound
Left-Brain.com Technology Resource Directory asp.netPRO ITTV Windows SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 © 2009 Penton Media, Inc. Terms of Use | Privacy Statement