Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 12 Jun 2024 19:44:27 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 271460] ctld ports become inaccessible due to concurrent service restarts
Message-ID:  <bug-271460-227-z0Fp6H0a9M@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-271460-227@https.bugs.freebsd.org/bugzilla/>
References:  <bug-271460-227@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D271460

--- Comment #2 from Alan Somers <asomers@FreeBSD.org> ---
I've confirmed that the cause of the problem is that ctld opens its pidfile=
 too
late.  It reads the current list of targets from the kernel, then reads the
config file, then opens its pidfile, and then applies changes based on the
differences between the kernel's state and the config file.  But the kernel=
's
state could've changed before the pidfile got opened.

I've hacked ctld to open the pidfile earlier and verified that this fixes t=
he
problem.  However, doing it properly is hard, because the code for opening =
the
config file is intermingled with the code for interacting with the kernel. =
 The
biggest problem is the conf_pports list, added in
057abcb00413010898f3046f7704444b8f537bab .

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-271460-227-z0Fp6H0a9M>