refactor lun survey code