# Go-pluginserver terminated when using custom Go plugin

**URL:** <https://discuss.konghq.com/t/go-pluginserver-terminated-when-using-custom-go-plugin/5969>\
**Category:** Questions\
**Created:** [April 7, 2020, 8:29pm UTC](https://discuss.konghq.com/t/go-pluginserver-terminated-when-using-custom-go-plugin/5969 "2020-04-07T20:29:26Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![PFadel](https://yyz2.discourse-cdn.com/flex036/user_avatar/discuss.konghq.com/pfadel/32/279_2.png) [@PFadel](https://discuss.konghq.com/u/PFadel)\
**Post date:** [April 7, 2020, 8:29pm UTC](https://discuss.konghq.com/t/go-pluginserver-terminated-when-using-custom-go-plugin/5969/1 "2020-04-07T20:29:26Z")

</div>

Hello! I’m trying to use a custom Go plugin with my Kong, here are some details:

Kong Version: `2.0.2`  
Go Version: `go version go1.13.5 linux/amd64`  
go-pluginserver version: `Runtime Version: go1.13.5`

I updated `kong.conf` to load my plugin, and Kong successfully starts. Although, when I execute a request to the service where my plugin is set, nothing happens, when I opend `error.log` i got a lot of this message:

```bash
2020/04/08 16:50:58 [notice] 26519#0: start worker process 26524
2020/04/08 16:50:58 [notice] 26519#0: start worker process 26525
2020/04/08 16:50:58 [notice] 26519#0: start worker process 26526
2020/04/08 16:50:58 [notice] 26519#0: start worker process 26527
2020/04/08 16:50:58 [notice] 26520#0: *1 [lua] cache_warmup.lua:45: cache_warmup_single_entity(): Preloading 'services' into the cache ..., context: init_worker_by_lua*
2020/04/08 16:50:58 [notice] 26520#0: *1 [lua] cache_warmup.lua:84: cache_warmup_single_entity(): finished preloading 'services' into the cache (in 85ms), context: init_worker_by_lua*
2020/04/08 16:50:58 [notice] 26520#0: *1 [lua] cache_warmup.lua:45: cache_warmup_single_entity(): Preloading 'plugins' into the cache ..., context: init_worker_by_lua*
2020/04/08 16:50:58 [notice] 26520#0: *1 [lua] cache_warmup.lua:84: cache_warmup_single_entity(): finished preloading 'plugins' into the cache (in 0ms), context: init_worker_by_lua*
2020/04/08 16:50:58 [notice] 26520#0: *16 [lua] cache_warmup.lua:25: warming up DNS entries ..., context: ngx.timer
2020/04/08 16:50:58 [notice] 26520#0: *16 [lua] cache_warmup.lua:35: finished warming up DNS entries' into the cache (in 6ms), context: ngx.timer
2020/04/08 16:51:24 [notice] 26519#0: signal 15 (SIGTERM) received from 27018, exiting
2020/04/08 16:51:24 [notice] 26520#0: exiting
2020/04/08 16:51:24 [notice] 26522#0: exiting
2020/04/08 16:51:24 [notice] 26521#0: exiting
2020/04/08 16:51:24 [notice] 26523#0: exiting
2020/04/08 16:51:24 [notice] 26524#0: exiting
2020/04/08 16:51:24 [notice] 26527#0: exiting
2020/04/08 16:51:24 [notice] 26525#0: exiting
2020/04/08 16:51:24 [notice] 26526#0: exiting
2020/04/08 16:51:24 [notice] 26527#0: exit
2020/04/08 16:51:24 [notice] 26520#0: exit
2020/04/08 16:51:24 [notice] 26521#0: exit
2020/04/08 16:51:24 [notice] 26522#0: exit
2020/04/08 16:51:24 [notice] 26519#0: signal 17 (SIGCHLD) received from 26527
2020/04/08 16:51:24 [notice] 26519#0: worker process 26520 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: worker process 26521 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: worker process 26522 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: worker process 26527 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: signal 29 (SIGIO) received
2020/04/08 16:51:24 [notice] 26523#0: exit
2020/04/08 16:51:24 [notice] 26519#0: signal 17 (SIGCHLD) received from 26523
2020/04/08 16:51:24 [notice] 26519#0: worker process 26523 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: signal 29 (SIGIO) received
2020/04/08 16:51:24 [notice] 26524#0: exit
2020/04/08 16:51:24 [notice] 26519#0: signal 17 (SIGCHLD) received from 26524
2020/04/08 16:51:24 [notice] 26519#0: worker process 26524 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: signal 29 (SIGIO) received
2020/04/08 16:51:24 [notice] 26526#0: exit
2020/04/08 16:51:24 [notice] 26519#0: signal 17 (SIGCHLD) received from 26526
2020/04/08 16:51:24 [notice] 26519#0: worker process 26526 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: signal 29 (SIGIO) received
2020/04/08 16:51:24 [notice] 26525#0: exit
2020/04/08 16:51:24 [notice] 26519#0: signal 17 (SIGCHLD) received from 26525
2020/04/08 16:51:24 [notice] 26519#0: worker process 26525 exited with code 0
2020/04/08 16:51:24 [notice] 26519#0: exit
2020/04/08 16:51:24 [notice] 27037#0: using the "epoll" event method
2020/04/08 16:51:24 [notice] 27037#0: openresty/1.15.8.2
2020/04/08 16:51:24 [notice] 27037#0: built by gcc 7.4.0 (Ubuntu 7.4.0-1ubuntu1~18.04.1) 
2020/04/08 16:51:24 [notice] 27037#0: OS: Linux 5.3.0-45-generic
2020/04/08 16:51:24 [notice] 27037#0: getrlimit(RLIMIT_NOFILE): 1024:4096
2020/04/08 16:51:24 [notice] 27049#0: start worker processes
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27050
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27051
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27052
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27053
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27054
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27055
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27056
2020/04/08 16:51:24 [notice] 27049#0: start worker process 27057
2020/04/08 16:51:24 [warn] 27050#0: *1 [lua] globalpatches.lua:52: sleep(): executing a blocking 'sleep' (0.001 seconds), context: init_worker_by_lua*
2020/04/08 16:51:24 [notice] 27050#0: *1 [lua] cache_warmup.lua:45: cache_warmup_single_entity(): Preloading 'services' into the cache ..., context: init_worker_by_lua*
2020/04/08 16:51:24 [notice] 27050#0: *1 [lua] cache_warmup.lua:84: cache_warmup_single_entity(): finished preloading 'services' into the cache (in 102ms), context: init_worker_by_lua*
2020/04/08 16:51:24 [notice] 27050#0: *1 [lua] cache_warmup.lua:45: cache_warmup_single_entity(): Preloading 'plugins' into the cache ..., context: init_worker_by_lua*
2020/04/08 16:51:24 [notice] 27050#0: *1 [lua] cache_warmup.lua:84: cache_warmup_single_entity(): finished preloading 'plugins' into the cache (in 0ms), context: init_worker_by_lua*
2020/04/08 16:51:24 [notice] 27050#0: *17 [lua] cache_warmup.lua:25: warming up DNS entries ..., context: ngx.timer
2020/04/08 16:51:24 [notice] 27050#0: *19 [kong] go.lua:84 Starting go-pluginserver, context: ngx.timer
2020/04/08 16:51:24 [notice] 27050#0: signal 17 (SIGCHLD) received from 27142
2020/04/08 16:51:24 [notice] 27050#0: *19 [kong] go.lua:95 go-pluginserver terminated: exit 0, context: ngx.timer

```

And those last three lines go on forever:

```bash
2020/04/08 16:51:24 [notice] 27050#0: signal 17 (SIGCHLD) received from 27398
2020/04/08 16:51:24 [notice] 27050#0: *19 [kong] go.lua:95 go-pluginserver terminated: exit 0, context: ngx.timer
2020/04/08 16:51:24 [notice] 27050#0: *19 [kong] go.lua:84 Starting go-pluginserver, context: ngx.timer

```

Am I doing something wrong ? Any help would be appreciated.

---

<div class="post-metadata">

**Author:** ![alex](https://avatars.discourse-cdn.com/v4/letter/a/db5fbb/32.png) [@alex](https://discuss.konghq.com/u/alex)\
**Post date:** [November 12, 2020, 3:34pm UTC](https://discuss.konghq.com/t/go-pluginserver-terminated-when-using-custom-go-plugin/5969/2 "2020-11-12T15:34:14Z")

</div>

Try this:

> [@Kong:2.0.5 infinite loop go-pluginserver terminated](https://discuss.konghq.com/t/kong-2-0-5-infinite-loop-go-pluginserver-terminated/6715/2):
>
> Hi @taotao. When the go-pluginserver starts, it attempts to create a Unix domain socket in the Kong prefix; as such, you need to ensure that the Kong prefix is writeable by the user that is starting the go-pluginserver.
