I'm using CDH 5.3.2 and elasticsearch-2.1.0. I built the the zip file of repository-hdfs and install it as a plugin. Then using elasticsearch-yarn to start the elasticsearch cluster. But when I created a HDFS repository, I got the error below. The hadoop jar where StringUtils resides elasticsearch-2.1.0/plugins/repository-hdfs/hadoop-libs/hadoop-common-2.5.0-cdh5.3.2.jar is included in the elasticsearch zip. Any idea?
[2015-12-14 15:32:27,288][INFO ][rest.suppressed ] /_snapshot/my_backup Params: {repository=my_backup}
RemoteTransportException[[Strobe][10.150.12.108:9300][cluster:admin/repository/put]]; nested: RepositoryException[[my_backup] failed to create repository]; nested: NotSerializableExceptionWrapper[Guice creation errors:
1) Error injecting constructor, java.lang.NoClassDefFoundError: Could not initialize class org.apache.hadoop.util.StringUtils
at org.elasticsearch.repositories.hdfs.HdfsRepository.<init>(Unknown Source)
while locating org.elasticsearch.repositories.hdfs.HdfsRepository
while locating org.elasticsearch.repositories.Repository
1 error]; nested: NotSerializableExceptionWrapper[Could not initialize class org.apache.hadoop.util.StringUtils];
Caused by: RepositoryException[[my_backup] failed to create repository]; nested: NotSerializableExceptionWrapper[Guice creation errors:
1) Error injecting constructor, java.lang.NoClassDefFoundError: Could not initialize class org.apache.hadoop.util.StringUtils
at org.elasticsearch.repositories.hdfs.HdfsRepository.<init>(Unknown Source)
while locating org.elasticsearch.repositories.hdfs.HdfsRepository
while locating org.elasticsearch.repositories.Repository
1 error]; nested: NotSerializableExceptionWrapper[Could not initialize class org.apache.hadoop.util.StringUtils];
at org.elasticsearch.repositories.RepositoriesService.createRepositoryHolder(RepositoriesService.java:411)
at org.elasticsearch.repositories.RepositoriesService.registerRepository(RepositoriesService.java:368)
at org.elasticsearch.repositories.RepositoriesService.access$100(RepositoriesService.java:55)
at org.elasticsearch.repositories.RepositoriesService$1.execute(RepositoriesService.java:110)
at org.elasticsearch.cluster.service.InternalClusterService$UpdateTask.run(InternalClusterService.java:388)
at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.runAndClean(PrioritizedEsThreadPoolExecutor.java:231)
at org.elasticsearch.common.util.concurrent.PrioritizedEsThreadPoolExecutor$TieBreakingPrioritizedRunnable.run(PrioritizedEsThreadPoolExecutor.java:194)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: NotSerializableExceptionWrapper[Guice creation errors:
1) Error injecting constructor, java.lang.NoClassDefFoundError: Could not initialize class org.apache.hadoop.util.StringUtils
at org.elasticsearch.repositories.hdfs.HdfsRepository.<init>(Unknown Source)
while locating org.elasticsearch.repositories.hdfs.HdfsRepository
while locating org.elasticsearch.repositories.Repository
1 error]; nested: NotSerializableExceptionWrapper[Could not initialize class org.apache.hadoop.util.StringUtils];
at org.elasticsearch.common.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:360)
at org.elasticsearch.common.inject.InjectorBuilder.injectDynamically(InjectorBuilder.java:178)
at org.elasticsearch.common.inject.InjectorBuilder.build(InjectorBuilder.java:110)
at org.elasticsearch.common.inject.InjectorImpl.createChildInjector(InjectorImpl.java:159)
at org.elasticsearch.common.inject.ModulesBuilder.createChildInjector(ModulesBuilder.java:55)
at org.elasticsearch.repositories.RepositoriesService.createRepositoryHolder(RepositoriesService.java:404)
... 9 more
Caused by: NotSerializableExceptionWrapper[Could not initialize class org.apache.hadoop.util.StringUtils]
at org.apache.hadoop.security.Groups.parseStaticMapping(Groups.java:104)
at org.apache.hadoop.security.Groups.<init>(Groups.java:86)
at org.apache.hadoop.security.Groups.<init>(Groups.java:66)
at org.apache.hadoop.security.Groups.getUserToGroupsMappingService(Groups.java:280)
at org.apache.hadoop.security.UserGroupInformation.initialize(UserGroupInformation.java:269)
at org.apache.hadoop.security.UserGroupInformation.setConfiguration(UserGroupInformation.java:297)
at org.elasticsearch.repositories.hdfs.HdfsRepository.initFileSystem(HdfsRepository.java:122)
at org.elasticsearch.repositories.hdfs.HdfsRepository.getFileSystem(HdfsRepository.java:99)
at org.elasticsearch.repositories.hdfs.HdfsRepository.<init>(HdfsRepository.java:71)
...
at