Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • forge forge
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 2
    • Merge requests 2
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ISC Open Source ProjectsISC Open Source Projects
  • forgeforge
  • Merge requests
  • !312

wait for "keactrl stop" to take effect

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Andrei Pavel requested to merge keactrl into master Sep 14, 2022
  • Overview 1
  • Commits 1
  • Pipelines 1
  • Changes 2

This should solve the intermittent failures on the test_radius_*.

What happens is that, for non-relevant reasons, RADIUS tests restart Kea servers at some point. When Kea is stopped via keactrl stop, forge doesn't wait for Kea to actually stop and just issues another keactrl start. This works most of the time, but when libdhcp_radius.so, Kea takes around 25 milliseconds to deregister radius as a host backend. Here is a log that shows that:

113-2022-09-08 15:23:05.279 DEBUG [kea-dhcp4.commands/3081227.140598081251776] COMMAND_DEREGISTERED Command version-get deregistered
114:2022-09-08 15:23:05.304 DEBUG [kea-dhcp4.hosts/3081227.140598081251776] HOSTS_BACKEND_DEREGISTER deregistered host backend type: radius

25ms is a lot, because when radius is not configured, everything happens in under a millisecond, such that you're lucky if you see the timestamp change from keactrl stop to the last log of Kea. And It's enough for keactrl start to not take effect because it sees the pidfile is still there, because Kea is not stopped.

So the suggested fix is to make keactrl stop wait for Kea to stop.

Here it is running a job. All radius tests pass: https://jenkins.aws.isc.org/view/Kea-manual/job/kea-manual/job/tarball-system-tests/158/

Edited Sep 14, 2022 by Andrei Pavel
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: keactrl