1 | Input data | Input | Char(*) |
2 | Length of input data | Input | Binary(4) |
3 | Format name | Input | Char(8) |
4 | Error code | I/O | Char(*) |
The Import LDIF File (QgldImportLdif) API imports directory server data from a Lightweight Directory Access Protocol Data Interchange Format (LDIF) file.
The IBM Directory Server must be stopped to use this API. To stop the server, use the End TCP/IP Server (ENDTCPSVR SVR(*DIRSRV)) command.
Input data required to identify the LDIF file and the administrator name and password. The content and format of this structure are determined by the format name. See Format of Input Data for a description of these formats.
The length of the input data structure.
The content and format of the input data. The possible format name follows:
LDIF0100 | Import LDIF file |
LDIF0200 | Import LDIF file with options |
See Format of Input Data for a description of this format.
The structure in which to return error information. For the format of the structure, see Error code parameter.
For details about the format of the input data, see the following section. For details about the fields in each format, see Field Descriptions.
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | BINARY(4) | Offset to LDIF file |
4 | 4 | BINARY(4) | Length of LDIF file |
8 | 8 | BINARY(4) | Offset to administrator DN |
12 | C | BINARY(4) | Length of administrator DN |
16 | 10 | BINARY(4) | Offset to administrator password |
20 | 14 | BINARY(4) | Length of administrator password |
CHAR(*) | LDIF file | ||
CHAR(*) | Administrator DN | ||
CHAR(*) | Administrator password |
Offset | Type | Field | |
---|---|---|---|
Dec | Hex | ||
0 | 0 | BINARY(4) | Offset to LDIF file |
4 | 4 | BINARY(4) | Length of LDIF file |
8 | 8 | BINARY(4) | Offset to administrator DN |
12 | C | BINARY(4) | Length of administrator DN |
16 | 10 | BINARY(4) | Offset to administrator password |
20 | 14 | BINARY(4) | Length of administrator password |
24 | 18 | BINARY(4) | Level indicator |
Additional fields if level indicator is equal to 1 or greater: | |||
28 | 1C | BINARY(4) | Replicate imported data |
Variable length string fields: | |||
CHAR(*) | LDIF file | ||
CHAR(*) | Administrator DN | ||
CHAR(*) | Administrator password |
Additional fields indicator. Additional fields supplied for a format. See the format descriptions for possible uses and values of this field.
Administrator DN. The distinguished name of the server administrator. This field is specified in UTF-16 (CCSID 13488).
Administrator password. The password for the server administrator. This field is specified in UTF-16 (CCSID 13488).
LDIF file. The integrated file system path name of the LDIF file to be used. This field is specified in UTF-16 (CCSID 13488).
Length of administrator DN. The length, in UTF-16 (CCSID 13488) characters, of the administrator DN field.
Length of administrator password. The length, in UTF-16 (CCSID 13488) characters, of the administrator password field.
Length of LDIF file. The length, in UTF-16 (CCSID 13488) characters, of the LDIF file field.
Level indicator. The level indicator of the data supplied for a format. See the format descriptions for possible uses and values of this field.
Offset to administrator DN. The offset, in bytes, from the start of the input data to the administrator DN field.
Offset to administrator password. The offset, in bytes, from the start of the input data to the administrator password field.
Offset to LDIF file. The offset, in bytes, from the start of the input data to the LDIF file field.
Replicate imported data. Indicates whether imported data should be replicated to replica servers. This option could be used, for example, when initializing an additional master server so that it does not attempt to replicate data to servers already containing this data. If format LDIF0100 is used, imported data is replicated. The following values may be specified Whether the directory server will replicate imported data. The following values may be specified:
0 | Imported data is not replicated. |
1 | Imported data is replicated. The value 1 can only be specified if a subtree DN is specified. |
Message ID | Error Message Text |
---|---|
GLD0125 E | IBM Directory Server failed for reason code &4. |
GLD0202 E | Administrator DN or password not correct. |
GLD0213 E | Error opening or creating file. |
GLD0215 E | Server has not been configured. |
GLD0218 E | *ALLOBJ and *IOSYSCFG special authorities required. |
GLD0225 E | &1 items added to directory, &2 items not added. |
GLD0226 E | LDAP server is read-only. |
Top | UNIX-Type APIs | APIs by category |