Problem configuring Gmail account for watcher

I'm following the info at Configuring Watcher to Send Email | Elasticsearch Watcher [2.4] | Elastic

Placing in elasticsearch.yml the following:

watcher.actions.email.service.account:
    gmail_account:
        profile: gmail
        smtp:
            auth: true
            starttls.enable: true
            host: smtp.gmail.com
            port: 587
            user: <username>
            password: <password>

trying with username in both the form xyz@gmail.com and just xyz.
The gmail account is configured to "Allow Less Secure Apps" and two-step verification is off.

But when I restart the Elasticsearch service, errors occur:

org.elasticsearch.bootstrap.StartupException: java.lang.IllegalArgumentException: unknown setting > [watcher.actions.email.service.account.gmail_account.smtp.starttls.enable] please check that any required plugins are installed, or check the breaking changes documentation for removed settings
at org.elasticsearch.common.settings.AbstractScopedSettings.validate(AbstractScopedSettings.java:344) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.common.settings.AbstractScopedSettings.validate(AbstractScopedSettings.java:308) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.common.settings.AbstractScopedSettings.validate(AbstractScopedSettings.java:282) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.common.settings.SettingsModule.(SettingsModule.java:135) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.node.Node.(Node.java:339) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.node.Node.(Node.java:252) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Bootstrap$5.(Bootstrap.java:213) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:213) ~[elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:326) [elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:136) [elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:127) [elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86) [elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:124) [elasticsearch-cli-6.3.0.jar:6.3.0]
at org.elasticsearch.cli.Command.main(Command.java:90) [elasticsearch-cli-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:93) [elasticsearch-6.3.0.jar:6.3.0]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:86) [elasticsearch-6.3.0.jar:6.3.0]

repeated for the other watcher.actions.email.service.account.gmail_account.* fields.

When I tried with an Exchange server account instead, using the info at Configuring Watcher to Send Email | Elasticsearch Watcher [2.4] | Elastic, that worked, but I haven't been able to get the Gmail configuration to work.

Realized my error. I must have originally copy-pasted the Gmail configuration settings from an older version of the docs at Configuring Watcher to Send Email | Elasticsearch Watcher [2.4] | Elastic

watcher.actions.email.service.account:

should now be:

xpack.notification.email.account:

It seems to be working now.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.