首页
Search
1
v2ray异常错误之二
3,310 阅读
2
linux时区设置
2,698 阅读
3
DB2常用操作
2,173 阅读
4
websphere修改jvm内存xmx和xms
1,929 阅读
5
nfs客户端文件属主为nobody的现象
1,552 阅读
技术
生活
运动
游戏
电影
登录
Search
标签搜索
docker
linux
troubleshooting
nginx
secure
truenas
mysql
windows
python
esxi
docker swarm
oracle
zabbix
tomcat
blog
dsm
群晖
rpa
freenas
db
yuc
累计撰写
291
篇文章
累计收到
0
条评论
首页
栏目
技术
生活
运动
游戏
电影
页面
搜索到
289
篇与
的结果
2022-06-07
jenkins打包出现的域名解析问题
0x1 某分支打包失败,通过日志查看到如下错误: stack: Error: getaddrinfo ENOTFOUND cdn.npmmirror.com at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) [npminstall:get] retry GET https://registry.npmmirror.com/caniuse-lite/-/caniuse-lite-1.0.30001349.tgz after 100ms, retry left 4, error: Error: getaddrinfo ENOTFOUND cdn.npmmirror.com at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) { errno: -3008, code: 'ENOTFOUND', syscall: 'getaddrinfo', hostname: 'cdn.npmmirror.com', name: 'RequestError', data: undefined, path: '/packages/caniuse-lite/1.0.30001349/caniuse-lite-1.0.30001349.tgz', status: -1, headers: {}, res: [Object] }, status: -1, headers: {}, 错误是挺明显的,地址无法解析到,并且是下载nodejs模块的过程中。接着在服务器上测试了下,确实无法访问: # 使用ping [root@localhost product-docs]# ping cdn.npmmirror.com ping: cdn.npmmirror.com: 未知的名称或服务 # 使用nslookup > server 192.168.10.184 Default server: 192.168.10.184 Address: 192.168.10.184#53 > cdn.npmmirror.com ;; Truncated, retrying in TCP mode. ;; Connection to 192.168.10.184#53(192.168.10.184) for cdn.npmmirror.com failed: connection refused. 但这里有个疑问,应该一直是使用的淘宝源,这个地址倒是第一次见到,于是粘贴到浏览器访问,确实是访问到了新地址上,那么可以确定源是没有问题的,依旧是淘宝,是地址访问的问题。 0x2 继续查看nslookup报错的信息,可以看到尝试使用tcp模式,但接下来访问tcp端口出现异常,可以继续排查dns问题了。进入dns服务器查询端口情况,发现确实没有监听,重启解决 0x3 此问题与这个问题一致: https://yuc.pub/uncategorized/295/ 0x4 之前是重启过dns服务的,但没有监听tcp就比较异常,而且重启过程中也没有报错,如何解决呢?
2022年06月07日
770 阅读
0 评论
0 点赞
2022-05-30
elasticsearch磁盘空间的问题
问题现象 selenium定时截图kibana,但是发现数据连续几天都是一样的,感觉好久没有更新了一样,怀疑是查询有问题,尝试登录kibana手动执行查询,但有如下报错: 排查经过 排查了kibana,logstash日志中有报错,但都没有明显的相关内容,那只能继续排查elasticsearch日志,在日志文件logcheck.log中发现了明显的异常: [2022-05-30T14:20:24,401][WARN ][o.e.c.r.a.DiskThresholdMonitor] [lognode1] high disk watermark [90%] exceeded on [1__xs753R3uOME1Sugp4kg][lognode1][/data/elfk/els/data/nodes/0] free: 181gb[5.1%], shards will be relocated away from this node; currently relocating away shards totalling [0] bytes; the node is expected to continue to exceed the high disk watermark when these relocations are complete 可以看到告警提示高水位线90%,于是我们查询服务器磁盘空间,确实目录使用率已经超过了90%了。清理空间后解决。 感悟 这个问题一开始的提示太模糊了,以致于我们排查了整个elfk日志才能定位,而且如果我们只是排查服务器性能,那么90%+的空间使用率也算正常,无法直接显示出问题在哪里,最后要么对elasticsearch特性很熟悉,要么对els故障排查熟悉,否则还是需要耗费一定时间的。 最后我们看看els关于空间的说明: https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-cluster.html#disk-based-shard-allocation
2022年05月30日
855 阅读
0 评论
0 点赞
2022-05-30
windows10激活
0x1 windows10激活 windows分家庭版,专业版,企业版等,key需要符合版本,以下是专业版的key,每个步骤需要回显后才能下一步 slmgr /ipk W269N-WFGWX-YVC9B-4J6C9-T83GX slmgr /skms kms.03k.org slmgr /ato 0x2 office激活 cd "C:\Program Files (x86)\Microsoft Office\Office16" cscript ospp.vbs /sethst:kms.03k.org cscript ospp.vbs /act
2022年05月30日
1,017 阅读
0 评论
0 点赞
2022-05-27
jenkins构建docker镜像
背景 因为有用户需要容器化运行,需要我们提供镜像,但镜像构建分发还是比较麻烦的,涉及到如下步骤: 下载此版本最新的war包 构建war包为镜像 推送到仓库 如果总是人工操作必然会浪费很多时间,于是使用jenkins来提供自动化的流程 注意点 因为Dockerfile/启动脚本的以后可能会修改,这部分我们使用git托管起来,使用jenkins构建的时候也能自动拉取最新代码 流程 jenkins中先拉取代码 jenkins中调用脚本拿到war包,并且获取war包的版本 把脚本从本地发送到远端进行构建,如果是本地就更方便一点了! 远程机器获取到war版本,设置新镜像名称,根据传送过来的文件中的dockerfile进行构建 构建完成后推送至镜像仓库 代码部分 镜像的dockerfile FROM harbor.xxx.com/base/xxx-centos:7.6-2020120414 COPY dirs/ /usr/local/ COPY ROOT.war start.sh /opt/ CMD sh -x /opt/start.sh dockerfile中的启动命令 #!/bin/bash # # 提供了三个参数: # MEM用来设置内存大小,未设置为1G # SERVICE来设置war名,上下文,否则为ROOT # CLUSTER设置集群ip前缀,docker私有ip有多个,如果做web集群,需要指定能容器之间互通的段 mem=0 war=0 cluster=0 if [ ! -z "${MEM}" ];then if echo ${MEM} | grep "^[[:digit:]]*$" &> /dev/null;then if [ ${MEM} -gt 31 ];then MEM=31 fi mem=1 fi fi if [ ! -z "${SERVICE}" ];then if [ -z "$(echo ${SERVICE} | tr -d '0-9A-Za-z')" ];then if ! echo ${SERVICE} | egrep "^[0-9]|[0-9]$" &> /dev/null;then war=1 fi fi fi if [ ! -z "${CLUSTER}" ];then cluster=1 fi if [ ${cluster} -eq 1 ];then export JAVA_OPTS="-Dsucc.clusterBindAddressPrefix=${CLUSTER}" fi if [ ${mem} -eq 1 ];then sed -i "s/1g/${MEM}g/g" /usr/local/tomcat/bin/catalina.sh fi if [ ${war} -eq 1 ];then cp -a /usr/local/tomcat/ROOT /usr/local/tomcat/webapps/ cp -a /opt/ROOT.war /usr/local/tomcat/webapps/${SERVICE}.war else cp -a /opt/ROOT.war /usr/local/tomcat/webapps/ fi /usr/local/tomcat/bin/catalina.sh start tail -f /etc/getcode/code jenkins部分 this="镜像-4.19.3" release_root="/var/jenkins_home/jobs/bi-4.19.3/workspace/bi" src_FILE="${release_root}/com.succez.bi/dist/ROOT.war" dst_FILE="/var/jenkins_home/jobs/${this}/workspace/ROOT.war" if [ ! -f "${src_FILE}" ];then echo "war包不存在" exit 1 fi \cp -rfa ${src_FILE} ${dst_FILE} version=$(cat ${release_root}/com.succez.bi/src/main/java/META-INF/succ-product.json | grep "version" | awk '{print $2}' | tr -d "\",") echo ${version} > /var/jenkins_home/jobs/${this}/workspace/version 文件传输 文件传输到远程机器使用的jenkins的sftp传输插件,在后台配置server登录账号密码后,在前端设置本地路径和目的路径。 本地路径是以workspace为参照的相对目录,表示当前所有文件,如果下级目录下的所有文件需要两个 目的路径需要写绝对目录 Remove prefix,如果本地目录中的目录层级需要移除,那么写入 后续脚本 cd /usr/local/build/release-bi/ version=$(cat version) time=`date +%Y%m%d%H` echo ${time} echo ${version} image_name="succbi:${version}-${time}" image_prefix="harbor.xxx.com/succbi/" image_latest="harbor.xxx.com/succbi/succbi:latest" image_cn=${image_prefix}${image_name} docker build -t ${image_name} . if [ $? -ne 0 ];then echo "docker build failed" exit 1 fi docker tag ${image_name} ${image_cn} docker tag ${image_name} ${image_latest} docker push ${image_cn} docker push ${image_latest} docker镜像命名规范 suxxx-4.xx.3:latest suxxx-4.xx.3:2022060801 suxxx-4.xx.0:latest suxxx-4.xx.0:2022060801 suxxx-oem:latest suxxx-oem:2022060801
2022年05月27日
920 阅读
0 评论
0 点赞
2022-05-27
v2ray异常错误之二
无法连接之异常 机器过期忘记续费停机了一天,但续费后v2ray死活连不上,有如下报错 服务端: 2022/05/27 02:17:28 [Info] [50130167] app/proxyman/inbound: connection ends > proxy/vmess/inbound: invalid request from 58.48.189.174:0 > proxy/vmess/encoding: connection drained DrainSize = 1589 23 2 > proxy/vmess/encoding: invalid user: VMessAEAD is enforced and a non VMessAEAD connection is received. You can still disable this security feature with environment variable v2ray.vmess.aead.forced = false . You will not be able to enable legacy header workaround in the future. 2022/05/27 02:17:29 [Info] [2512890072] app/proxyman/inbound: connection ends > proxy/vmess/inbound: invalid request from 58.48.189.174:0 > proxy/vmess/encoding: connection drained DrainSize = 1589 23 20 > proxy/vmess/encoding: invalid user: VMessAEAD is enforced and a non VMessAEAD connection is received. You can still disable this security feature with environment variable v2ray.vmess.aead.forced = false . You will not be able to enable legacy header workaround in the future. 客户端 May 27 14:16:37 localhost v2ray: 2022/05/27 14:16:37 [Info] failed to handler mux client connection > v2ray.com/core/proxy/vmess/outbound: connection ends > v2ray.com/core/proxy/vmess/outbound: failed to read header > v2ray.com/core/proxy/vmess/encoding: failed to read response header > websocket: close 1000 (normal) May 27 14:16:37 localhost v2ray: 2022/05/27 14:16:37 [Info] v2ray.com/core/common/mux: failed to read metadata > io: read/write on closed pipe May 27 14:16:37 localhost v2ray: 2022/05/27 14:16:37 [Info] [924485881] v2ray.com/core/app/proxyman/inbound: connection ends > v2ray.com/core/proxy/socks: connection ends > context canceled 排查了客户端和服务端时间同步问题,再就是配置也没有动,突然就连不上了确实很奇怪。查了下资料按照如下方法解决: 1.执行 systemctl status v2ray 命令 2.若步骤1正常输出v2ray的信息 ,观察Drop-In:后面的路径 ,如: Drop-In: /etc/systemd/system/v2ray.service.d 3.进入上述路径 cd /etc/systemd/system/v2ray.service.d 4.执行 ls 命令看是否有一个 .conf后缀的文件,如 10-donot_touch_single_conf.conf 5.vim 修改这个文件: vim 10-donot_touch_single_conf.conf 6. 在[service]下添加一行信息: Environment="V2RAY_VMESS_AEAD_FORCED=false" 7. 文件修改保存后,再执行 systemctl daemon-reload 8. 执行 systemctl restart v2ray
2022年05月27日
3,310 阅读
0 评论
0 点赞
1
...
50
51
52
...
58