I’m working with multiple instances of Elasticsearch on the same host.
It always loads the default settings when I started the service.
/etc/sysconfig/master-node-0_elasticsearch
ES_HOME=/usr/share/elasticsearch
CONF_DIR=/etc/elasticsearch/master-node-0
ES_PATH_CONF=/etc/elasticsearch/master-node-0
DATA_DIR=/var/lib/elasticsearch/10.49.113.9-master-node-0
LOG_DIR=/var/log/elasticsearch/10.49.113.9-master-node-0
PID_DIR=/var/run/elasticsearch/10.49.113.9-master-node-0
ES_JVM_OPTIONS=/etc/elasticsearch/master-node-0/jvm.options
ES_USER=elasticsearch
ES_GROUP=elasticsearch
ES_STARTUP_SLEEP_TIME=5
MAX_OPEN_FILES=65536
MAX_LOCKED_MEMORY=unlimited
MAX_MAP_COUNT=262144
MAX_THREADS=2048
/etc/elasticsearch/master-node-0/elasticsearch.yml
bootstrap.memory_lock: true
cluster.name: opendistro-cluster-preprod
cluster.routing.allocation.same_shard.host: true
discovery.zen.minimum_master_nodes: 2
discovery.zen.ping.unicast.hosts:
- 10.49.113.9
http.compression: true
http.port: ‘9200’
network.bind_host:
- local:ipv4
- site:ipv4
network.publish_host: site:ipv4
node.data: false
node.ingest: false
node.master: true
opendistro_security.audit.type: internal_elasticsearch
opendistro_security.authcz.admin_dn:
- CN=Administrator,OU=.,O=.,DC=.,DC=.,C=US
opendistro_security.check_snapshot_restore_write_privileges: true
opendistro_security.enterprise_modules_enabled: false
opendistro_security.nodes_dn:
- CN=10.49.,OU=.,O=.,DC=.,DC=.*,C=US
opendistro_security.restapi.roles_enabled:
- all_access
opendistro_security.ssl.http.enabled: true
opendistro_security.ssl.http.pemcert_filepath: 10.49.113.9.pem
opendistro_security.ssl.http.pemkey_filepath: 10.49.113.9.key
opendistro_security.ssl.http.pemkey_password: compass
opendistro_security.ssl.http.pemtrustedcas_filepath: root-ca.pem
opendistro_security.ssl.transport.enforce_hostname_verification: false
opendistro_security.ssl.transport.pemcert_filepath: 10.49.113.9.pem
opendistro_security.ssl.transport.pemkey_filepath: 10.49.113.9.key
opendistro_security.ssl.transport.pemkey_password: compass
opendistro_security.ssl.transport.pemtrustedcas_filepath: root-ca.pem
opendistro_security.ssl.transport.resolve_hostname: false
node.name: 10.49.113.9-master-node-0
path.conf: /etc/elasticsearch/master-node-0
path.data: /var/lib/elasticsearch/10.49.113.9-master-node-0
path.logs: /var/log/elasticsearch/10.49.113.9-master-node-0
action.auto_create_index: true
/etc/elasticsearch/master-node-0/jvm.options
-Xms31g
-Xmx31g
-XX:+UseConcMarkSweepGC
-XX:CMSInitiatingOccupancyFraction=75
-XX:+UseCMSInitiatingOccupancyOnly
-XX:+AlwaysPreTouch
-server
-Djava.awt.headless=true
-Dfile.encoding=UTF-8
-Djna.nosys=true
-Djdk.io.permissionsUseCanonicalPath=true
-Dio.netty.noUnsafe=true
-Dio.netty.noKeySetOptimization=true
-Dio.netty.recycler.maxCapacityPerThread=0
-Dlog4j.shutdownHookEnabled=false
-Dlog4j2.disable.jmx=true
-Dlog4j.skipJansi=true
-XX:+HeapDumpOnOutOfMemoryError
The Elasticsearch process with options
495 30799 1 3 04:25 ? 00:00:37 /usr/bin/java -Xms1g -Xmx1g -XX:+UseConcMarkSweepGC -XX:CMSInitiatingOccupancyFraction=75 -XX:+UseCMSInitiatingOccupancyOnly -Des.networkaddress.cache.ttl=60 -Des.networkaddress.cache.negative.ttl=10 -XX:+AlwaysPreTouch -Xss1m -Djava.awt.headless=true -Dfile.encoding=UTF-8 -Djna.nosys=true -XX:-OmitStackTraceInFastThrow -Dio.netty.noUnsafe=true -Dio.netty.noKeySetOptimization=true -Dio.netty.recycler.maxCapacityPerThread=0 -Dlog4j.shutdownHookEnabled=false -Dlog4j2.disable.jmx=true -Djava.io.tmpdir=/tmp/elasticsearch-5890626230362802382 -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/var/lib/elasticsearch -XX:ErrorFile=/var/log/elasticsearch/hs_err_pid%p.log -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintTenuringDistribution -XX:+PrintGCApplicationStoppedTime -Xloggc:/var/log/elasticsearch/gc.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=32 -XX:GCLogFileSize=64m -Dclk.tck=100 -Djdk.attach.allowAttachSelf=true -Djava.security.policy=file:///usr/share/elasticsearch/plugins/opendistro_performance_analyzer/pa_config/es_security.policy -Des.path.home=/usr/share/elasticsearch -Des.path.conf=/etc/elasticsearch -Des.distribution.flavor=oss -Des.distribution.type=rpm -cp /usr/share/elasticsearch/lib/* org.elasticsearch.bootstrap.Elasticsearch -p /var/run/elasticsearch/10.49.113.9-master-node-0/master-node-0_elasticsearch.pid -d
You can see the invalid options in BOLD.