[stork-users] COMMAND_SOCKET_CONNECTION_SHUTDOWN_FAIL
Slawek Figiel
slawek at isc.org
Thu Mar 6 10:03:21 UTC 2025
Sébastien,
> Can you confirm that kea & stork agent need to use the same socket ?
What do you mean that Kea CA and Stork agent use the same socket?
The communication between Kea CA and the Stork agent is done over HTTP.
Stork and Kea CA listen on specific ports. The HTTP libraries open some
sockets on demand under the hood, but they shouldn't cause any collisions.
The sockets are also used to establish a connection from Kea CA to Kea
DHCP daemons.
> Also, even if the communication with each component seems to work well,
> can you confirm which ports should be used by each component (kea
> control agent, stork agent, ...) ?
Kea CA listens on port 8000 by default. It is configurable in
`kea-ctrl-agent.conf` file in the "http-port" property.
Stork agent listens on port 8080 (CLI argument "--port") and 9547 (CLI
argument "--prometheus-kea-exporter-port") and 9119 (CLI argument
"--prometheus-bind9-exporter-port").
I suppose some sockets used during the HTTP connection are not correctly
closed on FreeBSD. It may be a bug in an HTTP library, or BSD-like
systems may require additional steps to close connection or specific
permissions to manage sockets fully.
Another possibility is that the Stork HTTP library improperly closes the
HTTP connection, and the problem exists only on FreeBSD because it has a
more strict network stack.
I think the problem may not be related to Stork itself but to the usage
of Kea RestAPI. I haven't checked it yet, but any request to this API
will probably generate a similar error message.
But I need to confirm it first. You can try to do it on your own if you
like.
Slawomir Figiel
On 3/5/25 8:22 AM, Sébastien Nauer wrote:
> Hello Slawek,
>
> Thank you for your message !
>
> We installed stork by following this documentation :
> https://stork.readthedocs.io/en/v2.1.1/install.html#installing-on-
> freebsd <https://stork.readthedocs.io/en/v2.1.1/install.html#installing-
> on-freebsd>
>
> FYI:
> We currently run 2 KEA instances in a lab environment without any
> traffic and this issue occurs when both services are simply running (kea
> + stork agent).
>
> Can you confirm that kea & stork agent need to use the same socket ?
> Also, even if the communication with each component seems to work well,
> can you confirm which ports should be used by each component (kea
> control agent, stork agent, ...) ?
>
> Thank you for your support on that topic.
> Best regards.
>
> Le mar. 4 mars 2025 à 14:08, Slawek Figiel <slawek at isc.org
> <mailto:slawek at isc.org>> a écrit :
>
> Hello Sébastien,
>
> We had no similar report so far.
>
> Unfortunately, we haven't tested Stork on the FreeBSD system. How do
> you
> install Stork on this operating system? Do you compile it on your own?
> Or rather, do you install it from some packages?
>
> I have no ready-to-use environment with FreeBSD, but I will configure
> one and try to reproduce the problem. Bear with me. I will contact you
> when I will know more.
>
> I opened https://gitlab.isc.org/isc-projects/stork/-/issues/1740
> <https://gitlab.isc.org/isc-projects/stork/-/issues/1740> to
> address the issue.
>
> Regards,
> Slawek Figiel
>
> On 3/4/25 9:08 AM, Sébastien Nauer wrote:
> > Hello,
> >
> > We use STORK for monitoring KEA instances and we notice repeating
> errors
> > in KEA logs :
> >
> > ...
> > 2025-02-23 08:31:22.383 INFO [kea-
> dhcp4.commands/533.0x186650a12000]
> > COMMAND_RECEIVED Received command 'version-get'
> > 2025-02-23 08:31:22.384 ERROR [kea-
> dhcp4.commands/533.0x186650a12000]
> > COMMAND_SOCKET_CONNECTION_SHUTDOWN_FAIL Encountered error Socket
> is not
> > connected while trying to gracefully shutdown socket
> > ...
> > 2025-02-23 08:31:53.036 INFO [kea-
> dhcp4.commands/533.0x186650a12000]
> > COMMAND_RECEIVED Received command 'version-get'
> > 2025-02-23 08:31:53.039 INFO [kea-
> dhcp4.commands/533.0x186650a12000]
> > COMMAND_RECEIVED Received command 'config-get'
> > 2025-02-23 08:31:53.308 ERROR [kea-
> dhcp4.commands/533.0x186650a12000]
> > COMMAND_SOCKET_CONNECTION_SHUTDOWN_FAIL Encountered error Socket
> is not
> > connected while trying to gracefully shutdown socket
> > ...
> >
> > As this error disappears when we stop the STORK AGENT on KEA
> instances,
> > it seems there is a conflict between STORK AGENT & KEA.
> >
> > We currently run :
> > * KEA instances v2.6.1 on FreeBSD 14.2
> > * STORK v2.1.1 on FreeBSD 14.2
> > * STORK Agent v2.1.1 on KEA instances
> >
> > Does someone have an idea of the root cause of this issue and how to
> > solve it ?
> > Best regards.
> >
> > --
> >
> > Inline-Bild 1
> >
> > *Sébastien NAUER <mailto:snauer at hotcity.lu
> <mailto:snauer at hotcity.lu>>*| Technical Manager
> > 11, Avenue Guillaume | L-1651 Luxembourg <http://goo.gl/maps/
> GqQcf <http://goo.gl/maps/GqQcf>>
> > Phone: (+352) 2663 2660 | Fax: (+352) 2663 2665
> > Facebook <https://www.facebook.com/hotcity.lu <https://
> www.facebook.com/hotcity.lu>> | Twitter <https://
> > twitter.com/hotcity_wifi <http://twitter.com/hotcity_wifi>>
> >
> >
>
>
>
> --
>
> Inline-Bild 1
>
> *Sébastien NAUER <mailto:snauer at hotcity.lu>*| Technical Manager
> 11, Avenue Guillaume | L-1651 Luxembourg <http://goo.gl/maps/GqQcf>
> Phone: (+352) 2663 2660 | Fax: (+352) 2663 2665
> Facebook <https://www.facebook.com/hotcity.lu> | Twitter <https://
> twitter.com/hotcity_wifi>
>
More information about the Stork-users
mailing list