- 博客(74)
- 资源 (1)
- 收藏
- 关注
原创 k8s容器驱逐之ephemeral-storage
1.容器被驱逐,首先比较直观的是查看EventThe node was low on resource: ephemeral-storage.Container zk was using 910316Ki, which exceeds its request of 0.2.原因cat /etc/docker/daemon.json{ "exec-opts": ["native.cgroupdriver=systemd"], "log-driver": "json-f...
2022-03-11 11:25:08
6911
原创 maxwell元数据问题
1.问题"Couldn't find table xxx in xxxx 相关的schema问题2.分析2.1代码本身存在缺陷saveSchema缺少savePosition2.2DBA相关的操作rename table `test`.`user` to `test`.user_bak;rename table dev.user to `test`.`user`;在此场景下缺少schema的处理解决方案BinlogConnectorReplicator下针对捕获..
2022-02-28 16:21:14
378
1
原创 流量回放goreplay
1.网关权重99/1旁路2.goreplay编译测试<==============================/usr/local/go/pkg/tool/linux_amd64/link: running gcc failed: exit status 1/bin/ld: cannot find -lpthread/bin/ld: cannot find -lc===============================>yum install glibc-stati
2021-12-31 15:53:01
684
原创 k8s-hpa
一、 产线当前是基于cpu和memory,当前考虑增加QPS来做HPA二、指标来源 应用容器自身采集、ingress-nginx-controller采集、 外部网关、 外部SLB三、步骤(测试)1、使用prometheus采集ingress-controller的指标(其他一样)2、helm部署prometheus-adapter-3.0.0.tgz3、配置prometheus-adapter自定义指标4、check指标函数以及ab测试1. - serie.
2021-12-17 18:03:32
2067
1
原创 maxwell时间timestamp
DateFormatter.javapublic static String formatDateTime(Object value, Timestamp ts, Time needCheckCdtFirstTime,boolean isTimestamp) { Calendar cal; Integer hour = null; if ( value instanceof Long ) { cal = isTimestamp && !MaxwellCon.
2021-10-20 15:45:57
901
原创 gRPC-client
import com.aaa.service.grpc.*;import io.grpc.Channel;import io.grpc.ManagedChannel;import io.grpc.ManagedChannelBuilder;import io.grpc.StatusRuntimeException;import io.grpc.stub.StreamObserver;import java.util.HashSet;import java.util.Set;impor...
2021-09-28 18:59:13
322
原创 python客户端登录容器
#nginx:location / { alias D:\\workplace\\UI\\dist\\;}location /api/ws/{ proxy_pass http://127.0.0.1:9090/ws/; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade";}location /api/ { proxy_pass http://127.0.0.1:9090/;}.
2021-09-27 18:54:12
384
原创 MutatingWebhookConfiguration升级
1.GitHub - caesarxuchao/example-webhook-admission-controller: An example of Kubernetes wehbook admission extensionAn example of Kubernetes wehbook admission extension - GitHub - caesarxuchao/example-webhook-admission-controller: An example of Kubernetes we
2021-09-27 17:17:48
986
原创 k8s1.20 问题https
1. 客户的 openssl 命令不支持 k8s 1.20 ,原因:https://github.com/kubernetes/kubernetes/pull/932642. 脚本修改 openssl 命令:https://github.com/kapicorp/kapitan-reference/pull/37/files#diff-9785650370c1ae0b43edde51b02a777e4ca883a2337091d8cae54a076680c7d4...
2021-09-17 10:16:15
223
原创 uwsgi
server { autoindex on; listen 80; server_name localhost; access_log logs/hello.access.log main; location / { alias /opt/apps/ui/dist/; } location /api { .
2021-09-03 11:18:50
115
原创 CDN+OSS
server { listen 8080; server_name localhost; #charset koi8-r; #access_log logs/host.access.log main; location ~/(.*)/(.*)/(.*) { set $env $1; set $type $2; set $other $...
2021-09-03 10:37:02
171
原创 Vue+CDN+HISTORY
location /aaa/go{ rewrite ^/(.*) /_index; } location /_index { proxy_pass http://xxxxxxxxxx.oss-cn-hangzhou.aliyuncs.com/aaa/index.html; proxy_set_header Host xxxxxxxxxx.oss-cn-han...
2021-08-28 17:30:59
282
原创 2021-07-22
1.弹性2.架构升级3.混部(在线、离线)4.大集群和小集群 公司内建议集群控制数量5-6个5.大节点+少 32G 64G6.java至少1:4 7.节点池1:4 + 1:88.阿里云+华为云 容灾9.华为MCP10.istio+serviceMesh------服务治理---11.容器安全12.监控(3) k8s本身的 业务 底层资源13.k8s备份-安全 华为是怎么建议?helm安装?有没有必要? 14.Flink大数据上...
2021-07-22 12:21:35
96
原创 beego跨域
beego.InsertFilter("*", beego.BeforeRouter, cors.Allow(&cors.Options{ AllowAllOrigins: true, AllowOrigins: []string{"*"}, AllowMethods: []string{"*"}, AllowHeaders: []string{"MyTokenHeader","Origin", "Authorization", "Access-Control-Allow-Orig.
2021-07-14 13:43:26
328
原创 go-makefile
.DEFAULT_GOAL := docker-imageIMAGE ?= registry.cn-hangzhou.aliyuncs.com/----------/cicdapi:v1image/app: $(shell find . -name '*.go') CGO_ENABLED=0 GOOS=linux go build -ldflags="-s -w" -o $@ ./.PHONY: docker-imagedocker-image: image/app .
2021-06-28 10:17:47
100
原创 jumpserver资产录入
1.clear-testtruncate table ops_adhoc_hosts;TRUNCATE table assets_asset_nodes;TRUNCATE table assets_systemuser_assets;delete from assets_asset;update assets_node set assets_amount=0;2.cmdb--->jumpserver--api def get_token(self): #
2021-04-21 11:58:51
450
原创 XXL-JOB-LDAP
package com.xxl.job.admin.core.conf;import org.springframework.beans.factory.annotation.Value;import org.springframework.context.annotation.Bean;import org.springframework.context.annotation.Configuration;import org.springframework.ldap.core.LdapTemp.
2021-03-29 19:18:07
759
原创 k8s-cephfs-test
[root@master ~]# kubectl versionClient Version: version.Info{Major:"1", Minor:"20", GitVersion:"v1.20.4", GitCommit:"e87da0bd6e03ec3fea7933c4b5263d151aafd07c", GitTreeState:"clean", BuildDate:"2021-02-18T16:12:00Z", GoVersion:"go1.15.8", Compiler:"gc"...
2021-03-05 19:45:34
430
原创 k8s部署Prometheus
https://github.com/prometheus-community/helm-chartsjust test1.k8s test cluster2.创建pv#######/data 是###########hostPath手动创建两个目录、创建2个pv/var/lib/disk3/data/1/var/lib/disk3/data/2chown 1000:1000 -R /data/启动问题(https://github.com/prometheus/prometheus.
2021-02-26 13:41:49
428
原创 Flink-Phoenix-HBase
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/flink/calcite/shaded/com/google/protobuf/MessageOrBuilder at org.apache.calcite.avatica.remote.HADriver.createService(HADriver.java:72) at org.apache.calcite.avatica.remote.Driver.cre.
2020-12-15 11:37:07
1632
1
翻译 helm-charts副本循环
原文:https://stackoverflow.com/questions/53973887/helm-simple-for-loop[root@master templates]# lsheadless-srv.yaml _helpers.tpl out-srv.yaml statefulset.yaml ui-srv.yaml[root@master templates]# cat out-srv.yaml {{- $num := 5 -}}{{- range $index :.
2020-12-02 16:51:52
741
原创 centos7-mysql5.7-client
1卸载centos7的原版的mysql-clientrpm -e mariadb-libs-5.5.68-1.el7.x86_64rpm -e mariadb-5.5.68-1.el7.x86_64rpm -e mariadb-libs-5.5.68-1.el7.x86_642.安装yum -y install http://dev.mysql.com/get/mysql57-community-release-el7-10.noarch.rpmyum -y install mysqlyu
2020-12-02 14:17:34
459
原创 airflow流程中断
airflow流程中断1.概要 在airflow流程中,有时候需要按条件中断,这里借助分支实现2.示例 zk和kafka部署(下图只部署kafka)。3种情况 1-只部署zk | 2-只部署kafka | 3-同时部署3.BranchPythonOperator# !/usr/bin/python# -*- coding: utf-8 -*-import jsonfrom airflow import DAGfro...
2020-11-12 17:36:54
1289
1
原创 nginx+iview-admin 404
iview-adminmode:history刷新页面404错误解决办法:nginx配置 server { listen 8087; server_name localhost; root E:\workspace\vue_work\my-iview-admin\dist; location / { try_files $uri $uri/ @router; index i.
2020-08-03 12:50:52
422
原创 k8s+nginx+ldap
一、场景 公司内部使用ldap做统一认证,k8s上某些如:skywaking(无账号有敏感信息)、kibana等服务接入账号验证,正好使用nginx反向代理,且有ldap模块。二、准备文件git clone https://github.com/chaoslawful/lua-nginx-module.git (v0.10.14)git clone https://github.com/openresty/luajit2 (v2.1-ag...
2020-07-11 09:21:00
603
原创 nginx+lua编译安装
FROM debian:buster-slimCOPY sources.list /etc/apt/sources.listARG SRC=/usr/local/src/ADD lua-nginx-module $SRC/lua/ADD ngx_devel_kit-0.2.19 $SRC/kit/ADD nginx-auth-ldap $SRC/ldap/ADD luajit2 $SRC/luajit/ADD nginx-1.19.1.tar.gz $SRCRUN ap.
2020-07-11 03:22:02
363
原创 seata分布式解决中间件
1.调研最近可能要用到seata,调研一下比较好的网上教程 springboot(springcloud、springmvc) + zookeeper或者nacos +dubbonacos https://github.com/mkyuangithub/mkyuangithub/ zookeeper https://blog.youkuaiyun.com/ssyujay/article/details/105851718 2.集成老项目spring-mvc是动态主从多数据源...
2020-05-09 16:27:11
360
原创 jupyter-api-test
import com.alibaba.fastjson.JSON;import com.alibaba.fastjson.JSONObject;import org.apache.http.HttpStatus;import org.apache.http.NameValuePair;import org.apache.http.client.CookieStore;import o...
2020-02-18 17:33:16
877
原创 jupyter-api调用
#!/usr/bin/python# -*- coding: UTF-8 -*-import jsonimport requestshost='自己域名'login_url = host+"/hub/login"r = requests.post(login_url, data={'username': 'tom', 'password': '123456'}, allow_re...
2020-02-14 12:28:09
3295
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人