dump出来文件
sudo tcpdump -i any -s 0 -w ./full_capture22.pcap 'tcp port 8080'
wireshark 过滤条件
http.request and http contains "/api/serve/predict"
frame contains "输入数据中缺少以下变量"
frame contains ""code":500"
(frame contains ":500") && (json.path_with_value == " 400: 发生错误")
#成功抓取
sudo tcpdump -i any -A -s 0 -l 'tcp port 8080' | grep --line-buffered -E "(POST|GET|HTTP/|Cookie:|Set-Cookie:|/api/torchserve/predict)"
sudo tcpdump -i any -A -s 0 -l 'tcp port 8080' | grep --line-buffered -E "(POST|GET|HTTP/|Cookie:|Set-Cookie:|TE1111B)"
sudo tcpdump -i any -A -s 0 -l 'tcp port 8080' | grep --line-buffered -E "(POST|GET|HTTP/|Cookie:|Set-Cookie:|TE1111B|HTTP/1.1 200)"
筛选出来后右键-追踪流-HTTP-stream 就可以看到http的请求参数和返回参数了