ElasticSearch-磁盘空间不够引起的问题

清理Elasticsearch占用的内存和磁盘空间 ELK中的Kibana连不上Elasticsearch了,提示Cannot connect to the Elasticsearch cluster,检查发现OutOfMemoryError,通过删除历史索引,达到清理Elasticsearch占用的内存和磁盘空间的目的 阅读详情

es 6.2.4版本
logstash跑了一阵子之后不再同步数据了,日志信息如下:

[2019-06-19T10:30:28,379][INFO ][logstash.outputs.elasticsearch] retrying failed action with response code: 403 ({"type"=>"cluster_block_exception", "reason"=>"blocked by: [FORBIDDEN/12/index read-only / allow delete (api)];"})
[2019-06-19T10:30:28,379][INFO ][logstash.outputs.elasticsearch] Retrying individual bulk actions that failed or were rejected by the previous bulk request. {:count=>125}

检查elasticsearch日志如下:(日志没贴全,应该有超过flood_stage阈值的告警,因为logstash日志里已经提示索引只读了...可是日志被我删掉了...)

[2019-06-19T10:30:26,746][WARN ][o.e.c.r.a.DiskThresholdMonitor] [node-1] high disk watermark [90%] exceeded on [sPv40vq_RKanFIUuBgJuUQ][node-2][/usr/elasticsearch/data/nodes/0] free: 657.4mb[8%], shards will be relocated away from this node
[2019-06-19T10:30:26,746][INFO ][o.e.c.r.a.DiskThresholdMonitor] [node-1] low disk watermark [85%] exceeded on [DJl3qtK5Twmpi-MGNuujog][node-3][/usr/elasticsearch/data/nodes/0] free: 1gb[13.4%], replicas will not be assigned to this node
[2019-06-19T10:30:56,752][WARN ][o.e.c.r.a.DiskThresholdMonitor] [node-1] high disk watermark [90%] exceeded on [sPv40vq_RKanFIUuBgJuUQ][node-2][/usr/elasticsearch/data/nodes/0] free: 657.4mb[8%], shards will be relocated away from this node
[2019-06-19T10:30:56,752][INFO ][o.e.c.r.a.DiskThresholdMonitor] [node-1] low disk watermark [85%] exceeded on [DJl3qtK5Twmpi-MGNuujog][node-3][/usr/elasticsearch/data/nodes/0] free: 1gb[13.4%], replicas will not be assigned to this node
[2019-06-19T10:30:56,752][INFO ][o.e.c.r.a.DiskThresholdMonitor] [node-1] rerouting shards: [high disk watermark exceeded on one or more nodes]

查看代码org.elasticsearch.cluster.routing.allocation.DiskThresholdMonitor#onNewInfo,结合官网文档 Disk-based Shard Allocationedit,可以知道es会对磁盘空间进行监控,当磁盘空间使用量达到一定的阈值就会做不同的处理。
这里其实是磁盘剩余空间达到了floodstage阈值,导致Elasticsearch对每个索引强制执行只读索引块,所以logstash在做数据同步的时候就报错了。

