es磁盘满了无法写入的处理办法
环境:
OS:Centos 7
es:6.8.5
1.查看index的只读状态
-bash-4.2$ curl -u elastic:elastic -H "Content-Type: application/json" -XGET "http://192.168.1.109:19200/app_message_all/_settings?pretty=true"
{
"app_message_all" : {
"settings" : {
"index" : {
"number_of_shards" : "5",
"blocks" : {
"read_only_allow_delete" : "true"
},
"provided_name" : "app_message_all",
"creation_date" : "1698133863992",
"number_of_replicas" : "1",
"uuid" : "Df6FxfizTSmeClUu9rom9g",
"version" : {
"created" : "6080599"
}
}
}
}
}
-bash-4.2$ curl -u elastic:elastic -H "Content-Type: application/json" -XGET "http://192.168.1.109:19200/.security-6/_settings?pretty=true"
{
".security-6" : {
"settings" : {
"index" : {
"number_of_shards" : "1",
"auto_expand_replicas" : "0-1",
"blocks" : {
"read_only_allow_delete" : "true"
},
"provided_name" : ".security-6",
"format" : "6",
"creation_date" : "1698054370201",
"analysis" : {
"filter" : {
"email" : {
"type" : "pattern_capture",
"preserve_original" : "true",
"patterns" : [
"([^@]+)",
"(\\p{L}+)",
"(\\d+)",
"@(.+)"
]
}
},
"analyzer" : {
"email" : {
"filter" : [
"email",
"lowercase",
"unique"
],
"tokenizer" : "uax_url_email"
}
}
},
"priority" : "1000",
"number_of_replicas" : "0",
"uuid" : "GWBAK8K8SjmIMraSC2rhpQ",
"version" : {
"created" : "6080599"
}
}
}
}
}
2.关闭磁盘告警
curl -X PUT "192.168.1.135:19200/_cluster/settings?pretty" -H 'Content-Type: application/json' -d'
{
"transient": {
"cluster.routing.allocation.disk.watermark.low": null,
"cluster.routing.allocation.disk.watermark.high": null,
"cluster.routing.allocation.disk.watermark.flood_stage": null
}
}
'
3.设置索引read_only状态
curl -H "Content-Type: application/json" -XPUT 'http://192.168.1.135:19200/.security-6/_settings' -d '{
"index.blocks.read_only_allow_delete" : null
}'
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· DeepSeek 开源周回顾「GitHub 热点速览」
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!
· AI与.NET技术实操系列(二):开始使用ML.NET
· 单线程的Redis速度为什么快?
2021-04-27 centos7 图形界面启动