<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??一站式輕松地調用各大LLM模型接口,支持GPT4、智譜、豆包、星火、月之暗面及文生圖、文生視頻 廣告
                <blockquote class="success">注意事項</blockquote> ``` 在線下載可能很慢,安裝包可以下載好用ftp上傳到指定目錄下,本文一律下載在root目錄下 ``` ### 一、安裝JDK1.8 ``` 1、查看linux 系統環境 getconf LONG_BIT 2、未安裝wget請先安裝 rpm -qa|grep "wget" yum -y install wget 3、下載JDK安裝包 wget --no-check-certificate http://www.ryloo.icu/jdk-8u251-linux-x64.tar.gz 4、創建安裝目錄 mkdir /usr/local/java/ 5、解壓至安裝目錄 tar -zxvf jdk-8u251-linux-x64.tar.gz -C /usr/local/java/ 6、設置環境變量 vim /etc/profile 在末尾添加 export JAVA_HOME=/usr/local/java/jdk1.8.0_251 export JRE_HOME=${JAVA_HOME}/jre export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib export PATH=${JAVA_HOME}/bin:$PATH 7、使環境變量生效 source /etc/profile 8、添加軟鏈接 ln -s /usr/local/java/jdk1.8.0_251/bin/java /usr/bin/java 9、檢查 java -version ``` ### 二、安裝elasticsearch-7.6.2 ``` 1、下載elasticsearch安裝包 wget?https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.6.2-linux-x86_64.tar.gz 2、創建安裝目錄 mkdir /usr/local/es/ 3、解壓至安裝目錄 tar -zxvf elasticsearch-7.6.2-linux-x86_64.tar.gz -C /usr/local/es/ 4、修改配置,內存占用可以調小一點 vim /usr/local/es/elasticsearch-7.6.2/config/jvm.options ``` ![](http://cloud.ryloo.icu/e5880fb9259f7c28d1c9f73604e6f0c0) ``` 5、配置elasticsearch.yml vim /usr/local/es/elasticsearch-7.6.2/config/elasticsearch.yml ``` ![](http://cloud.ryloo.icu/825ee90c7569aaa4dc506b5f62584676) ![](http://cloud.ryloo.icu/357edfe940082ef156b288e06a7da9e9) ### 三、創建賬戶esuser,因為es默認不允許以root賬戶運行 ``` //創建用戶組 groupadd esgroup //創建用戶 useradd -g esgroup esuser //設置權限 chown -R esuser:esgroup /usr/local/es/ //設置密碼 864923705 passwd esuser ``` ### 四、修改linux內核參數 ``` //修改/etc/security/limits.conf 增加下面內容 * soft nproc 65535 * hard nproc 65535 * soft nofile 65535 * hard nofile 131072 //修改/etc/sysctl.conf 增加下面內容 vm.max_map_count=655360 //然后執行命令,使配置生效** sysctl -p ``` ### 五、啟動 ``` //切換用戶 su esuser //切換目錄 cd /usr/local/es/elasticsearch-7.6.2/bin //前臺啟動es,Ctrl + C 則程序終止 ./elasticsearch //后臺啟動es ./elasticsearch -d //查找es進程 ps -ef | grep elastic //殺掉ES進程 kill -9 xxxx ``` ### 六、訪問 ``` //測試 curl 127.0.0.1:9200 | curl IP:9200 //curl: (7) couldn't connect to host iptables -I INPUT 1 -p tcp --dport 9200 -j ACCEPT ``` ![](http://cloud.ryloo.icu/232a500c143b009e690fddbcdbd49e40) ### 七、配置文件參數詳解 [【elasticsearch.yml】](https://www.cnblogs.com/hanyouchun/p/5163183.html) ### 八、賬號密碼設置 1、elasticsearch.yml 設置 ~~~ http.cors.enabled: true http.cors.allow-origin: "*" http.cors.allow-headers: Authorization,X-Requested-With,Content-Type,Content-Length xpack.security.enabled: true xpack.security.transport.ssl.enabled: true ~~~ 設置密碼 ~~~ [root@VM-0-11-centos bin]# su esuser [esuser@VM-0-11-centos bin]# whereis gcc gcc: /usr/bin/gcc /usr/lib/gcc /usr/libexec/gcc /usr/share/man/man1/gcc.1.gz [esuser@VM-0-11-centos bin]$ cd ~ [esuser@VM-0-11-centos ~]$ cd /usr/bin [esuser@VM-0-11-centos bin]$ /usr/local/es/elasticsearch-7.6.2/bin/elasticsearch-setup-passwords interactive ~~~ ![](http://cloud.ryloo.icu/ce743822c63f489ea83a7dc5b1a2023a) 重啟服務 ![](http://cloud.ryloo.icu/9c1c8dddae0246566f67735b23db2e7e) 2、elasticsearch-head ES開啟安全密碼認證后,在web界面訪問時,該框由原來的 http://118.25.242.51:9100替換為 http://118.25.242.51:9100/?auth\_user=elastic&auth_password=你的es密碼,例如: ![](http://cloud.ryloo.icu/5f4fa80103eed9e4475c7726d25975e3) 3、Kibana > vi /usr/local/kibana/kibana-7.6.2-linux-x86_64/config/kibana.yml ![](http://cloud.ryloo.icu/8e1a7481cd1a5506839bd9cf7750ba26) ![](http://cloud.ryloo.icu/a4788a3c8938ae78f4a33699c62f4ad4) 4、logstash >需修改導入數據的配置文件,例: ~~~ output { elasticsearch { hosts => ["118.25.242.51:9200"] user => "elastic" password => "123456" index => "lawsuit_clauses_v1" document_id => "%{id}" } # 這里輸出調試,正式運行時可以注釋掉 stdout { codec => json_lines } } ~~~ ![](http://cloud.ryloo.icu/ef6db89b7713f1e720d7b7ddba1fed4d) ### 九、ES開機啟動 參考博主文章 # [elasticsearch設置開機自啟動](https://www.cnblogs.com/tester-yu/p/14889003.html) ~~~ // 先查看當前的開機啟動服務 chkconfig --list // 創建es 的系統啟動服務文件,進入到?cd /etc/init.d 目錄 cd /etc/init.d   vi elasticsearch // 復制以下腳本 #!/bin/bash #chkconfig: 345 63 37 #description: elasticsearch #processname: elasticsearch-7.6.2 export ES_HOME=/usr/local/es/elasticsearch-7.6.2 case $1 in start) su esuser<<! cd $ES_HOME ./bin/elasticsearch -d -p pid exit ! echo "elasticsearch is started" ;; stop) pid=`cat $ES_HOME/pid` kill -9 $pid echo "elasticsearch is stopped" ;; restart) pid=`cat $ES_HOME/pid` kill -9 $pid echo "elasticsearch is stopped" sleep 1 su esuser<<! cd $ES_HOME ./bin/elasticsearch -d -p pid exit ! echo "elasticsearch is started" ;; *) echo "start|stop|restart" ;; esac exit 0 // 修改文件權限 chmod 777 elasticsearch // 添加服務并設置啟動方式 chkconfig --add elasticsearch chkconfig elasticsearch on // 重啟后,驗證是否已啟動 ps -ef | grep elasticsearch ~~~ ![](http://cloud.ryloo.icu/b19138b566c313d49d3da2b6bfacb857) ![](http://cloud.ryloo.icu/544bb89526faa4c577e52d4bab0a5dde) ![](http://cloud.ryloo.icu/9db9444995fca933601e15cc3c7ca166) ![](http://cloud.ryloo.icu/08eb81a894e2b2413fb9a76550b0f2bb) 重啟,等服務器啟動elasticsearch服務。 ![](http://cloud.ryloo.icu/dd86855a794df287927b744ab221e707)
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看