rearranging to run offline for D2