部分源码如下:

    public void onNewInfo(ClusterInfo info) {
        ImmutableOpenMap<String, DiskUsage> usages = info.getNodeLeastAvailableDiskUsages();
        if (usages != null) {
            boolean reroute = false;
            String explanation = "";

            // Garbage collect nodes that have been removed from the cluster
            // from the map that tracks watermark crossing
            ObjectLookupContainer<String> nodes = usages.keys();
            for (String node : nodeHasPassedWatermark) {
                if (nodes.contains(node) == false) {
                    nodeHasPassedWatermark.remove(node);
                }
            }
            ClusterState state = clusterStateSupplier.get();
            Set<String> indicesToMarkReadOnly = new HashSet<>();
            for (ObjectObjectCursor<String, DiskUsage> entry : usages) {
                String node = entry.key;
                DiskUsage usage = entry.value;  
                //检测磁盘空间使用量,当达到不同阈值时给出告警或者info信息
                warnAboutDiskIfNeeded(usage);  
                //磁盘使用量达到floodstage阈值,将所有索引都标记为只读
                if (usage.getFreeBytes() < diskThresholdSettings.getFreeBytesThresholdFloodStage().getBytes() ||
                    usage.getFreeDiskAsPercentage() < diskThresholdSettings.getFreeDiskThresholdFloodStage()) {
                    RoutingNode routingNode = state.getRoutingNodes().node(node);
                    if (routingNode != null) { // this might happen if we haven't got the full cluster-state yet?!
                        for (ShardRouting routing : routingNode) {
                            indicesToMarkReadOnly.add(routing.index().getName());
                        }
                    }
                } 
                    //磁盘使用量达到高阈值,超过重新分配分片的间隔时间则重新分配
                    else if (usage.getFreeBytes() < diskThresholdSettings.getFreeBytesThresholdHigh().getBytes() ||
                    usage.getFreeDiskAsPercentage() < diskThresholdSettings.getFreeDiskThresholdHigh()) {
                    if ((System.nanoTime() - lastRunNS) > diskThresholdSettings.getRerouteInterval().nanos()) {
                        lastRunNS = System.nanoTime();
                        reroute = true;
                        explanation = "high disk watermark exceeded on one or more nodes";
                    } else {
                        logger.debug("high disk watermark exceeded on {} but an automatic reroute has occurred " +
                                "in the last [{}], skipping reroute",
                            node, diskThresholdSettings.getRerouteInterval());
                    }
                    nodeHasPassedWatermark.add(node);
                } 
                //磁盘使用量达到低阈值
                else if (usage.getFreeBytes() < diskThresholdSettings.getFreeBytesThresholdLow().getBytes() ||
                    usage.getFreeDiskAsPercentage() < diskThresholdSettings.getFreeDiskThresholdLow()) {
                    nodeHasPassedWatermark.add(node);
                } 
                //磁盘使用量未达到任何阈值,如果之前达到了高阈值或低阈值,重新路由,以便能够分配任何未分配的分片
                else {
                    if (nodeHasPassedWatermark.contains(node)) {
                        // The node has previously been over the high or
                        // low watermark, but is no longer, so we should
                        // reroute so any unassigned shards can be allocated
                        // if they are able to be
                        if ((System.nanoTime() - lastRunNS) > diskThresholdSettings.getRerouteInterval().nanos()) {
                            lastRunNS = System.nanoTime();
                            reroute = true;
                            explanation = "one or more nodes has gone under the high or low watermark";
                            nodeHasPassedWatermark.remove(node);
                        } else {
                            logger.debug("{} has gone below a disk threshold, but an automatic reroute has occurred " +
                                    "in the last [{}], skipping reroute",
                                node, diskThresholdSettings.getRerouteInterval());
                        }
                    }
                }
            }
            if (reroute) {
                logger.info("rerouting shards: [{}]", explanation);
                reroute();
            }
            indicesToMarkReadOnly.removeIf(index -> state.getBlocks().indexBlocked(ClusterBlockLevel.WRITE, index));
            if (indicesToMarkReadOnly.isEmpty() == false) {
                markIndicesReadOnly(indicesToMarkReadOnly);
            }
        }
    }

    /**
     * Warn about the given disk usage if the low or high watermark has been passed
     */
    private void warnAboutDiskIfNeeded(DiskUsage usage) {  
        //检查磁盘剩余使用量
        // Check absolute disk values  
      // 剩余磁盘使用量 < cluster.routing.allocation.disk.watermark.flood_stage
        if (usage.getFreeBytes() < diskThresholdSettings.getFreeBytesThresholdFloodStage().getBytes()) {
            logger.warn("flood stage disk watermark [{}] exceeded on {}, all indices on this node will marked read-only",
                diskThresholdSettings.getFreeBytesThresholdFloodStage(), usage);
        } 
        // 剩余磁盘使用量 < cluster.routing.allocation.disk.watermark.high
        else if (usage.getFreeBytes() < diskThresholdSettings.getFreeBytesThresholdHigh().getBytes()) {
            logger.warn("high disk watermark [{}] exceeded on {}, shards will be relocated away from this node",
                diskThresholdSettings.getFreeBytesThresholdHigh(), usage);
        } 
        // 剩余磁盘使用量 < cluster.routing.allocation.disk.watermark.low
        else if (usage.getFreeBytes() < diskThresholdSettings.getFreeBytesThresholdLow().getBytes()) {
            logger.info("low disk watermark [{}] exceeded on {}, replicas will not be assigned to this node",
                diskThresholdSettings.getFreeBytesThresholdLow(), usage);
        }
        
        //检查磁盘使用百分比
        // Check percentage disk values  
        // 剩余磁盘百分比 < 100 - 95(cluster.routing.allocation.disk.watermark.flood_stage)
        if (usage.getFreeDiskAsPercentage() < diskThresholdSettings.getFreeDiskThresholdFloodStage()) {
            logger.warn("flood stage disk watermark [{}] exceeded on {}, all indices on this node will marked read-only",
                Strings.format1Decimals(100.0 - diskThresholdSettings.getFreeDiskThresholdFloodStage(), "%"), usage);
        } 
        // 剩余磁盘百分比 < 100 - 90(cluster.routing.allocation.disk.watermark.high)
        else if (usage.getFreeDiskAsPercentage() < diskThresholdSettings.getFreeDiskThresholdHigh()) {
            logger.warn("high disk watermark [{}] exceeded on {}, shards will be relocated away from this node",
                Strings.format1Decimals(100.0 - diskThresholdSettings.getFreeDiskThresholdHigh(), "%"), usage);
        } 
        // 剩余磁盘百分比 < 100 - 85(cluster.routing.allocation.disk.watermark.low)
        else if (usage.getFreeDiskAsPercentage() < diskThresholdSettings.getFreeDiskThresholdLow()) {
            logger.info("low disk watermark [{}] exceeded on {}, replicas will not be assigned to this node",
                Strings.format1Decimals(100.0 - diskThresholdSettings.getFreeDiskThresholdLow(), "%"), usage);
        }
    }

