New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Index Template] Use index.auto_expand_replicas '0-1' #5921
Comments
@pickypg Interesting, wasn't aware of this option. At the moment we don't set it at all (I think) and use the default from ES. Do we have to change anything in this case? |
@ruflin The default value for the setting is "settings": {
"index.auto_expand_replicas": "0-1"
} As with all |
Great. It's pretty simple for us to add such settings to our config like we do here for shards: https://github.com/elastic/beats/blob/master/filebeat/filebeat.yml#L81 It would be nice if the two could be merged because I worry that people will try to set both. |
@elastic/beats After a conversation with @pickypg I'm thinking we should add this to our short config for a better getting started experience, similar as we do with shards. This means it's not hardcoded anywhere in our binary but only exists in our This means if someone just starts a beat against a 1 elasticsearch node to tests, he will have a green cluster state. As soon as someone scales up he should change this config to his own needs. Having it in our short config I would also not treat it as a breaking change as everyone that keeps the old config still has the same behaviour. If a beat of the exact same version with the config and without the config exists, the first one "wins", means writes the template. We have the same problem with number of shards and so far this didn't seem to be an issue. @graphaelli I would recommend to do the same for apm-server. |
@ruflin Thanks for the reminder, getting this in now. |
@ruflin @pickypg What happens if the user still has the setting set from testing and now deploys with a bigger cluster of N nodes (without changing the TBH I'm not convinced by: User just has to change this setting in beats when going with a bigger cluster. The main problem is not the potential race on template loading, but the user not being aware of this setting (who reads documentation?). |
@urso For yellow instead of green, yes. For the second part, not reading docs, agree. I would hope someone that goes into production would revise the config settings like shards, replicas and auto-expand but definitively will be skipped form time to time. We should probably add a note in the config file, that this should not be enabled for production clusters. |
@pickypg @graphaelli We discussed this again in the beats team sync and decided to not move forward with this as we worry about the cases where people take this into production and have a green cluster when they shouldn't. |
The Beats index / indices should consider using the
index.auto_expand_replicas
setting, set to"0-1"
in favor ofindex.number_of_replicas
set to1
(or leaving it as the default).Doing so will allow single node (e.g., dev) clusters to startup as green, which gives a better getting started experience.
The text was updated successfully, but these errors were encountered: