To import the file described in "Input File" sing the mapping file described in "Mapping File", you can use dsimport with the following arguments:
# dsimport -h hostname -D cn=admin,o=xyz,c=us -w secret -m mapping.file -f EXAMPLE -t People input.file |
where:
hostname is the name of the host that holds the directory data store
cn=admin,o=xyz,c=us is by default the distinguished name of the directory administrator
secret represents the password of the directory administarator
mapping.file contains the mapping for the input information
EXAMPLE is the front-end specified in the mapping file
People is the table specified in the mapping file
input.file contains the input information
It is not strictly necessary to specify the DN and password of the administrator on the command line. If you omit these parameters, dsimport will read them from the dsserv.conf file. The advantage is that the DN and password of the administrator will not be displayed by the ps command.
After running this command, the following message is displayed:
Lines read: 9, processed: 8 Entries: added 10, modified 0, deleted 0, errors 0 |
The line count includes blank lines. The number of entries created is greater than the number of lines in the file because the dsimport command automatically creates the root entry, in this example o=xyz, c=US.