fail and restore