Skip to content

Commit 1646126

Browse files
committed
Update error message for disk compatibility with machine family
1 parent 58694ce commit 1646126

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/gce-pd-csi-driver/controller.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,7 @@ func (gceCS *GCEControllerServer) executeControllerPublishVolume(ctx context.Con
548548
// If we encountered an UnsupportedDiskError, rewrite the error message to be more user friendly.
549549
// The error message from GCE is phrased around disk create on VM creation, not runtime attach.
550550
machineFamily := parseMachineFamily(instance.MachineType)
551-
return nil, status.Errorf(codes.Internal, "'%s' is not a compatible disk type with the machine family '%s', please review the GKE online documentation for available persistent disk options", udErr.DiskType, machineFamily)
551+
return nil, status.Errorf(codes.InvalidArgument, "'%s' is not a compatible disk type with the machine family '%s', please review the GCP online documentation for available persistent disk options", udErr.DiskType, machineFamily)
552552
}
553553
return nil, status.Errorf(codes.Internal, "unknown Attach error: %v", err.Error())
554554
}

0 commit comments

Comments
 (0)