fix/refactor/snapshot and free shadow page