- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我试图在Elasticsearch节点中启用安全性功能,但是每当我打开“xpack.security.enabled:true”时,我的Elasticsearch根本不会启动。我该如何解决?
这是我在两个Elasticsearch节点上的配置:
节点1:
# ======================== Elasticsearch Configuration =========================
#
# NOTE: Elasticsearch comes with reasonable defaults for most settings.
# Before you set out to tweak and tune the configuration, make sure you
# understand what are you trying to accomplish and the consequences.
#
# The primary way of configuring a node is via this file. This template lists
# the most important settings you may want to configure for a production cluster.
#
# Please consult the documentation for further information on configuration options:
# https://www.elastic.co/guide/en/elasticsearch/reference/index.html
#
# ---------------------------------- Cluster -----------------------------------
#
# Use a descriptive name for your cluster:
#
cluster.name: "elastic-a"
#
# ------------------------------------ Node ------------------------------------
#
# Use a descriptive name for the node:
#
node.name: "elastic-master"
node.master: true
node.data: true
#
# Add custom attributes to the node:
#
#node.attr.rack: r1
#
# ----------------------------------- Paths ------------------------------------
#
# Path to directory where to store the data (separate multiple locations by comma):
#
path.data: /var/lib/elasticsearch
#
# Path to log files:
#
path.logs: /var/log/elasticsearch
#
# ----------------------------------- Memory -----------------------------------
#
# Lock the memory on startup:
#
#bootstrap.memory_lock: true
#
# Make sure that the heap size is set to about half the memory available
# on the system and that the owner of the process is allowed to use this
# limit.
#
# Elasticsearch performs poorly when the system is swapping the memory.
#
# ---------------------------------- Network -----------------------------------
#
# Set the bind address to a specific IP (IPv4 or IPv6):
#
network.host: 192.168.143.30
#http.host: 0.0.0.0
#
# Set a custom port for HTTP:
#
#http.port: 9200
#
# For more information, consult the network module documentation.
#
# --------------------------------- Discovery ----------------------------------
#
# Pass an initial list of hosts to perform discovery when this node is started:
# The default list of hosts is ["127.0.0.1", "[::1]"]
#
discovery.seed_hosts: ["192.168.143.30", "192.168.143.23"]
#
# Bootstrap the cluster using an initial set of master-eligible nodes:
#
cluster.initial_master_nodes: ["elastic-master","elastic-slave"]
#
# For more information, consult the discovery and cluster formation module documentation.
#
# ---------------------------------- Gateway -----------------------------------
#
# Block initial recovery after a full cluster restart until N nodes are started:
#
#gateway.recover_after_nodes: 3
#
# For more information, consult the gateway module documentation.
#
# ---------------------------------- Various -----------------------------------
#
# Require explicit names when deleting indices:
#
#action.destructive_requires_name: true
action.auto_create_index: .monitoring*,.watches,.triggered_watches,.watcher-history*,.ml*
xpack.security.enabled: true
# ======================== Elasticsearch Configuration =========================
#
# NOTE: Elasticsearch comes with reasonable defaults for most settings.
# Before you set out to tweak and tune the configuration, make sure you
# understand what are you trying to accomplish and the consequences.
#
# The primary way of configuring a node is via this file. This template lists
# the most important settings you may want to configure for a production cluster.
#
# Please consult the documentation for further information on configuration options:
# https://www.elastic.co/guide/en/elasticsearch/reference/index.html
#
# ---------------------------------- Cluster -----------------------------------
#
# Use a descriptive name for your cluster:
#
cluster.name: "elastic-a"
#
# ------------------------------------ Node ------------------------------------
#
# Use a descriptive name for the node:
#
node.name: "elastic-slave"
node.master: true
node.data: true
#
# Add custom attributes to the node:
#
#node.attr.rack: r1
#
# ----------------------------------- Paths ------------------------------------
#
# Path to directory where to store the data (separate multiple locations by comma):
#
path.data: /var/lib/elasticsearch
#
# Path to log files:
#
path.logs: /var/log/elasticsearch
#
# ----------------------------------- Memory -----------------------------------
#
# Lock the memory on startup:
#
#bootstrap.memory_lock: true
#
# Make sure that the heap size is set to about half the memory available
# on the system and that the owner of the process is allowed to use this
# limit.
#
# Elasticsearch performs poorly when the system is swapping the memory.
#
# ---------------------------------- Network -----------------------------------
#
# Set the bind address to a specific IP (IPv4 or IPv6):
#
network.host: 192.168.143.23
#http.host: 0.0.0.0
#
# Set a custom port for HTTP:
#
#http.port: 9200
#
# For more information, consult the network module documentation.
#
# --------------------------------- Discovery ----------------------------------
#
# Pass an initial list of hosts to perform discovery when this node is started:
# The default list of hosts is ["127.0.0.1", "[::1]"]
#
discovery.seed_hosts: ["192.168.143.30", "192.168.143.23"]
#
# Bootstrap the cluster using an initial set of master-eligible nodes:
#
cluster.initial_master_nodes: ["elastic-master","elastic-slave"]
#
# For more information, consult the discovery and cluster formation module documentation.
#
# ---------------------------------- Gateway -----------------------------------
#
# Block initial recovery after a full cluster restart until N nodes are started:
#
#gateway.recover_after_nodes: 3
#
# For more information, consult the gateway module documentation.
#
# ---------------------------------- Various -----------------------------------
#
# Require explicit names when deleting indices:
#
#action.destructive_requires_name: true
action.auto_create_index: .monitoring*,.watches,.triggered_watches,.watcher-history*,.ml*
xpack.security.enabled: true
Oct 21 12:24:51 elastic-master systemd[1]: Starting Elasticsearch...
Oct 21 12:24:52 elastic-master elasticsearch[18296]: OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","elasticsearch","admin"],"pid":781,"message":"Unable to revive connection: http://192.168.143.30:9200/"}
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","elasticsearch","admin"],"pid":781,"message":"No living connections"}
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","elasticsearch","admin"],"pid":781,"message":"Unable to revive connection: http://192.168.143.30:9200/"}
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","elasticsearch","admin"],"pid":781,"message":"No living connections"}
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","elasticsearch","data"],"pid":781,"message":"Unable to revive connection: http://192.168.143.30:9200/"}
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","elasticsearch","data"],"pid":781,"message":"No living connections"}
Oct 21 12:24:53 elastic-master kibana[781]: {"type":"log","@timestamp":"2020-10-21T08:54:53Z","tags":["warning","plugins","licensing"],"pid":781,"message":"License information could not be obtained from Elasticsearch for the [data] cluster. Error: No Living connections"}
Oct 21 12:24:54 elastic-master elasticsearch[18296]: [2020-10-21T12:24:54,557][INFO ][o.e.e.NodeEnvironment ] [elastic-master] using [1] data paths, mounts [[/ (rootfs)]], net usable_space [32.3gb], net total_space [43.9gb], types [rootfs]
Oct 21 12:24:54 elastic-master elasticsearch[18296]: [2020-10-21T12:24:54,561][INFO ][o.e.e.NodeEnvironment ] [elastic-master] heap size [989.8mb], compressed ordinary object pointers [true]
Oct 21 12:24:54 elastic-master elasticsearch[18296]: [2020-10-21T12:24:54,612][INFO ][o.e.n.Node ] [elastic-master] node name [elastic-master], node ID [1lAXp_eJRL--r0o2Uq4P1Q], cluster name [elastic-a]
Oct 21 12:24:54 elastic-master elasticsearch[18296]: [2020-10-21T12:24:54,613][INFO ][o.e.n.Node ] [elastic-master] version[7.5.0], pid[18296], build[default/rpm/e9ccaed468e2fac2275a3761849cbee64b39519f/2019-11-26T01:06:52.518245Z], OS[Linux/3.10.0-1127.19.1.el7.x86_64/amd64], JVM[AdoptOpenJDK/OpenJDK 64-Bit Server VM/13.0.1/13.0.1+9]
Oct 21 12:24:54 elastic-master elasticsearch[18296]: [2020-10-21T12:24:54,613][INFO ][o.e.n.Node ] [elastic-master] JVM home [/usr/share/elasticsearch/jdk]
Oct 21 12:24:54 elastic-master elasticsearch[18296]: [2020-10-21T12:24:54,613][INFO ][o.e.n.Node ] [elastic-master] JVM arguments [-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, -Dio.netty.allocator.numDirectArenas=0, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -Djava.locale.providers=COMPAT, -Xms1g, -Xmx1g, -XX:+UseConcMarkSweepGC, -XX:CMSInitiatingOccupancyFraction=75, -XX:+UseCMSInitiatingOccupancyOnly, -Djava.io.tmpdir=/tmp/elasticsearch-1946051170077590643, -XX:+HeapDumpOnOutOfMemoryError, -XX:HeapDumpPath=/var/lib/elasticsearch, -XX:ErrorFile=/var/log/elasticsearch/hs_err_pid%p.log, -Xlog:gc*,gc+age=trace,safepoint:file=/var/log/elasticsearch/gc.log:utctime,pid,tags:filecount=32,filesize=64m, -XX:MaxDirectMemorySize=536870912, -Des.path.home=/usr/share/elasticsearch, -Des.path.conf=/etc/elasticsearch, -Des.distribution.flavor=default, -Des.distribution.type=rpm, -Des.bundled_jdk=true]
elastic-master elasticsearch[18296]: [2020-10-21T12:24:55,042][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [elastic-master] uncaught exception in thread [main]
elastic-master elasticsearch[18296]: org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: failed to load plugin class [org.elasticsearch.xpack.core.XPackPlugin]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:163) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:150) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:125) ~[elasticsearch-cli-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.cli.Command.main(Command.java:90) ~[elasticsearch-cli-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:115) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:92) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: Caused by: java.lang.IllegalStateException: failed to load plugin class [org.elasticsearch.xpack.core.XPackPlugin]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:614) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundle(PluginsService.java:556) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:471) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.<init>(PluginsService.java:163) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:309) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:253) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:349) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:159) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: ... 6 more
elastic-master elasticsearch[18296]: Caused by: java.lang.reflect.InvocationTargetException
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:500) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstance(Constructor.java:481) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:605) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundle(PluginsService.java:556) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:471) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.<init>(PluginsService.java:163) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:309) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:253) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:349) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:159) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: ... 6 more
elastic-master elasticsearch[18296]: Caused by: org.elasticsearch.ElasticsearchSecurityException: failed to load SSL configuration [xpack.security.transport.ssl]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.loadConfiguration(SSLService.java:449) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.loadSSLConfigurations(SSLService.java:430) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.<init>(SSLService.java:121) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.XPackPlugin.<init>(XPackPlugin.java:142) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:500) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstance(Constructor.java:481) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:605) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundle(PluginsService.java:556) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:471) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.<init>(PluginsService.java:163) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:309) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:253) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:349) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:159) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: ... 6 more
elastic-master elasticsearch[18296]: Caused by: org.elasticsearch.ElasticsearchException: failed to initialize SSL TrustManager - not permitted to read truststore file [/etc/elasticsearch/certs/elastic-certificates.p12]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.TrustConfig.unreadableTrustConfigFile(TrustConfig.java:121) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.StoreTrustConfig.createTrustManager(StoreTrustConfig.java:70) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.createSslContext(SSLService.java:384) ~[?:?]
elastic-master elasticsearch[18296]: at java.util.HashMap.computeIfAbsent(HashMap.java:1138) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.loadConfiguration(SSLService.java:446) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.loadSSLConfigurations(SSLService.java:430) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.<init>(SSLService.java:121) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.XPackPlugin.<init>(XPackPlugin.java:142) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:500) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstance(Constructor.java:481) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:605) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundle(PluginsService.java:556) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:471) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.<init>(PluginsService.java:163) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:309) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:253) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:349) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:159) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: ... 6 more
elastic-master elasticsearch[18296]: Caused by: java.nio.file.AccessDeniedException: /etc/elasticsearch/certs/elastic-certificates.p12
elastic-master elasticsearch[18296]: at sun.nio.fs.UnixException.translateToIOException(UnixException.java:90) ~[?:?]
elastic-master elasticsearch[18296]: at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111) ~[?:?]
elastic-master elasticsearch[18296]: at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:116) ~[?:?]
elastic-master elasticsearch[18296]: at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:219) ~[?:?]
elastic-master elasticsearch[18296]: at java.nio.file.Files.newByteChannel(Files.java:374) ~[?:?]
elastic-master elasticsearch[18296]: at java.nio.file.Files.newByteChannel(Files.java:425) ~[?:?]
elastic-master elasticsearch[18296]: at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:420) ~[?:?]
elastic-master elasticsearch[18296]: at java.nio.file.Files.newInputStream(Files.java:159) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.TrustConfig.getStore(TrustConfig.java:95) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.StoreTrustConfig.createTrustManager(StoreTrustConfig.java:65) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.createSslContext(SSLService.java:384) ~[?:?]
elastic-master elasticsearch[18296]: at java.util.HashMap.computeIfAbsent(HashMap.java:1138) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.loadConfiguration(SSLService.java:446) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.loadSSLConfigurations(SSLService.java:430) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.ssl.SSLService.<init>(SSLService.java:121) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.xpack.core.XPackPlugin.<init>(XPackPlugin.java:142) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:?]
elastic-master elasticsearch[18296]: at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:500) ~[?:?]
elastic-master elasticsearch[18296]: at java.lang.reflect.Constructor.newInstance(Constructor.java:481) ~[?:?]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:605) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundle(PluginsService.java:556) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.loadBundles(PluginsService.java:471) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.plugins.PluginsService.<init>(PluginsService.java:163) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:309) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.node.Node.<init>(Node.java:253) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:221) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:349) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:159) ~[elasticsearch-7.5.0.jar:7.5.0]
elastic-master elasticsearch[18296]: ... 6 more
elastic-master systemd[1]: elasticsearch.service: main process exited, code=exited, status=1/FAILURE
elastic-master systemd[1]: Failed to start Elasticsearch.
elastic-master systemd[1]: Unit elasticsearch.service entered failed state.
elastic-master systemd[1]: elasticsearch.service failed.
elastic-master polkitd[814]: Unregistered Authentication Agent for unix-process:18290:7813320 (system bus name :1.429, object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale en_US.UTF-8) (disconnected from bus)
最佳答案
如果您启用安全性,则必须强制节点通过SSL相互通信,即您需要将节点配置为encrypt communications between them。因此,您需要执行一些步骤:
步骤1:Generate a node certificate
在此步骤中,有两个选项:
A. 如果您没有任何根证书颁发机构来签名证书,则可以使用bin/elasticsearch-certutil ca
创建一个证书颁发机构(按照here解释的步骤进行操作)。您将获得以PKCS#12编码的证书,其中包含根CA证书,节点证书和私钥。
B. 如果您的组织具有根证书颁发机构(Digicert等),则可以create a CSR(证书签名请求)提交到根CA。通常,您将获得以PKCS#7编码的证书。 PS:让我们知道这是否是您要走的路,因为还有更多步骤将其转换为PKCS#12。
请注意,出于测试目的,您绝对可以在两个节点上使用相同的证书,即您不需要为每个节点生成一个证书。
步骤2:Modify your configuration
获得节点证书后(通过选项A或B),可以通过在elasticsearch.yml
文件中添加以下内容来修改两个节点上的配置:
# enable security
xpack.security.enabled: true
# make sure the nodes talk in SSL to each other
xpack.security.transport.ssl.enabled: true
xpack.security.transport.ssl.keystore.path: certs/mynode.p12
xpack.security.transport.ssl.truststore.path: certs/mynode.p12
之后,您可以重新启动群集,因为它们现在可以使用SSL相互通信。
关于elasticsearch - 在Elasticsearch中具有两个节点的集群中启用安全性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/64426911/
由于 PostgreSQL 人员选择的术语不当,这会让一些人感到困惑,但请耐心等待... 我们需要能够支持多个 PostgreSQL (PG) 集群,并将它们集群在多个服务器上,例如使用repmgr.
Hadoop会跑很多jobs,从Hbase读取数据,写数据到数据库。假设我有 100 个节点,那么有两种方法可以构建我的 Hadoop/Hbase集群: 100节点hadoop&hbase集群(1个b
在kafka中,我们能创建多种类型的集群,一般如下: 单节点——单个broker集群 单节点——多broker集群 多结点——多broker集群 kafka集群中主要有五个组件: Topic:主题主要
我想在两台机器上运行我的 MPI 程序,一台是 ubuntu 18.04,另一台是 Windows 10。是否可以使用不同的操作系统组成一个集群? (我正在使用 MPICH) 如果可能,怎么做?我在网
简介: 更新负载平衡集群中的节点的最佳实践是什么? 我们在 ha 代理负载均衡器后面使用 RabbitMQ 集群来支持我们的客户端轻松集群,as suggested in the RabbitMQ d
我正在尝试创建一个图表,我明确指定了许多节点的等级并指定了集群。以下代码生成我想要的图形类型: digraph { rankdir=LR subgraph cluster0 {
我正在尝试在 RABBITMQ 上进行集群。我添加了 2 个节点,但无法添加第 3 个节点。我已经聚集了 rabbit@node1 和 rabbit@node2。现在我正在尝试将 rabbit@nod
我在 MS Azure 的生产环境中启用了一个双集群多区域 HA。 我被要求重用同一个集群来使用微服务管理几个新项目。 这里的最佳做法是什么?我应该为每个应用程序创建一个集群吗?将不同集群中的每个项目
我正在尝试 flex 搜索,并且很难在具有3个 flex 搜索实例的单台计算机上创建集群。我对实例进行了以下更改: 在所有实例上更改了群集名称{cluster.name:es-stack} 在所有实例
我想创建一个redis集群,仅将特定的redis主机作为主服务器和从服务器。另外,我想自己指定哪个主机应该是哪个主机的副本。 目前,cluster-create command当在任何一个 Redis
我计划在具有负载平衡的集群中设置 Magento,那么是否可以让两个 Magento 安装指向同一个数据库? 如果可能的话 - 我应该如何配置这些服务器的基本 URL?服务器应该具有相同的名称吗? 最
我目前正在计划一个 Web 应用程序,我想计划它最终在集群上运行。 集群将由一个 php web 集群和一个 mysql 集群以及一个独立的存储单元组成(也许是一个集群,我真的不知道它是如何工作的:s
我已经安装了 elasticsearch 2.2.3 并在 2 个节点的集群中配置 节点 1 (elasticsearch.yml) cluster.name: my-cluster node.nam
我正在寻找现有的中间件解决方案,以解决服务集群/分布方面的问题,以实现负载平衡和可用性。我正在考虑基于消息传递系统(更具体地说,JMS)为此构建自己的基础设施。但是,如果可能的话,我宁愿使用已经存在的
在 Hadoop 集群中,数据是自动跨数据节点复制还是必须编程? 如果必须编程,那我该怎么做呢? 最佳答案 dfs.replication 的默认值为 3。这存在于您的 hdfs.site.xml 中
我已经设置了一个具有 1 个主节点和 2 个从节点的 redis 集群,哨兵在所有 3 个节点上运行。 在此设置之前,我的应用程序指向运行 Redis 实例的单个节点。 集群搭建完成后,我的应用应该指
所以,我正在设计一个具有多个 redis 实例的分布式系统来分解大量的流式写入,但发现很难清楚地了解事情是如何工作的。 从我读到的内容来看,正确配置的集群似乎会自动对“错误实例”上的请求进行分片和重定
我有一个关于redis集群架构的问题。 我正在设置一个 Redis 集群,并遵循基本建议:3 硕士3个奴隶 有什么方法可以在 Amazon LB、HAProxy、Nginx 等负载均衡器后面配置此集群
那么集群背后的想法是什么? 您有多台机器具有相同的数据库副本,您在其中传播读/写?这是正确的吗? 这个想法如何运作?当我进行选择查询时,集群会分析哪个服务器的读/写较少并将我的查询指向该服务器? 当您
目录 一.系统环境 二.前言 三.Kubernetes 3.1 概述 3.2 Kube
我是一名优秀的程序员,十分优秀!