First draft of 'resync-root' script.
DO NOT USE without checking first.