Hi, I tried to schedule a batch job with the following requirement, but it gives me CODE_MACHINE_TYPE_NOT_FOUND, I am wondering why is that? There are a lot of N2 machine types that can satisfy my need but Batch seems to limit itself to e2 machine types.
Solved! Go to Solution.
Hi @gradientopt,
For custom machine types, you can view this documentation to check if the custom machine type is available and valid.
Next, in your JSON or YAML file configuration, if you are using machine types other than e2, kindly try to specify the machine type in the allocationPolicy.
You may follow the code blocks below for the sample.
JSON:
"allocationPolicy": { "instances": [ { "policy": { "machineType": "n2-standard-80" } } ] },
YAML:
allocationPolicy: instances: - policy: machineType: n2-standard-80"
If the above options don't work, as @wenyhu said, you can send your job request so we can check. Otherwise, you can contact Google Cloud Support to further look into your case. Thank you!
Hi @gradientopt could you share your job json request content to us for further investigation? Thanks!
Hi @gradientopt,
For custom machine types, you can view this documentation to check if the custom machine type is available and valid.
Next, in your JSON or YAML file configuration, if you are using machine types other than e2, kindly try to specify the machine type in the allocationPolicy.
You may follow the code blocks below for the sample.
JSON:
"allocationPolicy": { "instances": [ { "policy": { "machineType": "n2-standard-80" } } ] },
YAML:
allocationPolicy: instances: - policy: machineType: n2-standard-80"
If the above options don't work, as @wenyhu said, you can send your job request so we can check. Otherwise, you can contact Google Cloud Support to further look into your case. Thank you!
Thanks for the reply! Just make sure I understand, if my memory requirement is say 200GB, which no e2 machine can satisfy, then I have to set machineType myself? Why can't I leave it to None as usual and let GCP Batch to help me allocate optimally?
Hi @gradientopt,
Unfortunately currently Batch only supports e2 series machines as the default machine types for the Batch non-GPU cases. You have to manually set the machine type as @lawrencenelson mentioned.
But thanks for the valuable feedback! We are planning to support more default machine types besides e2 machines.
Thanks!
Wenyan
Got it, thanks a lot! Hoping to see the new feature release !