You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The text was updated successfully, but these errors were encountered:
cheneylew
changed the title
I copy folder that contain many little files, the server become crashed!when gsync server is running! this is log
I copy folder that contain many little files to server watched dir, the server become crashed!when gsync server is running! this is log
Aug 5, 2017
Thanks for report this problem. I just had a quick look, it looks like the fsnotify dependency I have using have been migrated to another project. I need sometime to load everything back to my brain. By the way, what is the OS that you were running this program on?
Sorry for the late reply. I found the code on the Github seems to be much older than the code in my computer. I have just updated the code and would you please get the latest code and try again? Thanks.
Cheneys-MacBook:gsync文件同步服务器 dejunliu$ gsync server.json
CPUs: 8
Ignored: /Users/dejunliu/Desktop/filesync/a/.sync/index.db
Serving now...
Ignored: /Users/dejunliu/Desktop/filesync/a/.sync/index.db
2017/08/06 07:06:48 http: panic serving 127.0.0.1:54190: runtime error: invalid memory address or nil pointer dereference
goroutine 4230 [running]:
net/http.(*conn).serve.func1(0xc4201a20a0)
/usr/local/go/src/net/http/server.go:1721 +0xd0
panic(0x444d420, 0x465b670)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
database/sql.(*Stmt).Close(0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:2045 +0x38
panic(0x444d420, 0x465b670)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
database/sql.(*Stmt).QueryContext(0x0, 0x4638500, 0xc420012300, 0xc420054fb0, 0x2, 0x2, 0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:1936 +0x5b
database/sql.(*Stmt).Query(0x0, 0xc420054fb0, 0x2, 0x2, 0x1, 0xc4201b6f40, 0x2)
/usr/local/go/src/database/sql/sql.go:1978 +0x65
github.com/elgs/filesync/api.RunWeb.func4(0x4949230, 0x4683fe8, 0xc420300100, 0x0, 0x0, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/elgs/filesync/api/api.go:72 +0x42e
reflect.Value.call(0x4448e80, 0x44be740, 0x13, 0x44aad9d, 0x4, 0xc4202189c0, 0x2, 0x2, 0x4011762, 0x4448e80, ...)
/usr/local/go/src/reflect/value.go:434 +0x91f
reflect.Value.Call(0x4448e80, 0x44be740, 0x13, 0xc4202189c0, 0x2, 0x2, 0xc420055550, 0x400b0fe, 0x44969c0)
/usr/local/go/src/reflect/value.go:302 +0xa4
github.com/codegangsta/inject.(*injector).Invoke(0xc420509480, 0x4448e80, 0x44be740, 0x444a800, 0xc4202188d0, 0xc4200555a8, 0xc42007d180, 0x16)
/Users/dejunliu/go/src/github.com/codegangsta/inject/inject.go:102 +0x314
github.com/codegangsta/martini.(*context).Invoke(0xc42034a9b0, 0x4448e80, 0x44be740, 0x4460840, 0xc420055600, 0x42df3e5, 0xc420509480, 0x447f240)
:30 +0x61
github.com/codegangsta/martini.(*routeContext).run(0xc420218990)
/Users/dejunliu/go/src/github.com/codegangsta/martini/router.go:408 +0x71
github.com/codegangsta/martini.(*route).Handle(0xc420019180, 0x49491c8, 0xc42034a9b0, 0x4949190, 0xc42034a960)
/Users/dejunliu/go/src/github.com/codegangsta/martini/router.go:285 +0x112
github.com/codegangsta/martini.(*router).Handle(0xc42001b9e0, 0x4949190, 0xc42034a960, 0xc420300100, 0x49491c8, 0xc42034a9b0)
/Users/dejunliu/go/src/github.com/codegangsta/martini/router.go:132 +0x31b
github.com/codegangsta/martini.(Router).Handle-fm(0x4949190, 0xc42034a960, 0xc420300100, 0x49491c8, 0xc42034a9b0)
/Users/dejunliu/go/src/github.com/elgs/filesync/api/api.go:116 +0x61
reflect.Value.call(0x4441a40, 0xc4200c2f20, 0x13, 0x44aad9d, 0x4, 0xc42034aa00, 0x3, 0x3, 0x0, 0x4441a40, ...)
/usr/local/go/src/reflect/value.go:434 +0x91f
reflect.Value.Call(0x4441a40, 0xc4200c2f20, 0x13, 0xc42034aa00, 0x3, 0x3, 0x0, 0x0, 0x0)
/usr/local/go/src/reflect/value.go:302 +0xa4
github.com/codegangsta/inject.(*injector).Invoke(0xc420509480, 0x4441a40, 0xc4200c2f20, 0x0, 0x0, 0x0, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/codegangsta/inject/inject.go:102 +0x314
github.com/codegangsta/martini.(*context).run(0xc42034a9b0)
/Users/dejunliu/go/src/github.com/codegangsta/martini/martini.go:179 +0x6a
github.com/codegangsta/martini.(*Martini).ServeHTTP(0xc4200176c0, 0x4637f00, 0xc4204020e0, 0xc420300100)
/Users/dejunliu/go/src/github.com/codegangsta/martini/martini.go:75 +0x57
net/http.serverHandler.ServeHTTP(0xc42009c420, 0x4637f00, 0xc4204020e0, 0xc420300100)
/usr/local/go/src/net/http/server.go:2568 +0x92
net/http.(*conn).serve(0xc4201a20a0, 0x46384c0, 0xc4204548c0)
/usr/local/go/src/net/http/server.go:1825 +0x612
created by net/http.(*Server).Serve
/usr/local/go/src/net/http/server.go:2668 +0x2ce
2017/08/06 07:06:53 http: panic serving 127.0.0.1:54191: runtime error: invalid memory address or nil pointer dereference
goroutine 8234 [running]:
net/http.(*conn).serve.func1(0xc4202243c0)
/usr/local/go/src/net/http/server.go:1721 +0xd0
panic(0x444d420, 0x465b670)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
database/sql.(*Stmt).Close(0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:2045 +0x38
panic(0x444d420, 0x465b670)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
database/sql.(*Stmt).QueryContext(0x0, 0x4638500, 0xc420012300, 0xc420054fb0, 0x2, 0x2, 0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:1936 +0x5b
database/sql.(*Stmt).Query(0x0, 0xc420054fb0, 0x2, 0x2, 0x1, 0xc4209fc136, 0x2)
/usr/local/go/src/database/sql/sql.go:1978 +0x65
github.com/elgs/filesync/api.RunWeb.func4(0x4949230, 0x4683fe8, 0xc420300200, 0x0, 0x0, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/elgs/filesync/api/api.go:72 +0x42e
reflect.Value.call(0x4448e80, 0x44be740, 0x13, 0x44aad9d, 0x4, 0xc42016fc20, 0x2, 0x2, 0x4011762, 0x4448e80, ...)
/usr/local/go/src/reflect/value.go:434 +0x91f
reflect.Value.Call(0x4448e80, 0x44be740, 0x13, 0xc42016fc20, 0x2, 0x2, 0xc420055550, 0x400b0fe, 0x44969c0)
/usr/local/go/src/reflect/value.go:302 +0xa4
github.com/codegangsta/inject.(*injector).Invoke(0xc42033e360, 0x4448e80, 0x44be740, 0x444a800, 0xc42016f770, 0xc4200555a8, 0xc42007c940, 0x16)
/Users/dejunliu/go/src/github.com/codegangsta/inject/inject.go:102 +0x314
github.com/codegangsta/martini.(*context).Invoke(0xc420376eb0, 0x4448e80, 0x44be740, 0x4460840, 0xc420055600, 0x42df3e5, 0xc42033e360, 0x447f240)
:30 +0x61
github.com/codegangsta/martini.(*routeContext).run(0xc42016fbf0)
/Users/dejunliu/go/src/github.com/codegangsta/martini/router.go:408 +0x71
github.com/codegangsta/martini.(*route).Handle(0xc420019180, 0x49491c8, 0xc420376eb0, 0x4949190, 0xc420376e10)
/Users/dejunliu/go/src/github.com/codegangsta/martini/router.go:285 +0x112
github.com/codegangsta/martini.(*router).Handle(0xc42001b9e0, 0x4949190, 0xc420376e10, 0xc420300200, 0x49491c8, 0xc420376eb0)
/Users/dejunliu/go/src/github.com/codegangsta/martini/router.go:132 +0x31b
github.com/codegangsta/martini.(Router).Handle-fm(0x4949190, 0xc420376e10, 0xc420300200, 0x49491c8, 0xc420376eb0)
/Users/dejunliu/go/src/github.com/elgs/filesync/api/api.go:116 +0x61
reflect.Value.call(0x4441a40, 0xc4200c2f20, 0x13, 0x44aad9d, 0x4, 0xc420376f00, 0x3, 0x3, 0x0, 0x4441a40, ...)
/usr/local/go/src/reflect/value.go:434 +0x91f
reflect.Value.Call(0x4441a40, 0xc4200c2f20, 0x13, 0xc420376f00, 0x3, 0x3, 0x0, 0x0, 0x0)
/usr/local/go/src/reflect/value.go:302 +0xa4
github.com/codegangsta/inject.(*injector).Invoke(0xc42033e360, 0x4441a40, 0xc4200c2f20, 0x0, 0x0, 0x0, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/codegangsta/inject/inject.go:102 +0x314
github.com/codegangsta/martini.(*context).run(0xc420376eb0)
/Users/dejunliu/go/src/github.com/codegangsta/martini/martini.go:179 +0x6a
github.com/codegangsta/martini.(*Martini).ServeHTTP(0xc4200176c0, 0x4637f00, 0xc420402000, 0xc420300200)
/Users/dejunliu/go/src/github.com/codegangsta/martini/martini.go:75 +0x57
net/http.serverHandler.ServeHTTP(0xc42009c420, 0x4637f00, 0xc420402000, 0xc420300200)
/usr/local/go/src/net/http/server.go:2568 +0x92
net/http.(*conn).serve(0xc4202243c0, 0x46384c0, 0xc4202ad280)
/usr/local/go/src/net/http/server.go:1825 +0x612
created by net/http.(*Server).Serve
/usr/local/go/src/net/http/server.go:2668 +0x2ce
panic: runtime error: invalid memory address or nil pointer dereference
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x4100ee8]
goroutine 11339 [running]:
database/sql.(*Stmt).Close(0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:2045 +0x38
panic(0x444d420, 0x465b670)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
database/sql.(*Stmt).ExecContext(0x0, 0x4638500, 0xc420012300, 0xc420c49a98, 0x6, 0x6, 0x0, 0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:1789 +0x67
database/sql.(*Stmt).Exec(0x0, 0xc420c49a98, 0x6, 0x6, 0x4634880, 0xc420342020, 0x8, 0x563dcc87005192c5)
/usr/local/go/src/database/sql/sql.go:1814 +0x65
github.com/elgs/filesync/index.WatchRecursively.func2.1(0xc42032a2d0, 0xc420c49c38, 0xc4200151a0, 0x22, 0xc42008ff40, 0x4639ae0, 0xc420145040)
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:283 +0x5e1
github.com/elgs/filesync/index.WatchRecursively.func2(0xc420392320, 0x46, 0x4639ae0, 0xc420145040, 0x0, 0x0, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:291 +0x3aa
path/filepath.walk(0xc420392320, 0x46, 0x4639ae0, 0xc420145040, 0xc420455900, 0x0, 0x40)
/usr/local/go/src/path/filepath/path.go:351 +0x81
path/filepath.Walk(0xc420392320, 0x46, 0xc420455900, 0x46, 0xc42032a2d0)
/usr/local/go/src/path/filepath/path.go:398 +0x14c
github.com/elgs/filesync/index.WatchRecursively(0xc42008eaa0, 0xc420391e00, 0x46, 0xc4200151a0, 0x22, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:301 +0x1d3
created by github.com/elgs/filesync/index.ProcessEvent
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:392 +0x412
panic: runtime error: invalid memory address or nil pointer dereference
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x4100ee8]
goroutine 10967 [running]:
database/sql.(*Stmt).Close(0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:2045 +0x38
panic(0x444d420, 0x465b670)
/usr/local/go/src/runtime/panic.go:489 +0x2cf
database/sql.(*Stmt).ExecContext(0x0, 0x4638500, 0xc420012300, 0xc420175a98, 0x6, 0x6, 0x0, 0x0, 0x0, 0x0)
/usr/local/go/src/database/sql/sql.go:1789 +0x67
database/sql.(*Stmt).Exec(0x0, 0xc420175a98, 0x6, 0x6, 0x4634880, 0xc420508100, 0x8, 0x71cb758e29063f7b)
/usr/local/go/src/database/sql/sql.go:1814 +0x65
github.com/elgs/filesync/index.WatchRecursively.func2.1(0xc4206ec1e0, 0xc420175c38, 0xc4200151a0, 0x22, 0xc4201ac000, 0x4639ae0, 0xc4205ba820)
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:283 +0x5e1
github.com/elgs/filesync/index.WatchRecursively.func2(0xc420744280, 0x46, 0x4639ae0, 0xc4205ba820, 0x0, 0x0, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:291 +0x3aa
path/filepath.walk(0xc420744280, 0x46, 0x4639ae0, 0xc4205ba820, 0xc420351ac0, 0x0, 0x40)
/usr/local/go/src/path/filepath/path.go:351 +0x81
path/filepath.Walk(0xc420744280, 0x46, 0xc420351ac0, 0x46, 0xc4206ec1e0)
/usr/local/go/src/path/filepath/path.go:398 +0x14c
github.com/elgs/filesync/index.WatchRecursively(0xc42008eaa0, 0xc4207f8000, 0x46, 0xc4200151a0, 0x22, 0x0, 0x0)
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:301 +0x1d3
created by github.com/elgs/filesync/index.ProcessEvent
/Users/dejunliu/go/src/github.com/elgs/filesync/index/index.go:392 +0x412
The text was updated successfully, but these errors were encountered: