A genetic memory initiates the epigenetic loop necessary to preserve centromere position