1. To configure a simple mail server, use the dsconfig command.
    $ bin/dsconfig create-external-server --server-name smtp1 \
      --type smtp --set server-host-name:smtp.example.com
  2. To configure an SMTP server, use the dsconfig command.
    $ bin/dsconfig set-global-configuration-prop \
      --set smtp-server:smtp1

    This command adds the server to the global list of mail servers that Directory Server can use.