这里涉及几个配置:

  • cluster.routing.allocation.disk.threshold_enabled是否开启基于磁盘的分片分配,默认true
  • cluster.routing.allocation.disk.watermark.low控制磁盘空间使用的低水位线,默认85%,es不会再将分片分配给磁盘使用超过这个配置的节点。

这个设置不会影响新创建的索引的主分片,或者是之前从未分配过的任何分片

  • cluster.routing.allocation.disk.watermark.high控制磁盘空间使用的高水位线,默认90%,es会将磁盘使用超过这个配置的节点中的分片重新进行分配。

这个设置将影响所有分片的分配,不管分片之前是否已经被分配过

  • cluster.routing.allocation.disk.watermark.flood_stage控制磁盘空间使用的洪水水位线,默认95%,es会将磁盘使用超过这个配置的节点中的所有索引都标记为只读。

这是防止节点耗尽磁盘空间的最后手段。一旦有足够的磁盘空间允许继续索引操作,需要手动释放索引块

  • cluster.routing.allocation.disk.include_relocations当计算一个节点的剩余磁盘空间时,是否考虑正在重新分配到当前节点的分片容量,默认true。

这可能导致错误的高估一个磁盘的使用率。因为分片重分配可能已经完成了90%,检索到的磁盘使用率包含了这个重新分配的分片总大小以及这已经分配了的90%进度的大小。

  • cluster.routing.allocation.disk.reroute_interval分片重分配间隔,默认60秒
  • cluster.info.update.interval磁盘使用率检查间隔,默认30秒

关于配置的几点说明:

  1. 上面几个配置要么都设置为百分比,要么都设置为具体的字节值,不能混用。
  2. 可以通过在配置文件elasticsearch.yml中配置,也可以在 cluster-update-settings API 在实时群集上动态更新。直接参考官网文档即可。

测试

