Agent install bug fixes