SDP-352

Robert Cowham
Closed
Eliminate excessive journal rotations on p4d startup.

We want to get closer to the comfortable, familiar old idea that
"one journal rotation is roughly one day."

Change @22215 introduced a change to rotate the journal on every
p4d startup.  This was done for good reason:  In the event of
journal corruption, e.g. in a 'sudden death' scenario for the
master server, we want any corruption to be at the tail end of
the journal file.  Rotating the journal on p4d start ensures
that any corruption is always at the end of a journal file.

In sophisticated topolgies when there is a "sudden death" of
the master server, having journal corruption reliablhy at the
end of a journal file can be a life saver, especially if you
have a global topology replica and edge servers that need to
be adjusted to skip the busted journal entries.

HOWEVER, rotating the journal on every p4d startup causes
confusion, and violates the "principal of least surprise."
On a maintenance window with lots of things going on like
sanity checks, p4d may be restarted a dozen times or so over
the course of a long weekend.  You may have thought you
had KEEPLOGS/KEEPJNLS/KEEPCKPS settings to preserve, say 14
days worth of data, but reallly it is 14 journal rotataions,
and they can get gobbled up fast in a maintenanc window.

So, we want the "Have our cake and eat it to" solution.

We want journal courrption to be reliably at the end of
of journal file, but we don't want excessive journal
rotations.  So, with SDP-351, we're adding detection
of journal corruption to the preflight checks done
during p4d startup.  If we detect corruption, we will
rotate the journal on startup.  Otherwise, we won't.

See also:  SDP-351
Status
Closed
Project
perforce-software-sdp
Severity
C
Reported By
robert_cowham
Reported Date
Modified By
robert_cowham
Modified Date
Owned By
tom_tyler
Component
core-unix
Type
Feature