Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 28 May 2026 15:16:50 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 242835] concurrency issue when building kernel with 'make -j8': make[5]: make[5]: don't know how to make opt_global.h. Stop
Message-ID:  <bug-242835-227-UShK6iCRVH@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-242835-227@https.bugs.freebsd.org/bugzilla/>

index | next in thread | previous in thread | raw e-mail

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=242835

--- Comment #7 from Martin Birgmeier <d8zNeCFG@aon.at> ---
I also still regularly get this with stable/15 at 6146c5962e5c.

There seem to be two components to the issue:
- opt_global.h is required in multiple parallel build branches, is determined
to be not up to date, and therefore must be (re)created. This seems to involve
removing the old/outdated file first if it exists.
- Doing this via NFS seems to result in slightly different visibility of
opt_global.h in these branches (filesystem state not fully synchronized or
different timing) compared to doing it in a local filesystem.

Possible race scenario:
- Build branches A and B determine opt_global.h to be outdated.
- Branch A removes the file.
- Branch A creates the file.
- Branch B removes the file.
- Branch A does not find the file.

Maybe the "remove" step could be left out somehow and any preexisting file just
be overwritten with the new contents. This might result in different issues,
though (e.g., incomplete file seen by another process). Or opt_global.h could
be generated without parallelism before make is allowed to continue with
parallel branches.

These are just the ideas of a non-expert, the actual cause and solution may be
totally different.

-- Martin

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

home | help

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