• 相同的问题

    sudo make reindex 也报错,求解答 @huacnlee

    [root@localhost homeland-docker]# sudo make reindex
    Reindex ElasticSearch...
    Starting homelanddocker_elasticsearch_1 ... 
    Starting homelanddocker_memcached_1 ... 
    Starting homelanddocker_memcached_1 ... done
    Starting homelanddocker_redis_1 ... done
    [!!!] Index does not exist (Elasticsearch::Transport::Transport::Errors::NotFound)
    rake aborted!
    Elasticsearch::Transport::Transport::Errors::BadRequest: [400] {"error":{"root_cause":[{"type":"mapper_parsing_exception","reason":"No handler for type [text] declared on field [title]"}],"type":"mapper_parsing_exception","reason":"Failed to parse mapping [topic]: No handler for type [text] declared on field [title]","caused_by":{"type":"mapper_parsing_exception","reason":"No handler for type [text] declared on field [title]"}},"status":400}
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-transport-5.0.4/lib/elasticsearch/transport/transport/base.rb:202:in `__raise_transport_error'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-transport-5.0.4/lib/elasticsearch/transport/transport/base.rb:319:in `perform_request'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-transport-5.0.4/lib/elasticsearch/transport/transport/http/faraday.rb:20:in `perform_request'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-transport-5.0.4/lib/elasticsearch/transport/client.rb:131:in `perform_request'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-api-5.0.4/lib/elasticsearch/api/namespace/common.rb:21:in `perform_request'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-api-5.0.4/lib/elasticsearch/api/actions/indices/create.rb:86:in `create'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-model-5.0.1/lib/elasticsearch/model/indexing.rb:232:in `create_index!'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-model-5.0.1/lib/elasticsearch/model/importing.rb:116:in `import'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/elasticsearch-rails-5.0.1/lib/elasticsearch/rails/tasks/import.rb:63:in `block (3 levels) in <top (required)>'
    /var/www/homeland/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/exe/rake:27:in `<top (required)>'
    /usr/local/bin/bundle:22:in `load'
    /usr/local/bin/bundle:22:in `<main>'
    Tasks: TOP => elasticsearch:import:model
    (See full trace by running task with --trace)
    make: *** [reindex] Error 1