Grep the snapshot id correctly