Setting Up a Mail Session for the Confluence Distribution

The simplest way to set up a mail server through the Confluence Administration console. See Configuring a Server for Outgoing Mail.

If you want to add different options or parameters you can also set up a mail session for the Confluence distribution. In the example below we'll set up Gmail.

To set up a mail session for the Confluence distribution:

  1. Stop Confluence.
  2. Move (don't copy) mail-x.x.x.jar from <confluence-install>/confluence/WEB-INF/lib to <confluence-install>/lib.
    Note: where x.x.x. represents the version numbers on the jar files in your installation. 
    Do not leave a renamed backup of the jar files in /confluence/WEB-INF/lib. Even with a different file name, the files will still be loaded as long as it remains in the directory
  3. Add the following to your server.xml file found in <confluence-install>/conf/ (add it just before the </Context> tag):

    For Confluence 3.5.x
  4. Restart Confluence.
  5. Choose the cog icon , then choose General Configuration under Confluence Administration

  6. Choose Mail Servers.
  7. Choose either Edit an existing configuration, or Add a new SMTP mail server.
  8. Edit the server settings as necessary, and set the JNDI Location as:


    Note that the JNDI Location is case sensitive and must match the resource name specified in server.xml.

  9. Save your changes and send a test email.

Was this helpful?

Thanks for your feedback!

Why was this unhelpful?

Have a question about this article?

See questions about this article

Powered by Confluence and Scroll Viewport