美文网首页
全文搜索引擎 Elasticsearch

全文搜索引擎 Elasticsearch

作者: 云龙789 | 来源:发表于2019-01-29 15:28 被阅读10次

    首先安装 java 环境 sudo apt-get install default-jre

    • 安装 elastic
    $ wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-5.5.1.zip
    $ unzip elasticsearch-5.5.1.zip
    $ cd elasticsearch-5.5.1/ 
    
    • 启动 Elastic
     ./bin/elasticsearch
    

    默认是 9200 端口

    vagrant@homestead:~$ curl localhost:9200
    {
      "name" : "6AKT6r3",
      "cluster_name" : "elasticsearch",
      "cluster_uuid" : "dCkD2MoLStibGouqvXdrvA",
      "version" : {
        "number" : "5.5.1",
        "build_hash" : "19c13d0",
        "build_date" : "2017-07-18T20:44:24.823Z",
        "build_snapshot" : false,
        "lucene_version" : "6.6.0"
      },
      "tagline" : "You Know, for Search"
    }
    

    其他的直接参看推荐资料好了

    • 添加中文分词
    $ cd elasticsearch-5.5.1/ 
    $ ./bin/elasticsearch-plugin install https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v6.3.0/elasticsearch-analysis-ik-6.3.0.zip
    

    相关文章

      网友评论

          本文标题:全文搜索引擎 Elasticsearch

          本文链接:https://www.haomeiwen.com/subject/stpxsqtx.html