Comments (4)
同问,不清楚什么原因,看系统资源还有空余
from yulong-hids-archived.
求解决办法~
from yulong-hids-archived.
求解决办法〜
临时解决方法,可以先写个脚本定时查看是否进程存在,不存在的话重启server端;
from yulong-hids-archived.
我用竞态检测的结果是这样的
WARNING: DATA RACE
Read at 0x00c0004394d0 by goroutine 36:
reflect.maplen()
/usr/lib/golang/src/runtime/map.go:1351 +0x0
reflect.Value.MapKeys()
/usr/lib/golang/src/reflect/value.go:1212 +0x3a4
encoding/json.mapEncoder.encode()
/usr/lib/golang/src/encoding/json/encode.go:785 +0x10f
encoding/json.mapEncoder.encode-fm()
/usr/lib/golang/src/encoding/json/encode.go:777 +0x84
encoding/json.structEncoder.encode()
/usr/lib/golang/src/encoding/json/encode.go:759 +0x3c4
encoding/json.structEncoder.encode-fm()
/usr/lib/golang/src/encoding/json/encode.go:730 +0xa4
encoding/json.(*encodeState).reflectValue()
/usr/lib/golang/src/encoding/json/encode.go:358 +0x93
encoding/json.(*encodeState).marshal()
/usr/lib/golang/src/encoding/json/encode.go:330 +0xd2
encoding/json.Marshal()
/usr/lib/golang/src/encoding/json/encode.go:161 +0x78
github.com/olivere/elastic.(*BulkIndexRequest).Source()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_index_request.go:240 +0x63e
github.com/olivere/elastic.(*bulkWorker).work()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_processor.go:484 +0x21e
Previous write at 0x00c0004394d0 by goroutine 57:
runtime.mapassign_faststr()
/usr/lib/golang/src/runtime/map_faststr.go:202 +0x0
yulong-hids/server/action.ResultStat()
/root/yulong-hids/server/action/statistics.go:32 +0x159e
main.(*Watcher).PutInfo()
/root/yulong-hids/server/server.go:44 +0x357
runtime.call64()
/usr/lib/golang/src/runtime/asm_amd64.s:541 +0x3d
reflect.Value.Call()
/usr/lib/golang/src/reflect/value.go:336 +0xd8
github.com/smallnest/rpcx/server.(*service).call()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/service.go:337 +0x292
github.com/smallnest/rpcx/server.(*Server).handleRequest()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/server.go:543 +0x1046
github.com/smallnest/rpcx/server.(*Server).serveConn.func2()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/server.go:422 +0x2e6
Goroutine 36 (running) created at:
github.com/olivere/elastic.(*BulkProcessor).Start()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_processor.go:336 +0x3d2
github.com/olivere/elastic.(*BulkProcessorService).Do()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_processor.go:186 +0x4b7
yulong-hids/server/models.InsertThread()
/root/yulong-hids/server/models/es.go:240 +0x29e
Goroutine 57 (running) created at:
github.com/smallnest/rpcx/server.(*Server).serveConn()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/server.go:403 +0x524
==================
WARNING: DATA RACE
Read at 0x00c0004640b8 by goroutine 36:
reflect.typedmemmove()
/usr/lib/golang/src/runtime/mbarrier.go:177 +0x0
reflect.copyVal()
/usr/lib/golang/src/reflect/value.go:1309 +0x7d
reflect.Value.MapIndex()
/usr/lib/golang/src/reflect/value.go:1195 +0x2fc
encoding/json.mapEncoder.encode()
/usr/lib/golang/src/encoding/json/encode.go:801 +0x33c
encoding/json.mapEncoder.encode-fm()
/usr/lib/golang/src/encoding/json/encode.go:777 +0x84
encoding/json.structEncoder.encode()
/usr/lib/golang/src/encoding/json/encode.go:759 +0x3c4
encoding/json.structEncoder.encode-fm()
/usr/lib/golang/src/encoding/json/encode.go:730 +0xa4
encoding/json.(*encodeState).reflectValue()
/usr/lib/golang/src/encoding/json/encode.go:358 +0x93
encoding/json.(*encodeState).marshal()
/usr/lib/golang/src/encoding/json/encode.go:330 +0xd2
encoding/json.Marshal()
/usr/lib/golang/src/encoding/json/encode.go:161 +0x78
github.com/olivere/elastic.(*BulkIndexRequest).Source()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_index_request.go:240 +0x63e
github.com/olivere/elastic.(*bulkWorker).work()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_processor.go:484 +0x21e
Previous write at 0x00c0004640b8 by goroutine 57:
yulong-hids/server/action.ResultStat()
/root/yulong-hids/server/action/statistics.go:32 +0x15b6
main.(*Watcher).PutInfo()
/root/yulong-hids/server/server.go:44 +0x357
runtime.call64()
/usr/lib/golang/src/runtime/asm_amd64.s:541 +0x3d
reflect.Value.Call()
/usr/lib/golang/src/reflect/value.go:336 +0xd8
github.com/smallnest/rpcx/server.(*service).call()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/service.go:337 +0x292
github.com/smallnest/rpcx/server.(*Server).handleRequest()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/server.go:543 +0x1046
github.com/smallnest/rpcx/server.(*Server).serveConn.func2()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/server.go:422 +0x2e6
##异步写入线程
Goroutine 36 (running) created at:
github.com/olivere/elastic.(*BulkProcessor).Start()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_processor.go:336 +0x3d2
github.com/olivere/elastic.(*BulkProcessorService).Do()
/root/go/pkg/mod/github.com/olivere/[email protected]+incompatible/bulk_processor.go:186 +0x4b7
yulong-hids/server/models.InsertThread()
/root/yulong-hids/server/models/es.go:240 +0x29e
Goroutine 57 (running) created at:
github.com/smallnest/rpcx/server.(*Server).serveConn()
/root/go/pkg/mod/github.com/smallnest/[email protected]/server/server.go:403 +0x524
==================
WARNING: DATA RACE
Read at 0x0000015018b0 by goroutine 34:
yulong-hids/server/safecheck.(*Check).Rules()
/root/yulong-hids/server/safecheck/check.go:114 +0x54
yulong-hids/server/safecheck.(*Check).Run()
/root/yulong-hids/server/safecheck/check.go:274 +0x10b
yulong-hids/server/safecheck.ScanMonitorThread.func1()
/root/yulong-hids/server/safecheck/check.go:290 +0x3e4
Previous write at 0x0000015018b0 by goroutine 21:
reflect.typedmemmove()
/usr/lib/golang/src/runtime/mbarrier.go:177 +0x0
reflect.Value.Set()
/usr/lib/golang/src/reflect/value.go:1556 +0x108
gopkg.in/mgo%2ev2.(*Iter).All()
/root/go/pkg/mod/gopkg.in/[email protected]/session.go:3812 +0x497
gopkg.in/mgo%2ev2.(*Query).All()
/root/go/pkg/mod/gopkg.in/[email protected]/session.go:3818 +0x5e
yulong-hids/server/models.setRules()
/root/yulong-hids/server/models/common.go:176 +0x1ca
yulong-hids/server/models.Heartbeat()
/root/yulong-hids/server/models/common.go:195 +0x84
Goroutine 34 (running) created at:
yulong-hids/server/safecheck.ScanMonitorThread()
/root/yulong-hids/server/safecheck/check.go:284 +0x8f
Goroutine 21 (running) created at:
main.init.0()
/root/yulong-hids/server/server.go:66 +0x186
==================
WARNING: DATA RACE
Write at 0x000001512cc8 by goroutine 21:
yulong-hids/server/models.setConfig()
/root/yulong-hids/server/models/common.go:166 +0x74c
yulong-hids/server/models.Heartbeat()
/root/yulong-hids/server/models/common.go:194 +0x7d
Previous read at 0x000001512cc8 by goroutine 34:
yulong-hids/server/safecheck.(*Check).Intelligence()
/root/yulong-hids/server/safecheck/check.go:191 +0x54
yulong-hids/server/safecheck.(*Check).Run()
/root/yulong-hids/server/safecheck/check.go:275 +0x119
yulong-hids/server/safecheck.ScanMonitorThread.func1()
/root/yulong-hids/server/safecheck/check.go:290 +0x3e4
Goroutine 21 (running) created at:
main.init.0()
/root/yulong-hids/server/server.go:66 +0x186
Goroutine 34 (running) created at:
yulong-hids/server/safecheck.ScanMonitorThread()
/root/yulong-hids/server/safecheck/check.go:284 +0x8f
==================
WARNING: DATA RACE
Write at 0x00c0001e4270 by goroutine 21:
reflect.typedmemmove()
/usr/lib/golang/src/runtime/mbarrier.go:177 +0x0
reflect.Value.Set()
/usr/lib/golang/src/reflect/value.go:1556 +0x108
gopkg.in/mgo.v2/bson.(*decoder).readDocTo()
/root/go/pkg/mod/gopkg.in/[email protected]/bson/decode.go:202 +0x624
gopkg.in/mgo.v2/bson.Unmarshal()
/root/go/pkg/mod/gopkg.in/[email protected]/bson/bson.go:559 +0x238
gopkg.in/mgo%2ev2.(*Iter).Next()
/root/go/pkg/mod/gopkg.in/[email protected]/session.go:3732 +0x6b0
gopkg.in/mgo%2ev2.(*Iter).All()
/root/go/pkg/mod/gopkg.in/[email protected]/session.go:3806 +0x590
gopkg.in/mgo%2ev2.(*Query).All()
/root/go/pkg/mod/gopkg.in/[email protected]/session.go:3818 +0x5e
yulong-hids/server/models.setRules()
/root/yulong-hids/server/models/common.go:176 +0x1ca
yulong-hids/server/models.Heartbeat()
/root/yulong-hids/server/models/common.go:195 +0x84
Previous read at 0x00c0001e4270 by goroutine 24:
yulong-hids/server/safecheck.(*Check).Rules()
/root/yulong-hids/server/safecheck/check.go:114 +0xab
yulong-hids/server/safecheck.(*Check).Run()
/root/yulong-hids/server/safecheck/check.go:274 +0x10b
yulong-hids/server/safecheck.ScanMonitorThread.func1()
/root/yulong-hids/server/safecheck/check.go:290 +0x3e4
Goroutine 21 (running) created at:
main.init.0()
/root/yulong-hids/server/server.go:66 +0x186
Goroutine 24 (running) created at:
yulong-hids/server/safecheck.ScanMonitorThread()
/root/yulong-hids/server/safecheck/check.go:284 +0x8f
==================
WARNING: DATA RACE
Write at 0x000001512c30 by goroutine 21:
yulong-hids/server/models.setConfig()
/root/yulong-hids/server/models/common.go:166 +0x74c
yulong-hids/server/models.Heartbeat()
/root/yulong-hids/server/models/common.go:194 +0x7d
Previous read at 0x000001512c30 by goroutine 34:
yulong-hids/server/safecheck.(*Check).BlackFilter()
/root/yulong-hids/server/safecheck/check.go:66 +0xa5
yulong-hids/server/safecheck.(*Check).Run()
/root/yulong-hids/server/safecheck/check.go:270 +0xe4
yulong-hids/server/safecheck.ScanMonitorThread.func1()
/root/yulong-hids/server/safecheck/check.go:290 +0x3e4
Goroutine 21 (running) created at:
main.init.0()
/root/yulong-hids/server/server.go:66 +0x186
Goroutine 34 (running) created at:
yulong-hids/server/safecheck.ScanMonitorThread()
/root/yulong-hids/server/safecheck/check.go:284 +0x8f
==================
WARNING: DATA RACE
Write at 0x000001512c90 by goroutine 21:
yulong-hids/server/models.setConfig()
/root/yulong-hids/server/models/common.go:166 +0x74c
yulong-hids/server/models.Heartbeat()
/root/yulong-hids/server/models/common.go:194 +0x7d
Previous read at 0x000001512c90 by goroutine 34:
yulong-hids/server/safecheck.(*Check).WhiteFilter()
/root/yulong-hids/server/safecheck/check.go:103 +0xa5
yulong-hids/server/safecheck.(*Check).Run()
/root/yulong-hids/server/safecheck/check.go:271 +0xf2
yulong-hids/server/safecheck.ScanMonitorThread.func1()
/root/yulong-hids/server/safecheck/check.go:290 +0x3e4
Goroutine 21 (running) created at:
main.init.0()
/root/yulong-hids/server/server.go:66 +0x186
Goroutine 34 (running) created at:
yulong-hids/server/safecheck.ScanMonitorThread()
/root/yulong-hids/server/safecheck/check.go:284 +0x8f
from yulong-hids-archived.
Related Issues (20)
- Error compile web binary HOT 6
- 无法卸载agent HOT 1
- 在某些内核版本下加载驱动,会造成系统挂掉
- 忽略
- 点赞 HOT 1
- 单独有一台监控的服务器进程异常敏感,随便敲个命令都会告警 HOT 1
- Available server node 是否支持nat映射 HOT 2
- 是不是打上spectre_v2补丁驱动就不能用了
- 启动web.exe无法绑定ip地址 HOT 1
- cnetos insmod syshook_execve.ko 内核版本 3.10.0-862.el7.x86_64 导致机器挂掉 HOT 3
- 驱动中宽字符(中文)处理问题
- 写的非常棒
- 我想把项目进行32位Linux的移植 HOT 1
- Agent安装失败 HOT 2
- fix task_id error
- agent在windows和linux下都无法运行
- web配置文件app.conf中ylhostname参数不起作用,base.go的24行c.Ctx.Input.Host()获取的不是客户端ip,可以用c.Ctx.Input.IP()替代
- 对进程的规则不起作用 HOT 2
- centos 启动agent时,瞬间把文件描述符打到65K,机器搞死了,怎么解决这个bug
- Process monitoring could not be started (无法实现进程监控)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yulong-hids-archived.