Examples Much of the OpenDJ Administration Guide consists of dsconfig examples with text in between. This section therefore remains short. The following example starts dsconfig in interactive, menu-driven mode on the default port of the current host. $ dsconfig -h opendj.example.com -p 4444 -D "cn=Directory Manager" -w password >>>> OpenDJ configuration console main menu What do you want to configure? 1) Access Control Handler 22) Log Publisher 2) Access Log Filtering Criteria 23) Log Retention Policy 3) Account Status Notification Handler 24) Log Rotation Policy 4) Administration Connector 25) Monitor Provider 5) Alert Handler 26) Password Generator 6) Backend 27) Password Policy 7) Backend Index 28) Password Storage Scheme 8) Backend VLV Index 29) Password Validator 9) Certificate Mapper 30) Plugin 10) Connection Handler 31) Plugin Root 11) Crypto Manager 32) Replication Domain 12) Debug Target 33) Replication Server 13) Entry Cache 34) Root DN 14) Extended Operation Handler 35) Root DSE Backend 15) External Changelog Domain 36) SASL Mechanism Handler 16) Global Configuration 37) Schema Provider 17) Group Implementation 38) Synchronization Provider 18) HTTP Authorization Mechanism 39) Trust Manager Provider 19) HTTP Endpoint 40) Virtual Attribute 20) Identity Mapper 41) Work Queue 21) Key Manager Provider q) quit Enter choice: The following example demonstrates generating a batch file that corresponds to an interactive session enabling the debug log. The example then demonstrates using a modified batch file to disable the debug log. $ dsconfig \ --hostname opendj.example.com \ --port 4444 \ --bindDN "cn=Directory Manager" \ --bindPassword password \ --commandFilePath ~/enable-debug-log.batch ... $ cat ~/enable-debug-log.batch # dsconfig session start date: 19/Oct/2011:08:52:22 +0000 # Session operation number: 1 # Operation date: 19/Oct/2011:08:55:06 +0000 dsconfig set-log-publisher-prop \ --publisher-name File-Based\ Debug\ Logger \ --set enabled:true \ --hostname opendj.example.com \ --port 4444 \ --trustStorePath /path/to/opendj/config/admin-truststore \ --bindDN cn=Directory\ Manager \ --bindPassword ****** \ --no-prompt $ cp ~/enable-debug-log.batch ~/disable-debug-log.batch $ vi ~/disable-debug-log.batch $ cat ~/disable-debug-log.batch set-log-publisher-prop \ --publisher-name File-Based\ Debug\ Logger \ --set enabled:false \ --hostname opendj.example.com \ --port 4444 \ --trustStorePath /path/to/opendj/config/admin-truststore \ --bindDN cn=Directory\ Manager \ --bindPassword password \ --no-prompt $ dsconfig --batchFilePath ~/disable-debug-log.batch --no-prompt set-log-publisher-prop --publisher-name File-Based Debug Logger --set enabled:false --hostname opendj.example.com --port 4444 --trustStorePath /path/to/opendj/config/admin-truststore --bindDN cn=Directory Manager --bindPassword password --no-prompt $ Notice that the original command file looks like a shell script with the bind password value replaced by asterisks. To pass the content as a batch file to dsconfig, strip dsconfig itself, and include the bind password for the administrative user or replace that option with an alternative, such as reading the password from a file.