stork agent does not connect to public ip
I installed Stork/Kea from scratch in order to setup a ha scenario. at the moment the first server is configured. If the controll agent is bound to 127.0.0.1 the stork agent can connect and collect infos. if i change the crtl-agent to the public ip, the agent complains it cannot connect to 127.0.0.1
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] main.go:75 Starting Stork Agent, version 0.11.0, build date 2020-09-04 15:29
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] promkeaexporter.go:272 Prometheus Kea Exporter listening on 0.0.0.0:9547, stats pulling interval: 10 seconds
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] monitor.go:80 Started app monitor
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] monitor.go:148 new or updated apps detected:
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] monitor.go:155 kea: control: 192.168.125.31:8000
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] monitor.go:155 bind9: control: 127.0.0.1:953, statistics: 127.0.0.1:80
Sep 16 22:35:40 ladc01 kea-ctrl-agent[19039]: INFO COMMAND_RECEIVED Received command 'config-get'
Sep 16 22:35:40 ladc01 kea-ctrl-agent[19039]: INFO COMMAND_RECEIVED Received command 'config-get'
Sep 16 22:35:40 ladc01 kea-dhcp4[32070]: 2020-09-16 22:35:40.341 INFO [kea-dhcp4.commands/32070.140437553672960] COMMAND_RECEIVED Received command 'config-get'
Sep 16 22:35:40 ladc01 kea-ctrl-agent[19039]: INFO CTRL_AGENT_COMMAND_FORWARDED command config-get successfully forwarded to the service dhcp4
Sep 16 22:35:40 ladc01 stork-agent[19743]: WARN[2020-09-16 22:35:40] kea.go:57 skipped refreshing viewable log files because config-get returned non success result
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] kea.go:72 no loggers found in the returned configuration while trying to refresh the viewable log files
Sep 16 22:35:40 ladc01 stork-agent[19743]: WARN[2020-09-16 22:35:40] kea.go:57 skipped refreshing viewable log files because config-get returned non success result
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40]prombind9exporter.go:825 Prometheus BIND 9 Exporter listening on 0.0.0.0:9119, stats pulling interval: 10 seconds
Sep 16 22:35:40 ladc01 stork-agent[19743]: INFO[2020-09-16 22:35:40] agent.go:309 started serving Stork Agent address="[::]:8080"
Sep 16 22:35:40 ladc01 named[25746]: validating ./SOA: got insecure response; parent indicates it should be secure
Sep 16 22:35:40 ladc01 named[25746]: no valid RRSIG resolving 'local/DS/IN': 172.24.38.124#53
Sep 16 22:35:40 ladc01 named[25746]: validating ./SOA: got insecure response; parent indicates it should be secure
Sep 16 22:35:40 ladc01 named[25746]: no valid RRSIG resolving 'local/DS/IN': 172.24.38.123#53
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] agent.go:244 Failed to forward commands to Kea CA: Post http://127.0.0.1:8000/: dial tcp 127.0.0.1:8000: connect: connection refused
Sep 16 22:35:48 ladc01 stork-agent[19743]: problem with sending POST to http://127.0.0.1:8000/
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*HTTPClient).Call
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/caclient.go:38
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*StorkAgent).ForwardToKeaOverHTTP
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/agent.go:240
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/api._Agent_ForwardToKeaOverHTTP_Handler
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/api/agent.pb.go:1361
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).processUnaryRPC
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1024
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).handleStream
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1313
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).serveStreams.func1.1
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:722
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357 URL="http://127.0.0.1:8000/"
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] agent.go:244 Failed to forward commands to Kea CA: Post http://127.0.0.1:8000/: dial tcp 127.0.0.1:8000: connect: connection refused
Sep 16 22:35:48 ladc01 stork-agent[19743]: problem with sending POST to http://127.0.0.1:8000/
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*HTTPClient).Call
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/caclient.go:38
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*StorkAgent).ForwardToKeaOverHTTP
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/agent.go:240
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/api._Agent_ForwardToKeaOverHTTP_Handler
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/api/agent.pb.go:1361
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).processUnaryRPC
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1024
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).handleStream
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1313
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).serveStreams.func1.1
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:722
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357 URL="http://127.0.0.1:8000/"
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] keaintercept.go:109 failed to parse Kea responses while invoking asynchronous handlers for command config-get: unexpected end of JSON input
Sep 16 22:35:48 ladc01 stork-agent[19743]: failed to parse responses from Kea:
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/appctrl/kea.UnmarshalResponseList
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/appctrl/kea/kea_command.go:152
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*keaInterceptor).asyncHandle
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/keaintercept.go:107
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] agent.go:244 Failed to forward commands to Kea CA: Post http://127.0.0.1:8000/: dial tcp 127.0.0.1:8000: connect: connection refused
Sep 16 22:35:48 ladc01 stork-agent[19743]: problem with sending POST to http://127.0.0.1:8000/
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*HTTPClient).Call
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/caclient.go:38
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*StorkAgent).ForwardToKeaOverHTTP
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/agent.go:240
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/api._Agent_ForwardToKeaOverHTTP_Handler
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/api/agent.pb.go:1361
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).processUnaryRPC
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1024
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).handleStream
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1313
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).serveStreams.func1.1
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:722
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357 URL="http://127.0.0.1:8000/"
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] agent.go:244 Failed to forward commands to Kea CA: Post http://127.0.0.1:8000/: dial tcp 127.0.0.1:8000: connect: connection refused
Sep 16 22:35:48 ladc01 stork-agent[19743]: problem with sending POST to http://127.0.0.1:8000/
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*HTTPClient).Call
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/caclient.go:38
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*StorkAgent).ForwardToKeaOverHTTP
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/agent.go:240
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/api._Agent_ForwardToKeaOverHTTP_Handler
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/api/agent.pb.go:1361
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).processUnaryRPC
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1024
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).handleStream
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1313
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).serveStreams.func1.1
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:722
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357 URL="http://127.0.0.1:8000/"
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] agent.go:244 Failed to forward commands to Kea CA: Post http://127.0.0.1:8000/: dial tcp 127.0.0.1:8000: connect: connection refused
Sep 16 22:35:48 ladc01 stork-agent[19743]: problem with sending POST to http://127.0.0.1:8000/
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*HTTPClient).Call
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/caclient.go:38
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*StorkAgent).ForwardToKeaOverHTTP
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/agent.go:240
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/api._Agent_ForwardToKeaOverHTTP_Handler
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/api/agent.pb.go:1361
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).processUnaryRPC
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1024
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).handleStream
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1313
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).serveStreams.func1.1
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:722
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357 URL="http://127.0.0.1:8000/"
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] agent.go:244 Failed to forward commands to Kea CA: Post http://127.0.0.1:8000/: dial tcp 127.0.0.1:8000: connect: connection refused
Sep 16 22:35:48 ladc01 stork-agent[19743]: problem with sending POST to http://127.0.0.1:8000/
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*HTTPClient).Call
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/caclient.go:38
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*StorkAgent).ForwardToKeaOverHTTP
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/agent.go:240
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/api._Agent_ForwardToKeaOverHTTP_Handler
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/api/agent.pb.go:1361
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).processUnaryRPC
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1024
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).handleStream
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:1313
Sep 16 22:35:48 ladc01 stork-agent[19743]: google.golang.org/grpc.(*Server).serveStreams.func1.1
Sep 16 22:35:48 ladc01 stork-agent[19743]: /root/go/pkg/mod/google.golang.org/grpc@v1.27.0/server.go:722
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357 URL="http://127.0.0.1:8000/"
Sep 16 22:35:48 ladc01 stork-agent[19743]: ERRO[2020-09-16 22:35:48] keaintercept.go:109 failed to parse Kea responses while invoking asynchronous handlers for command config-get: unexpected end of JSON input
Sep 16 22:35:48 ladc01 stork-agent[19743]: failed to parse responses from Kea:
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/appctrl/kea.UnmarshalResponseList
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/appctrl/kea/kea_command.go:152
Sep 16 22:35:48 ladc01 stork-agent[19743]: isc.org/stork/agent.(*keaInterceptor).asyncHandle
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/backend/agent/keaintercept.go:107
Sep 16 22:35:48 ladc01 stork-agent[19743]: runtime.goexit
Sep 16 22:35:48 ladc01 stork-agent[19743]: /build/tools/1.13.5/go/src/runtime/asm_amd64.s:1357
Sep 16 22:35:48 ladc01 stork-agent[19743]: DEBU[2020-09-16 22:35:48] rndc.go:45 rndc: [rndc -s 127.0.0.1 -p 953 -k /etc/bind/rndc.key status]
^C
here are the versions:
ii isc-kea-admin 1.8.0-isc0000420200825110759 amd64 Administration utilities for ISC Kea DHCP server
ii isc-kea-common 1.8.0-isc0000420200825110759 amd64 Common libraries for the ISC Kea DHCP server
ii isc-kea-ctrl-agent 1.8.0-isc0000420200825110759 amd64 ISC Kea DHCP server REST API service
ii isc-kea-dhcp4-server 1.8.0-isc0000420200825110759 amd64 ISC Kea IPv4 DHCP server
ii isc-stork-agent 0.11.0.200904152903 amd64 ISC Stork Agent
``
root@ladc01:~# cat /etc/debian_version
10.5
Edited by Michal Nowikowski