-- 添加文档,自动创建索引
curl http://172.16.22.51:9200/idx_luoluocaihong/_doc/1 -X PUT  -H 'Content-Type:application/json' -d '{"user":"luoluocaihong","age":"20"}'
{"_index":"idx_luoluocaihong","_type":"_doc","_id":"1","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"_seq_no":0,"_primary_term":1}

-- 设置只读索引块
curl http://172.16.22.51:9200/idx_luoluocaihong/_settings -X PUT -H 'Content-Type:application/json' -d '{"index.blocks.read_only_allow_delete": true}'
{"acknowledged":true}

-- 查看索引的设置
curl http://172.16.22.51:9200/idx_luoluocaihong/_settings
{"idx_luoluocaihong":{"settings":{"index":{"number_of_shards":"5","blocks":{"read_only_allow_delete":"true"},"provided_name":"idx_luoluocaihong","creation_date":"1561107195032","number_of_replicas":"1","uuid":"3iS68s1nQMudxhyL-zNnRg","version":{"created":"6020499"}}}}}

-- 添加文档
curl http://172.16.22.51:9200/idx_luoluocaihong/_doc/2 -X PUT  -H 'Content-Type:application/json' -d '{"user":"user_2","age":"20"}'
{"error":{"root_cause":[{"type":"cluster_block_exception","reason":"blocked by: [FORBIDDEN/12/index read-only / allow delete (api)];"}],"type":"cluster_block_exception","reason":"blocked by: [FORBIDDEN/12/index read-only / allow delete (api)];"},"status":403}

-- 重置只读索引块
curl http://172.16.22.51:9200/idx_luoluocaihong/_settings -X PUT -H 'Content-Type:application/json' -d '{"index.blocks.read_only_allow_delete": null}'
{"acknowledged":true}

-- 查看索引的设置
curl http://172.16.22.51:9200/idx_luoluocaihong/_settings
{"idx_luoluocaihong":{"settings":{"index":{"creation_date":"1561107195032","number_of_shards":"5","number_of_replicas":"1","uuid":"3iS68s1nQMudxhyL-zNnRg","version":{"created":"6020499"},"provided_name":"idx_luoluocaihong"}}}}

-- 添加文档
curl http://172.16.22.51:9200/idx_luoluocaihong/_doc/2 -X PUT  -H 'Content-Type:application/json' -d '{"user":"user_2","age":"20"}'
{"_index":"idx_luoluocaihong","_type":"_doc","_id":"2","_version":1,"result":"created","_shards":{"total":2,"successful":2,"failed":0},"_seq_no":0,"_primary_term":1}

-- 搜索
curl http://172.16.22.51:9200/idx_luoluocaihong/_search?q=age:20
{"took":19,"timed_out":false,"_shards":{"total":5,"successful":5,"skipped":0,"failed":0},"hits":{"total":2,"max_score":0.2876821,"hits":[{"_index":"idx_luoluocaihong","_type":"_doc","_id":"2","_score":0.2876821,"_source":{"user":"user_2","age":"20"}},{"_index":"idx_luoluocaihong","_type":"_doc","_id":"1","_score":0.2876821,"_source":{"user":"luoluocaihong","age":"20"}}]}}

-- 查看集群设置
curl 172.16.22.51:9200/_cluster/settings

-- 修改集群设置
curl 172.16.22.51:9200/_cluster/settings -X PUT  -H 'Content-Type:application/json' -d '{"transient":{"cluster.routing.allocation.disk.watermark.low":"80%","cluster.routing.allocation.disk.watermark.high":"85%","cluster.routing.allocation.disk.watermark.flood_stage":"90%"}}'
{"acknowledged":true,"persistent":{},"transient":{"cluster":{"routing":{"allocation":{"disk":{"watermark":{"low":"80%","flood_stage":"90%","high":"85%"}}}}}}}  

-- 检查索引状况
curl http://172.16.22.51:9200/_cat/indices
green open idx_luoluocaihong 3iS68s1nQMudxhyL-zNnRg 5 1    2    0  17.4kb   8.7kb

-- 检查es集群健康状况
curl 172.16.22.51:9200/_cluster/health?pretty
{
  "cluster_name" : "iot-es",
  "status" : "green",
  "timed_out" : false,
  "number_of_nodes" : 3,
  "number_of_data_nodes" : 3,
  "active_primary_shards" : 15,
  "active_shards" : 30,
  "relocating_shards" : 0,
  "initializing_shards" : 0,
  "unassigned_shards" : 0,
  "delayed_unassigned_shards" : 0,
  "number_of_pending_tasks" : 0,
  "number_of_in_flight_fetch" : 0,
  "task_max_waiting_in_queue_millis" : 0,
  "active_shards_percent_as_number" : 100.0
}

-- 删除索引
curl http://172.16.22.51:9200/idx_luoluocaihong  -X DELETE



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

retrying failed action with response code: 429 ({“type“=>“es_rejected_execution_exception“, “reason“ retrying failed action with response code: 429 ({“type”=>“es_rejected_execution_exception”, “reason”=>“rejected execution of processing of [2270115][indices:data/write/bulk[s][p]]: request: BulkShardRequest [[ami-2022.01.11][1]] containing [88] reque 阅读详情

相关推荐

Elasticsearch实战系列(一)---ES简介

1.什么是搜索引擎,能解决什么样的问题? 快速的返回搜索结果或者相应的统计信息,即解决快速搜索的问题 引擎可以快速的返回查询结果,而且这些结果都是相关的 搜索引擎还能提供辅助搜索的功能,这些辅助功能包括识别错误输入,给出自动提示,并对结果进行分类 2.什么是ES? ES是构建在Lucence基础之上的开源分布式搜素引擎,Lucene是个高性能的搜索引擎包,默认情况下将所有的数据全部进行索...

吴小豪的博客 507

解决elk报错,索引变成只读状态。

解决elk报错,索引变成只读状态

lzy_zhi_yuan的博客 2197

Elasticsearch 磁盘空间异常排查过程

分片大小差不多的情况下,节点 76 的分片数还比别的节点还少 10 个左右,它的磁盘空间反而多占用了 8TB。这是不是太奇怪了?事出反常必有妖,继续往下查。

yonggeit的博客 4250

Elasticsearch存储空间不够导致索引只读的解决方法

为什么80%的码农都做不了架构师?>>> ...

weixin_34127717的博客 3268

ElasticSearch删除索引【真实案例】

删除ElasticSearch索引的真实案例,以及介绍当时遇到的删除超时问题的解决方案。

甘蓝的专栏 3167

Linux系统搭建OpenClaw(原Clawdbot)全流程指南 最新版

工具定位:开源个人 AI 助手,支持文件读取、命令执行、多渠道交互(Telegram / 本地终端等);系统要求:主流 Linux 发行版(Ubuntu/Debian/CentOS 等),Node.js ≥22(核心依赖);安全提示:OpenClaw 为测试版,具备高权限操作能力,建议使用非主力机,配置权限白名单,避免接触敏感数据。

AI时代老码农的第二春 6569

ElasticSearch 因为磁盘空间不够引起的数据插入错误

错误描述: ElasticSearch 因为磁盘空间不够引起的数据插入错误。(message [ClusterBlockException[blocked by: [FORBIDDEN/12/index read-only / allow delete (api)];]]) 当使用Logstash将MySQL中的数据采用到ES索引中: 出现以下问题, 昨天还可以正常采集mysql数据库中的信息, 今天报了错,解决方案如下: 问题原因: 索引变成了只读 index read-only / allow del

Guizy 3035

实例讲解MOS管电源开关电路的软启动

1、控制电源开关的输入信号 Control 为低电平或高阻时,三极管Q2的基极被拉低到地,为低电平,Q2不导通,进而MOS管Q1的Vgs = 0,MOS管Q1不导通,+5V_OUT 无输出。此时将 Control 设为低电平,三极管Q2关闭,电容C1与G极相连端通过电阻R2放电,电压逐渐上升到5V,起到软关闭的效果。不过从作者的描述来看,只是电路参数有区别,能通过的电流、能承受的耐压等不一样,但是软启动的原理是一样的。从公式可以看出,当电容容量越大,电压越高,时间越短,电流就会越大,从而形成浪涌电流。

U_YAO的博客 2万+

搜索引擎 Elasticsearch 的三大坑

Elasticsearch 现在是用得越来越多了,比如我们日志系统中用到的 ELK 就用到了(简称 ES)。那对于搜索这种技术来说,最看重的是搜索的结果的准确性和搜索的响应时间。ES 的准确性可以通过 倒排索引算法来保证,那响应时间就需要磁盘或缓存来支持了,那么磁盘和缓存会带来哪些坑呢?( 其实不论是分布式的,还是单机模式下的搜索引擎都会遇到这个问题。

悟空聊架构的专栏 5548

三相电路小白必看:正弦量向量表示法保姆级教程(附欧拉公式推导)

本文为电气工程初学者详细解析了三相电路中正弦量的向量表示法,即相量法。通过几何直观和欧拉公式推导,阐明如何将时变正弦量转化为静态复平面向量进行运算,并利用平行四边形法则简化同频正弦量的加减计算。文章结合Python代码进行可视化验证,帮助读者牢固掌握这一分析交流电路的核心工具。

linux6sysadmin的博客 1010

microblaze之Video Processing Subsystem调试误区

内容:总结video processing subsystem调试中遇到的问题,以及在解决问题中的思路方法论,引为前车之鉴。 1,我的目的是希望采用vps中的scaler模块对图像进行拉伸缩小。IP的配置如下: 2,整个系统的框架图如下,仅比上期的内容增加了scaler模块,如下: 3,查手册,可以知道这个scaler only组件分成了hscale,vscale和GPIO,其中GPIO是控制上下游stream流控设备复位用,暂时忽略。 hscale和vscale的寄存器空间如下,主要关注图

YDY5659150的专栏 3567

Elasticsearch节点磁盘空间耗尽

最近遇到了一个特殊的情况,我们所使用的一个Elasticsearch集群的数据节点磁盘空间耗尽,啥事会发生呢? 当然你的RED。下面是相关的日志信息,其中ES-Data_11是当时的Master节点,ES-Data_12是出现的磁盘耗尽的数据节点,出事儿的index名字为raw_v3.2017_03_22。 [2017-03-22 11:57:30,503][WARN ][index

Jeffrey Zhou 的专栏 1万+

【技术纵览】行为识别前沿模型演进:从CNN到多模态大模型

本文全面解析了行为识别技术从CNN到多模态大模型的演进历程,重点介绍了SlowFast、TimeSformer、VideoMAE和InternVideo等SOTA模型的核心创新与应用实践。通过对比分析各代模型在Kinetics-400等数据集上的表现,揭示了自监督学习和多模态融合如何推动行为识别准确率突破85%,并探讨了工业部署中的技术选型策略与优化方向。

weixin_29169505的博客 163

[转]基于Elasticsearch分布式搜索引擎的架构原理

[转]基于Elasticsearch分布式搜索引擎的架构原理 http://www.mobabel.net/%E8%BD%AC%E5%9F%BA%E4%BA%8Eelasticsearch%E5%88%86%E5%B8%83%E5%BC%8F%E6%90%9C%E7%B4%A2%E5%BC%95%E6%93%8E%E7%9A%84%E6%9E%B6%E6%9E%84%E5%8E%9F%E7%90...

yb223731的博客 1014

整车 EOL下线 测试系统介绍

整车下线(EOL)测试专门针对整车进行设计开发,是车企将组装好的整车交付客户前的 最后一道检测工序。EOL 测试针对的是整车下线测试,不同于零部件下线,是整车级别的下线 测试,测试过程关系整车的每个零部件,其测试质量直接影响到整车的质量好坏。因此,整车EOL测试是整车下线必不可少的测试过程.

王小奎的博客 5525

KylinOS 离线安装 MinIO【图文步骤】

在国产操作系统 KylinOS 中安装 MinIO,详细步骤...

甘蓝的专栏 1548

ES(ElasticSearch)分布式全文搜索引擎介绍及使用方式

什么是ES **ES** 全称 **ElasticSearch** 是一种分布式全文搜索引擎,基于Lucene(全文搜索框架)开发而来。 Lucene是公认的迄今为止的最好用的搜索引擎库,但是他所提供的API对于我们使用者来说,是非常苦恼的,常要花费大量时间去熟悉学习。ES的出现就很好的解决了这个问题,良好的封装,易用的API,链式书写方式,开瓶即饮。 ES的特点 **ES** 虽然是以Lucene核心库开发的,但是却不是以它作为核心,**ES** 的特点: *分布式实时文件存储,每个字...

喜欢猪猪 1246

DeepSeek + 微信:手把手教你把 AI 接入个人微信,秒变“高情商”聊天助手(防封指南)

将 DeepSeek 接入微信,本质上是给你的微信装了一个**“最强外挂”**。它不仅能帮你回消息,还能帮你写周报、查资料、甚至陪聊解闷。工具是服务于人的,不要让 AI 完全替代了你的真情实感。毕竟,真正的高情商,是屏幕背后那个在乎对方的你。先申请一个小号,按照步骤跑通流程。然后试着调整 Prompt,训练一个属于你自己的“嘴替”吧!

BUG猿的博客 975

【ES】Elasticsearch常见问题与日常随笔(持续更新)

Elasticsearch (ES) 是一个强大的开源搜索和分析引擎,广泛用于全文搜索、日志和数据分析等场景。由于其复杂性,用户可能会遇到各种问题。

慕白Lee的博客 5804

C# WinForm 基于DirectShow.dll编写的程序,可边预览边保存视频,音频和图片

基于微软的DirectShow.dll的二次开发1.自动识别连接的摄像头跟麦克风且可以对其进行选择(默认选中第一个)2.可录制wmv和avi两种格式的视频并且都带有音频,avi可以录制的分辨率和帧数进行选择,wmv默认进行了淸晰度优化如不喜欢可去除代码中有相关提示3.可在预览点开之后进行拍照,也可边录制视频边拍照4.添加了视频和音频的压缩功能(酌情使用)这次二次开发发现C#对DirectShow的相关信息太少,这次做完也不敢藏私共享出来,还望大家指正

jre9下载 jdk9

(Java SE Runtime Environment 9.0) 9.0u175 官方最新版 【x86|x64】

elasticsearch磁盘空间满了故障处理思路

昨天接到客户投诉说ES数据目录已达到100%了,当时第一想法监控组怎么监控的80%报警为什么没有监控出啦,经问,监测组是几天前接到报警,并忽略了,我当时那个崩溃,并有想骂人的冲动,这是现网,不是测试时环境,竟然有这么不负责的同事我也是醉的,我登录服务器一看磁盘空间最糟的100%,另几个99%,刚搭建两个月的集群出现空间不足,当时说没有这么大的数据量,我自己给自己挖了一个大坑,把数据存在一个磁盘上。

蘑菇丁的专栏 2万+

老版QQ原生表情gif动态

这是老版的QQ表情,不过全是动态的的,Windows照片查看器是不会动的,可以右击用浏览器打开查看,再说一遍是老版的,只是分享给宁愿用老版也要动态的人。

解决 Elasticsearch 写操作磁盘空间问题——cluster_block_exception

在运行 Elasticsearch 集群遇到磁盘空间不足的情况时,Elasticsearch 会采取保护措施以防止数据丢失。错误,特别是当错误消息表明索引被设置为只读模式时。

后端开发 1609

Elasticsearch 启动失败?从日志分析到最终解决(磁盘空间不足案例)

Spring Boot 项目启动后,ES 操作正常,不再报超时错误。ES 真正的日志在 logs/elasticsearch.log。,但 Java 应用就是连不上!:ES HTTP 接口正常,但 Java 客户端无法连接。,但 HTTP 接口可能仍然能访问(误导性现象)。,适用于类似 ES 启动失败、连接超时等场景。,而不是 Windows 服务日志(导致 ES 无法正常写入数据。看起来没问题,但为什么连不上?,导致 ES 无法写入数据!,不要只看服务控制日志。,不一定是网络问题。

Leaton的博客 1626

elasticsearch 运维中遇到的问题

[2020-12-22T16:28:07,485][INFO ][logstash.outputs.elasticsearch][main][7a9bd902efcf008d8e54ca5c1eae1bb97fe2712e0be94b53b9e2a59022ef3172] retrying failed action with response code: 503 ({"type"=>"unavailable_shards_exception", "reason"=>"[log-app-tclo

h952520296的博客 6707

ElasticSearch搜索引擎原理,都给你整理好了

“最近接触的几个项目都使用到了 Elasticsearch (以下简称 ES ) 来存储数据和对数据进行搜索分析,就对 ES 进行了一些学习。本文整理自我自己的一次技术分享。本文不会关注 ...

独行侠梦的博客 3587

精准优化Elasticsearch:磁盘空间管理与性能提升技巧20241106

通过以上方法,你可以系统性地优化Elasticsearch的磁盘空间和性能。良好的索引管理、日志控制和资源隔离,配合实时监控与合理的内存设置,将帮助你构建一个高效、可维护的Elasticsearch集群。

Narutolxy的博客 1410
上一篇: Prometheus 报警规则配置
下一篇: Kubernetes 性能的 Prometheus Operator 指标
mnasd
博客等级 码龄16年 242粉丝 120原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值