摘要: netstat -tnlp 查看当前机器开放的端口 netstat -tn 统计出tcp协议 netstat -n 当前所有的网络请求,不统计主机名 netstat -tn | grep ':22' | wc -l 统计出当前的连接数 vmstat 1 每隔1秒钟 打印出当前机器的状态 netsta 阅读全文
posted @ 2019-09-07 22:15 yile 阅读(160) 评论(0) 推荐(0) 编辑
摘要: sed替换 stream editor 根据定位到到数据行修改数据,用于数据修改 sed[addr]X[options] -e 表达式 sed -n '2p' 打印第二行 sed -n '/00:00:01/,/00:00:04/' /tmp/nginx.log 打印1-4之间的数据 sed 's# 阅读全文
posted @ 2019-09-07 11:58 yile 阅读(138) 评论(0) 推荐(0) 编辑
摘要: awk 根据定位到到数据行处理其中到分段,用于数据切片 awk 'BEGIN{}END{}' # 开始和结束 awk '/Running/' # 正则匹配 awk '/aaa/,/bbb/' # 区间选择 awk '$2~/xx/' # 字段匹配 awk 'NR==2' # 取第二行 awk 'NR 阅读全文
posted @ 2019-09-07 11:56 yile 阅读(269) 评论(0) 推荐(0) 编辑
摘要: grep (global search regular expression and print out the line)基于正则表达式查找满足条件的行,用于数据查找定位 grep -v 不显示匹配的行 grep -i 忽略大小写 grep -o 把每个匹配的内容用独立的行显示 grep -E 使 阅读全文
posted @ 2019-09-07 11:51 yile 阅读(907) 评论(0) 推荐(0) 编辑
摘要: a=ddd echo $a echo aecho $p echo $PATH which findwhich adbecho $PATH[ 2 -gt 1 ] echo $? ls a=1 echo $a b=hello world b="hello world" echo $b echo b a= 阅读全文
posted @ 2019-09-07 11:46 yile 阅读(1017) 评论(0) 推荐(0) 编辑
摘要: from jsonpath import jsonpath res_dict = {} res_dict = {"code":0, "msg":"success",} res_dict = { "code": 0, "msg": "成功", "data": { "users": [ {"name": "张三", "gender": ... 阅读全文
posted @ 2019-09-05 18:23 yile 阅读(367) 评论(0) 推荐(0) 编辑
摘要: ERROR: Exception:Traceback (most recent call last): File "C:\Users\admin\AppData\Roaming\Python\Python37\site-packages\pip\_internal\cli\base_command. 阅读全文
posted @ 2019-09-05 17:43 yile 阅读(2023) 评论(0) 推荐(0) 编辑
摘要: Could not fetch URL https://pypi.org/simple/jsonpath/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=4 阅读全文
posted @ 2019-09-05 17:06 yile 阅读(9684) 评论(1) 推荐(1) 编辑
摘要: docker pull jenkins:34.78 docker images 列出本机所有的镜像列表 docker tag redmine:latest 创建新tag docker rmi redmine 删除镜像 docker rmi id 删除镜像 docker save redmine > 阅读全文
posted @ 2019-09-01 08:28 yile 阅读(88) 评论(0) 推荐(0) 编辑
摘要: python2 -m CGIHTTPServer 8080python3 -m http.server 阅读全文
posted @ 2019-08-27 21:09 yile 阅读(176) 评论(0) 推荐(0) 编辑