会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
lixinliang
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
···
22
下一页
2024年2月18日
nginx ip分流
摘要: 需求 将尾号ip为 0或者 为具体ip 的真实用户转发至其他云服务上 架构 阿里云slb--> k8s nginx ingress --> nginx pod (以下nginx 配置为nginx pod里的转发配置) nginx ip分流 (以ip尾号为0或者1 的客户端ip进行分流) root /
阅读全文
posted @ 2024-02-18 17:31 lixinliang
阅读(127)
评论(0)
推荐(0)
2024年1月20日
linux修改max user processes limits
摘要: 突破ulimit 限制 修改普通用户单个用户可同时运行的最大进程数 (默认为 4096 ) [root@xxx devops]# cat /etc/security/limits.d/20-nproc.conf # Default limit for number of user's process
阅读全文
posted @ 2024-01-20 12:02 lixinliang
阅读(950)
评论(0)
推荐(0)
2023年12月15日
linux 监控目录大小并配置告警
摘要: 配置目录大小监控 #!/bin/bash #cd /nfs1/ExternalPersonnel cd /nfs1/ExternalPersonnel capacitydata=`du -sh data |awk '{print $1}'` capacityhome=`du -sh home |aw
阅读全文
posted @ 2023-12-15 10:39 lixinliang
阅读(143)
评论(0)
推荐(0)
2023年11月8日
k8s cronjob
摘要: k8s cronjob 任务模版 k8s cronjob 任务模版 cat > ${k8s_resource_list}-cronjob.yaml << EOF apiVersion: batch/v1beta1 kind: CronJob metadata: name: ${k8s_resourc
阅读全文
posted @ 2023-11-08 11:43 lixinliang
阅读(21)
评论(0)
推荐(0)
2023年10月12日
python 删除es指定字段数据
摘要: 需求: 删除es 中指定IP 相关的数据 (remoteAddr: ip) 日志格式 fields.product:wantwords_zxxxx_feature @timestamp:Oct 12, 2023 @ 18:56:39.000 date_timeLocal:12/Oct/2023:18
阅读全文
posted @ 2023-10-12 18:59 lixinliang
阅读(229)
评论(0)
推荐(0)
2023年8月30日
k8s service 增加会话保持模式
摘要: ### 会话保持模式 - 基于客户端地址的会话保持模式,即来自同一个客户端发起的所有请求都会转发到固定的一个Pod上。此模式可以使在spec中添加sessionAffinity:ClientIP配置 ``` # service 中增加 sessionAffinity: ClientIP ; 默认 s
阅读全文
posted @ 2023-08-30 10:22 lixinliang
阅读(656)
评论(0)
推荐(0)
2023年8月25日
crictl和ctr
摘要: ### crictl和ctr的用法 ``` crictl是遵循CRI接口规范的一个命令行工具,通常用它来检查和管理kubelet节点上的容器运行时和镜像 ctr是containerd的一个客户端工具, 接下来就是crictl的的常见命令,其中能完全替代docker命令的参照下列表格 操作 crict
阅读全文
posted @ 2023-08-25 14:10 lixinliang
阅读(674)
评论(0)
推荐(0)
2023年8月24日
filebeat 配置采集nginx 日志
摘要: ### filebeat 配置nginx 日志采集 - filebeat 采集需求 ``` 1.需要将以往30 天的日志输出到es,并且以时间按天展示 2.将不同的时间字段解析出来,输出到es ``` - nginx 配置json 日志 ``` log_format log_json '{ "rem
阅读全文
posted @ 2023-08-24 21:03 lixinliang
阅读(917)
评论(0)
推荐(0)
2023年8月22日
未配置nginx 域名的返回 403
摘要: ### 防止恶意ip绑定至服务器公网ip地址 ``` server { listen 80 default; listen 8088 default; server_name _; return 403; } ```
阅读全文
posted @ 2023-08-22 12:12 lixinliang
阅读(70)
评论(0)
推荐(0)
2023年8月21日
pod 反亲和测试验证
摘要: ### 场景需求 ``` node 节点上不允许有两个一样的pod,即每个节点上每个应用仅仅允许一个pod 运行 ``` - 测试yaml ``` [root@k8sNode0 podqinhexing]# cat test.yaml apiVersion: apps/v1 kind: Deploy
阅读全文
posted @ 2023-08-21 20:44 lixinliang
阅读(103)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
···
22
下一页
公告