Wait for rs.status() to return ok=1 after rs initiation