草庐IT

Elasticsearch-head-master

全部标签

linux查看es节点使用情况,elasticsearch(es) 如何查看当前集群中哪个节点是主节点(master)

elasticsearch查看当前集群中的master节点是哪个需要使用_cat监控命令,具体如下。查看方法es主节点确定命令,以kibana上查看示例如下:GET_cat/nodesv返回结果示例如下:ipheap.percentram.percentcpuload_1mload_5mload_15mnode.rolemastername172.16.16.188529952.591.701.45mdi-elastic3172.16.16.187329950.990.991.19mdi-elastic2172.16.16.231699940.871.001.03mdi-elastic4172

ruby - 在 Elasticsearch 中计算地理距离

我在查询中使用geo_distancefilter和tire,它工作正常:search.filter:geo_distance,:distance=>"#{request.distance}km",:location=>"#{request.lat},#{request.lng}"我预计结果会以某种方式包括到我用于过滤器的地理位置的计算距离。有没有办法告诉elasticsearch在响应中包含它,这样我就不必在ruby​​中为每个结果计算它?==更新==我在谷歌群组中的foundtheanswer:search.sortdoby"_geo_distance","location"=>"

ruby - 有没有办法计算 ElasticSearch 或 Tire 中索引的所有元素?

如果不必像这样进行搜索就可以对元素进行计数,那就太好了Obj.search("id:*").count这可能吗? 最佳答案 在ElasticSearch中,您可以使用计数API对所有元素进行计数curl-XGEThttp://localhost:9200/index/_count参见CountAPI他们网站上的文档。 关于ruby-有没有办法计算ElasticSearch或Tire中索引的所有元素?,我们在StackOverflow上找到一个类似的问题: ht

ruby-on-rails - 当我停止 rails server 时,我的 elasticsearch 索引会发生什么?

我对在Rails应用程序中使用Elasticsearch还很陌生,我正在使用耐嚼的gem来实现它。当我通过railss在开发模式下运行我的Rails应用程序时,我然后通过elasticsearch命令运行Elasticsearch并运行rakechewy:reset:all为我的数据创建索引。这样做一切正常,但如果我重新启动服务器,我必须再次运行rakechewy:reset:all命令以重建索引,否则我会收到错误消息。当我重新启动服务器时,索引会发生什么变化?服务器停止时是否销毁?我不是很熟悉Elasticsearch的功能,所以希望有人能对幕后发生的事情有所了解。

ruby-on-rails - Elasticsearch、轮胎与协会

运行:Ruby1.9.3p0(2011-10-30修订版33570)[x86_64-darwin11.2.0],Rails3.2.0我正在尝试通过跨协会的TIREgem进行Elasticsearch。出于某种原因,在TIRE导入或偶尔在View上执行rake时,我不断收到以下错误/错误:Daves-MacBook-Pro:outdoordave$rakeenvironmenttire:importCLASS=GearFORCE=true[IMPORT]Deletingindex'gears'[IMPORT]Creatingindex'gears'withmapping:{"gear":

org.elasticsearch.cluster.block.clusterblockexception: blocked by: [service_unavailable/1/state not

文章目录一.搭建集群时出现错误错误日志elasticsearch.logorg.elasticsearch.cluster.block.clusterblockexception:blockedby:[service_unavailable/1/statenotrecovered/initialized];原因:解决方案:一.搭建集群时出现错误错误日志elasticsearch.logorg.elasticsearch.cluster.block.clusterblockexception:blockedby:[service_unavailable/1/statenotrecovered/i

ruby - 为什么不使用 RVM 安装 Ruby 1.9.2-head?

我一直在尝试使用RVM安装Ruby1.9.2-head,但一直收到此错误消息:echoexecutablehostrubyisrequired为了通过RVM安装Ruby,是否必须具有系统Ruby?我拥有rvmnotes中给出的所有依赖项,但我没有安装任何系统Ruby。错误日志显示:[2011-05-0207:42:19]makegcc-O3-ggdb-Wextra-Wno-unused-parameter-Wno-parentheses-Wpointer-arith-Wwrite-strings-Wno-missing-field-initializers-Wno-long-long-

ruby-on-rails - Ruby NET::HTTP 在主体之前读取 header (没有 HEAD 请求)?

我使用Net::HTTP和Ruby来抓取URL。我不想抓取流式音频,例如:http://listen2.openstream.co/334其实我只想抓取Html内容,所以没有pdfs、video、txt..现在,我将open_timeout和read_timeout都设置为10,所以即使我抓取这些流式音频页面,它们也会超时。url='http://listen2.openstream.co/334'path=uri.pathreq=Net::HTTP::Get.new(path,{'Accept'=>'*/*','Content-Type'=>'text/plain;charset=u

ruby-on-rails - ElasticSearch Rails - 设置自定义分析器

我通过elasticsearch-rails(https://github.com/elasticsearch/elasticsearch-rails)在Rails4中使用ElasticSearch我有一个带有电子邮件属性的用户模型。我正在尝试使用文档中描述的“uax_url_email”分词器:classUser我按照wiki(https://github.com/elasticsearch/elasticsearch-rails/wiki)和elasticsearch-model文档(https://github.com/elasticsearch/elasticsearch-ra

ruby - Head 用法未知选项 -1/-n 错误。可能与 ruby 有关

我在OSX10.9.1中启动终端时反复出现问题。每次启动终端时,我都会重复以下至少30次Unknownoption:1Usage:head[-options]...-musemethodfortherequest(defaultis'HEAD')-fmakerequestevenifheadbelievesmethodisillegal-bUsethespecifiedURLasbase-tSettimeoutvalue-iSettheIf-Modified-Sinceheaderontherequest-cusethiscontent-typeforPOST,PUT,CHECKIN-