Though it is somewhat plausible that mineral deficiencies would lead to cramping, the data does not support it. Two large studies have been performed on marathon runners and cramping, both of which failed to show any correlation between mineral concentrations and cramping.
Here's one.
I've also taken care of many, many folks in the hospital with extreme disturbances in mineral concentrations, and have never seen anyone with low potassium or sodium have a muscle cramp. Hypocalcemia, yes, but only at levels caused by pathological conditions (parathyroid removal being the most common scenario).
Muscle cramping is common, however, in those with glycogen storage disorders. Based on this model, it is likely that muscle glycogen depletion is at the root of muscle cramping amongst those transitioning to primal, especially those who are very active. So first step would be make sure you're getting enough starch pre-race.
If that alone doesn't do it, then
drink a little pickle juice before the race and keep a little shot of it handy during it. The mechanism is still unclear, but it works.