|
| 1 | +[role="xpack"] |
| 2 | +[testenv="gold"] |
| 3 | +[[watcher-troubleshooting]] |
| 4 | +== Troubleshooting {watcher} |
| 5 | +[subs="attributes"] |
| 6 | +++++ |
| 7 | +<titleabbrev>Troubleshooting</titleabbrev> |
| 8 | +++++ |
| 9 | + |
| 10 | +[discrete] |
| 11 | +=== Dynamic mapping error when trying to add a watch |
| 12 | + |
| 13 | +If you get the _Dynamic Mapping is Disabled_ error when you try to add a watch, |
| 14 | +verify that the index mappings for the `.watches` index are available. You can |
| 15 | +do that by submitting the following request: |
| 16 | + |
| 17 | +[source,js] |
| 18 | +-------------------------------------------------- |
| 19 | +GET .watches/_mapping |
| 20 | +-------------------------------------------------- |
| 21 | +// CONSOLE |
| 22 | + |
| 23 | +//When testing is enabled, test [setup:my_active_watch] |
| 24 | + |
| 25 | +If the index mappings are missing, follow these steps to restore the correct |
| 26 | +mappings: |
| 27 | + |
| 28 | +. Stop the Elasticsearch node. |
| 29 | +. Add `xpack.watcher.index.rest.direct_access : true` to `elasticsearch.yml`. |
| 30 | +. Restart the Elasticsearch node. |
| 31 | +. Delete the `.watches` index: |
| 32 | ++ |
| 33 | +-- |
| 34 | +[source,js] |
| 35 | +-------------------------------------------------- |
| 36 | +DELETE .watches |
| 37 | +-------------------------------------------------- |
| 38 | +// CONSOLE |
| 39 | + |
| 40 | +//When testing is enabled, test[skip:index deletion] |
| 41 | +-- |
| 42 | +. Disable direct access to the `.watches` index: |
| 43 | +.. Stop the Elasticsearch node. |
| 44 | +.. Remove `xpack.watcher.index.rest.direct_access : true` from `elasticsearch.yml`. |
| 45 | +.. Restart the Elasticsearch node. |
| 46 | + |
| 47 | +[discrete] |
| 48 | +=== Unable to send email |
| 49 | + |
| 50 | +If you get an authentication error indicating that you need to continue the |
| 51 | +sign-in process from a web browser when Watcher attempts to send email, you need |
| 52 | +to configure Gmail to |
| 53 | +https://support.google.com/accounts/answer/6010255?hl=en[Allow Less Secure Apps to access your account]. |
| 54 | + |
| 55 | +If you have two-step verification enabled for your email account, you must |
| 56 | +generate and use an App Specific password to send email from {watcher}. For more |
| 57 | +information, see: |
| 58 | + |
| 59 | +- Gmail: https://support.google.com/accounts/answer/185833?hl=en[Sign in using App Passwords] |
| 60 | +- Outlook.com: http://windows.microsoft.com/en-us/windows/app-passwords-two-step-verification[App passwords and two-step verification] |
| 61 | + |
| 62 | +[discrete] |
| 63 | +=== {watcher} not responsive |
| 64 | + |
| 65 | +Keep in mind that there's no built-in validation of scripts that you add to a |
| 66 | +watch. Buggy or deliberately malicious scripts can negatively impact {watcher} |
| 67 | +performance. For example, if you add multiple watches with buggy script |
| 68 | +conditions in a short period of time, {watcher} might be temporarily unable to |
| 69 | +process watches until the bad watches time out. |
0 commit comments