Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Nov 2018 15:26:20 +0000
From:      bugzilla-noreply@freebsd.org
To:        pkg@FreeBSD.org
Subject:   [Bug 232350] ports-mgmt/pkg: periodic pkg-checksum and pkg-backup interfere with 'overnight' port builds
Message-ID:  <bug-232350-32340-4SmZUeQ3XT@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-232350-32340@https.bugs.freebsd.org/bugzilla/>
References:  <bug-232350-32340@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=232350

--- Comment #11 from Ian Lepore <ian@FreeBSD.org> ---
(In reply to Alex Kozlov from comment #10)

It is not an error or a problem to be working on a snapshot of the database
taken at the beginning of the periodic run.  This is a standard axiom of fixing
races with lockless (or lock minimization) techniques... it doesn't matter
whether you capture the snapshot before or after some arbitrary action, it only
matters that you capture and operate on a consistant snapshot.  If updates are
happening to the live database while you run the validation on the snapshot,
those updates will be validated in the run the next day, and that situation is
exactly identical to the situation in which running with exclusionary locks
prevented the update from happening until after the validation run completes.

These are not new problems, and the techniques for solving them are not new
either.  I first ran into these problems and the snapshot-based solutions to
them in the 1970s.

The main downside to such techniques is that it requires copying the data to be
validated, and sometimes the size of that data makes that too expensive of an
operation.  That could be the case here, I have no idea how much data would
have to be copied in this instance.

-- 
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-232350-32340-4SmZUeQ3XT>