本站文章总数为:165
Search Posts

Elastic Stack 7.4.0-7.12.0 gold白金版永不过期(亲测破解Elasticsearch许可证)

内容纲要

转载备忘

7.12.0 jar文件蓝奏云地址

https://wws.lanzouy.com/iVRW10610bih 密码:80n8

系统环境:CentOS Linux release 7.7.1908 (Core)
7.4.0~7.12.0都适用这个方法。
仅限于学习,非商业用途。

一键执行(仅限RPM包安装的7.12.0版使用):

rm -rf /usr/share/elasticsearch/modules/x-pack-core/x-pack-core-7.12.0.jar
wget https://www.itca.cc/file/x-pack-core-7.12.0.jar -O /usr/share/elasticsearch/modules/x-pack-core/x-pack-core-7.12.0.jar
echo xpack.security.enabled: false >> /etc/elasticsearch/elasticsearch.yml
systemctl restart elasticsearch kibana


手动处理(适用上述所有版本,请自行根据实际情况修改):

01、下载tar.gz安装包

# 创建目录
mkdir /root/elasticsearch-pj && cd /root/elasticsearch-pj
mkdir install && cd install

# 下载
wget https://mirrors.huaweicloud.com/elasticsearch/7.12.0/elasticsearch-7.12.0-linux-x86_64.tar.gz -O elasticsearch-7.12.0-linux-x86_64.tar.gz

# 解压
tar zxvf elasticsearch-7.12.0-linux-x86_64.tar.gz
cd ..

02、下载elasticsearch源码

# 创建目录
cd /root/elasticsearch-pj
mkdir src && cd src

# 下载
wget https://github.com/elastic/elasticsearch/archive/v7.12.0.tar.gz -O elasticsearch-v7.12.0.tar.gz

# 解压
tar zxvf elasticsearch-v7.12.0.tar.gz
cd ..

03、修改并编译x-pack包

cd /root/elasticsearch-pj
mkdir build && cd build

# lib module
ln -s ../install/elasticsearch-7.12.0/lib .
ln -s ../install/elasticsearch-7.12.0/modules .

# License.java
find ../src -name "License.java" | xargs -r -I {} cp {} .
sed -i 's#this.type = type;#this.type = "platinum";#g' License.java
sed -i 's#validate();#// validate();#g' License.java

# 编译
yum -y install java-devel
javac -cp "`ls lib/elasticsearch-7.12.0.jar`:`ls lib/elasticsearch-x-content-7.12.0.jar`:`ls lib/lucene-core-*.jar`:`ls modules/x-pack-core/x-pack-core-7.12.0.jar`" License.java

# x-pack-core-7.12.0.jar
mkdir src && cd src
find ../../install -name "x-pack-core-7.5.0.jar" | xargs -r -I {} cp {} .
jar xvf x-pack-core-7.12.0.jar
rm -f x-pack-core-7.12.0.jar
\cp -f ../License*.class org/elasticsearch/license/
jar cvf x-pack-core-7.12.0.jar .

04、覆盖x-pack-core-7.12.0.jar

把编译后的x-pack-core-7.12.0.jar文件覆盖到安装目录下

cp /root/elasticsearch-pj/build/src/x-pack-core-7.12.0.jar /usr/share/elasticsearch/modules/x-pack-core/

注:若想保留安装时候直接打开页面,无需登陆,请执行下条命令,跳过05和06步骤

echo xpack.security.enabled: false >> /etc/elasticsearch/elasticsearch.yml && systemctl restart elasticsearch kibana
#需要使用密码登陆无需执行
05、初始化elasticsearch密码

#进入elasticsearch的安装目录操作,一般为:/usr/share/elasticsearch
[root@CentOS elasticsearch]# elasticsearch-setup-passwords interactive
Initiating the setup of passwords for reserved users elastic,apm_system,kibana,logstash_system,beats_system,remote_monitorin_user.
You will be prompted to enter passwords as the process progresses.
Please confirm that you would like to continue [y/N]y


Enter password for [elastic]:
Reenter password for [elastic]:
Enter password for [apm_system]:
Reenter password for [apm_system]:
Enter password for [kibana]:
Reenter password for [kibana]:
Enter password for [logstash_system]:
Reenter password for [logstash_system]:
Enter password for [beats_system]:
Reenter password for [beats_system]:
Enter password for [remote_monitoring_user]:
Reenter password for [remote_monitoring_user]:
Changed password for user [apm_system]
Changed password for user [kibana]
Changed password for user [logstash_system]
Changed password for user [beats_system]
Changed password for user [remote_monitoring_user]
Changed password for user [elastic]
06、配置重启elasticsearch及kibana

# 配置
sed -i '$a\xpack.security.enabled: true\nxpack.security.transport.ssl.enabled: true\n' /etc/elasticsearch/elasticsearch.yml
sed -i '$a\elasticsearch.username: kibana\nelasticsearch.password: 12345\n' /etc/kibana/kibana.yml

# 重启
systemctl restart elasticsearch kibana

作者:运维猿Winter
链接:https://www.jianshu.com/p/85d4971ed3f9
来源:简书
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注