Skip to content

Node-level cluster.max_shards_per_node has no effect #42137

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

Closed
DaveCTurner opened this issue May 14, 2019 · 5 comments
Closed

Node-level cluster.max_shards_per_node has no effect #42137

DaveCTurner opened this issue May 14, 2019 · 5 comments
Labels
>bug :Data Management/Indices APIs APIs to create and manage indices and templates

Comments

@DaveCTurner
Copy link
Contributor

We only look at the value of cluster.max_shards_per_node taken from the cluster metadata which, if unset, defaults to 1000:

int maxShardsPerNode = MetaData.SETTING_CLUSTER_MAX_SHARDS_PER_NODE.get(theseSettings);

This means that setting cluster.max_shards_per_node in elasticsearch.yml has no effect, but most other dynamic settings can also be set statically like this, so this caught me by surprise.

Relates #34021
Relates https://discuss.elastic.co/t/180785

@DaveCTurner DaveCTurner added >bug :Data Management/Indices APIs APIs to create and manage indices and templates labels May 14, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-features

@jasontedor
Copy link
Member

Duplicates #40803

@verygreen
Copy link

So #40803 was closed because original report was about some non-default distro or some such.

But THIS ticket is about stock package you get from elastic theselves. So should we reopen this ticket instead? Open another one?

@jasontedor any advice? I jsut hit this problem on this package from the official repo:

# rpm -qi elasticsearch-7.3.2-1.x86_64
Name        : elasticsearch
Epoch       : 0
Version     : 7.3.2
Release     : 1
Architecture: x86_64
Install Date: Thu 12 Sep 2019 03:42:55 PM EDT
Group       : Application/Internet
Size        : 480100569
License     : Elastic License
Signature   : RSA/SHA512, Fri 06 Sep 2019 01:02:00 PM EDT, Key ID d27d666cd88e42b4
Source RPM  : elasticsearch-7.3.2-1-src.rpm
Build Date  : Fri 06 Sep 2019 10:55:26 AM EDT
Build Host  : packer-virtualbox-iso-1559162487
Relocations : /usr 
Packager    : Elasticsearch
Vendor      : Elasticsearch
URL         : https://www.elastic.co/
Summary     : Distributed RESTful search engine built for the cloud

@DaveCTurner
Copy link
Contributor Author

@verygreen I think you're mistaken: #40803 is still open, and while it remains unresolved the workaround mentioned there should still work for you.

@verygreen
Copy link

Hm, I guess I was confused by the (currently) last comment that says closed, but that is a different ticket. Coupled with the previous one pointing at unsupported distro. Oh well, sorry about the false alarm then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug :Data Management/Indices APIs APIs to create and manage indices and templates
Projects
None yet
Development

No branches or pull requests

4 participants