prepare for snapshot