Logon Scripts

 

CSVDE - Home

Introduction to CSVDE

This section explains how CSVDE can bulk import users into Windows 2003 Active Directory.  You can also extend this import principle to create computer accounts for XP professional machines.  Another job for CSVDE is to design users with Exchange mailboxes.

Topics for CSVDE

Purpose of CSVDE in Windows 2003

CSVDE is the type of program that you learn for a specific task and then forget about.  Therefore, what you need are a few tried and tested examples to get started.  The classic job for CSVDE is to import user accounts into a Windows domain.  While I often use CSVDE to create users on my test network, my main use for CSVDE is to research LDAP names.  What I do is a quick export of Active Directory into a .csv file.  I then open that .csv export file with Excel and study the LDAP fields in the first row of the spreadsheet.

What does the acronym CSVDE mean?

Comma - Delimit data with a comma, not tab.  CSV is an ideal format for Excel.
Separated - Split a string of data, so that each property fits into an LDAP column.
Value - We focus on the values, rather than properties.
Data - Again concentrate on the data, and don't worry about the objects.
Exchange - Move data from the spreadsheet into Active Directory (or vica versa).

How CSVDE works

Think of CSVDE as the engine that drives data into or out of Active Directory. This CSVDE engine has two directions, export and import. The data consists of Active Directory accounts in CSV format. Excel, or a similar spreadsheet, is marvelous at dropping the comma-separated data into columns. To actually export from Active Directory, all you need is CSVDE -f filename.csv. As export is the default mode, there is no -e switch, so just issue CSVDE, the -f switch and a suitable name.

The knack of reading the data is to launch Excel, find the export file and open it as a spreadsheet. Fortunately, Excel has a built-in csv converter, each row in Excel holds one user's properties and each column represents one LDAP field. As we will see, only a few fields are compulsory. Most columns are optional and can remain blank if you wish.

Whenever you transfer data in the other direction, from the file into Active Directory, you must actively switch CSVDE into import mode. This is why you need the extra the -i parameter. For example CSVDE -i -f filename.csv.

Guy Recommends: SolarWinds Engineer's Toolset v10Engineer's Toolset v10

The Engineer's Toolset v10 provides a comprehensive console of utilities for troubleshooting computer problems.  Guy says it helps me monitor what's occurring on the network, and the tools teaches me more about how the system literally operates.

There are so many good gadgets, it's like having free rein of a sweetshop. Thankfully the utilities are displayed logically: monitoring, discovery, diagnostic, and Cisco tools.  Download your copy of the Engineer's Toolset v 10

The three foundations of CSVDE

  • A good spreadsheet
  • Knowledge of LDAP
  • Begin with CSVDE Export

 

Each of these three areas enhances the other two. How do you gain knowledge of LDAP? The answer is by exporting the LDAP fields that already exist in Active Directory. Where can you best display these LDAP properties? The answer is in a spreadsheet. Which command do you execute to create that spreadsheet?  The answer is export with CSVDE -f filename.csv.

Why begin with CSVDE Export?

My mission is to get you started. In fact, my first goal is to prevent you setting off in the wrong direction. Your instinct is to begin with CSVDE import, whereas I want to persuade you to master CSVDE export before you make a bulk import into Active Directory. Here is my reasoning. When you use CSVDE -i to import user accounts, the changes that you make could be difficult to reverse. For instance, you may import incorrect usernames; it may not be easy to spot the rogue users in amongst the regular accounts. In frustration, you delete existing users as well as the test accounts. By starting with Export mode, you can do no harm to Active Directory, so CSVDE -f filename.csv will help build up your understanding of the switches.

The executable CSVDE is a found in Windows Server 2003 and 2000. To see it in action, just open up a Command Prompt then type: CSVDE. As a result the executable will launch and you will see all the switches, or parameters as Microsoft call them.

CSVDE TipWhen I needed CSVDE on an XP machine, at first I could not find it. So, I connected to the admin$ share on my Windows server and copied csvde.exe from the %windir%\system32 folder, to the XP machine.

CSVDE Summary

CSVDE is an ideal program to bulk import users into Active Directory. The key feature of CSVDE is the way than it interacts with spreadsheets to import or export LDAP data. The executable is built-in to Windows Server 2003, so try it now.

See Also

 


Download your eBook:  How to use CSVDE commands - only $6.25

CSVDESave hours of frustration and buy Guy's eBook.  The extra features include: detailed instructions on how to import and export user accounts, ten new pages of worked CSVDE examples.

You get a printer friendly version with copy enabled, and no expiry date.

 

 

 *


Google

Web  This website

Review of Orion NPMGuy Recommends: Orion's Network Performance Monitor (NPM)

Orion NPM is designed for detecting network outages.

Network-centric views (screenshot) make it easy to see what's working, and what needs your attention.

Download your free trial of Orion's network performance monitor

 

Home Copyright © 1999-2010 Computer Performance LTD All rights reserved

Please report a broken link, or an error.