hello
I use the initialization container to install the plugin.
ECK version:
ECK version 1.3.1
kubernetes version
Client Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.8", GitCommit:"9f2892aab98fe339f3bd70e3c470144299398ace", GitTreeState:"clean", BuildDate:"2020-08-13T16:12:48Z", GoVersion:"go1.13.15", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.8", GitCommit:"9f2892aab98fe339f3bd70e3c470144299398ace", GitTreeState:"clean", BuildDate:"2020-08-13T16:04:18Z", GoVersion:"go1.13.15", Compiler:"gc", Platform:"linux/amd64"}
config,elaticsearch version is 7.10.1
...
spec:
containers:
- env:
- name: ES_JAVA_OPTS
value: -Xms1g -Xmx1g -Des.allow_insecure_settings=true
name: elasticsearch
resources:
limits:
memory: 2Gi
requests:
cpu: "0"
memory: 2Gi
initContainers:
- command:
- sh
- -c
- 'bin/elasticsearch-plugin install --batch http://mirrors.crcloud.com/ece/repository-s3-7.10.1.zip '
name: install-s3
resources: {}
- command:
- sh
- -c
- 'bin/elasticsearch-plugin install --batch http://mirrors.crcloud.com/ece/elasticsearch-analysis-ik-7.10.1.zip '
name: install-ik
resources: {}
...
install s3 log
-> Installing http://mirrors.crcloud.com/ece/repository-s3-7.10.1.zip
2021/2/1 下午4:23:24 -> Downloading http://mirrors.crcloud.com/ece/repository-s3-7.10.1.zip
2021/2/1 下午4:23:27 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
2021/2/1 下午4:23:27 @ WARNING: plugin requires additional permissions @
2021/2/1 下午4:23:27 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
2021/2/1 下午4:23:27 * java.lang.RuntimePermission accessDeclaredMembers
2021/2/1 下午4:23:27 * java.lang.RuntimePermission getClassLoader
2021/2/1 下午4:23:27 * java.lang.reflect.ReflectPermission suppressAccessChecks
2021/2/1 下午4:23:27 * java.net.SocketPermission * connect,resolve
2021/2/1 下午4:23:27 * java.util.PropertyPermission es.allow_insecure_settings read,write
2021/2/1 下午4:23:27 See http://docs.oracle.com/javase/8/docs/technotes/guides/security/permissions.html
2021/2/1 下午4:23:27 for descriptions of what these permissions allow and the associated risks.
2021/2/1 下午4:23:27 -> Installed repository-s3
install ik
-> Installing http://mirrors.crcloud.com/ece/elasticsearch-analysis-ik-7.10.1.zip
2021/2/1 下午4:34:24 -> Downloading http://mirrors.crcloud.com/ece/elasticsearch-analysis-ik-7.10.1.zip
2021/2/1 下午4:34:24 -> Failed installing http://mirrors.crcloud.com/ece/elasticsearch-analysis-ik-7.10.1.zip
2021/2/1 下午4:34:24 -> Rolling back http://mirrors.crcloud.com/ece/elasticsearch-analysis-ik-7.10.1.zip
2021/2/1 下午4:34:24 -> Rolled back http://mirrors.crcloud.com/ece/elasticsearch-analysis-ik-7.10.1.zip
2021/2/1 下午4:34:24 Exception in thread "main" java.nio.file.NoSuchFileException: /usr/share/elasticsearch/plugins/.installing-7953201950996782894/plugin-descriptor.properties
2021/2/1 下午4:34:24 at java.base/sun.nio.fs.UnixException.translateToIOException(UnixException.java:92)
2021/2/1 下午4:34:24 at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:106)
2021/2/1 下午4:34:24 at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111)
2021/2/1 下午4:34:24 at java.base/sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:218)
2021/2/1 下午4:34:24 at java.base/java.nio.file.Files.newByteChannel(Files.java:375)
2021/2/1 下午4:34:24 at java.base/java.nio.file.Files.newByteChannel(Files.java:426)
2021/2/1 下午4:34:24 at java.base/java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:420)
2021/2/1 下午4:34:24 at java.base/java.nio.file.Files.newInputStream(Files.java:160)
2021/2/1 下午4:34:24 at org.elasticsearch.plugins.PluginInfo.readFromProperties(PluginInfo.java:156)
2021/2/1 下午4:34:24 at org.elasticsearch.plugins.InstallPluginCommand.loadPluginInfo(InstallPluginCommand.java:807)
2021/2/1 下午4:34:24 at org.elasticsearch.plugins.InstallPluginCommand.installPlugin(InstallPluginCommand.java:866)
2021/2/1 下午4:34:24 at org.elasticsearch.plugins.InstallPluginCommand.execute(InstallPluginCommand.java:254)
2021/2/1 下午4:34:24 at org.elasticsearch.plugins.InstallPluginCommand.execute(InstallPluginCommand.java:224)
2021/2/1 下午4:34:24 at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86)
2021/2/1 下午4:34:24 at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:127)
2021/2/1 下午4:34:24 at org.elasticsearch.cli.MultiCommand.execute(MultiCommand.java:91)
2021/2/1 下午4:34:24 at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:127)
2021/2/1 下午4:34:24 at org.elasticsearch.cli.Command.main(Command.java:90)
2021/2/1 下午4:34:24 at org.elasticsearch.plugins.PluginCli.main(PluginCli.java:47)
Can anyone help me, thank you very much!