You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: cmd/job/submit.go
+7-2Lines changed: 7 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -70,6 +70,9 @@ var (
70
70
volumeStr []string
71
71
pathways orchestrator.PathwaysJobDefinition
72
72
73
+
mtcEnabledbool
74
+
ramdiskDirectorystring
75
+
73
76
gkeNapProvisioningstring
74
77
gkeNapReservationstring
75
78
@@ -180,8 +183,8 @@ func init() {
180
183
SubmitCmd.Flags().StringArrayVar(&pathwaysWorkerEnv, "pathways-worker-env", []string{}, "Custom environment variables for the Pathways worker container in KEY=VALUE format. Can be specified multiple times.")
181
184
SubmitCmd.Flags().StringVar(&pathways.ColocatedPythonSidecarImage, "pathways-colocated-python-sidecar-image", "", "Image for an optional Python-based sidecar container to run alongside the Pathways head components.")
182
185
SubmitCmd.Flags().StringVar(&pathways.HeadNodePool, "pathways-head-np", "", "The node pool to use for the Pathways head job. If empty, it will be auto-detected (looking for 'cpu-np' or 'pathways-np').")
183
-
SubmitCmd.Flags().BoolVar(&pathways.MTCEnabled, "pathways-mtc-enabled", false, "Enable Multi-Tier Checkpointing (MTC) for Pathways.")
184
-
SubmitCmd.Flags().StringVar(&pathways.RamdiskDirectory, "pathways-ramdisk-directory", "", "The ramdisk directory path for local checkpoints in MTC.")
Copy file name to clipboardExpand all lines: docs/gcluster_job_guide.md
+8-2Lines changed: 8 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,6 +29,12 @@ If you use `--build-context` to build images on-the-fly, you must set:
29
29
>
30
30
> Successful checks are remembered in `~/.gcluster/job_prereq_state.json` to optimize subsequent runs. Checks are re-run if the state is older than 24 hours or if you switch projects.
If you plan to use Multi-Tier Checkpointing (`--mtc-enabled` flag), ensure that your cluster was created with `enable_multi_tier_checkpointing = true` (or `stateful_ha_config { enabled = true }`).
35
+
36
+
To use this feature, the cluster administrator must deploy the required `CheckpointConfiguration` Custom Resource globally at cluster creation. This is done by specifying the `mtc_target_bucket` variable in the Terraform blueprint. Job submitters then only need to pass `--mtc-enabled` to their jobs.
37
+
32
38
## 2. Prepare Sample Application Code
33
39
34
40
Create a directory named `job_details` and place your application files inside it. This will serve as your build context for the job. The tool will package all files in this directory and add them to the image.
@@ -1098,6 +1104,8 @@ The `gcluster job submit` command deploys a container image as a job (Kubernetes
1098
1104
| `--env` | `stringArray` | Custom environment variables to pass exclusively to the user's workload container in KEY=VALUE format (e.g. `--env KEY=VALUE`). Applies to both standard and Pathways workloads. Can be specified multiple times. |
1099
1105
|`--await-job-completion`|`bool`| If true, the CLI waits for the job to complete before exiting. |
1100
1106
|`--timeout`|`string`| Time to waitfor job completion (e.g., `1h`, `10m`). Used with `--await-job-completion`. |
1107
+
|`--mtc-enabled`|`flag`| If present, enables Multi-Tier Checkpointing (MTC) for the workload. |
1108
+
|`--mtc-ramdisk-directory`|`string`| The ramdisk directory path forlocal checkpointsin MTC (defaults to `/tmp/mtc_checkpoints`). |
1101
1109
|`--verbose`|`bool`| Enable verbose logging for the workload. |
1102
1110
1103
1111
*(Note: `--cluster`, `--location`, and `--project` are also supported as common flags, see 9.1)*
@@ -1124,8 +1132,6 @@ The `gcluster job submit` command deploys a container image as a job (Kubernetes
1124
1132
|`--pathways-worker-env`|`stringArray`| Custom environment variables injected specifically into the Pathways worker containers (KEY=VALUE). |
1125
1133
|`--pathways-colocated-python-sidecar-image`|`string`| Image for an optional Python-based sidecar container running alongside workers. |
1126
1134
|`--pathways-head-np`|`string`| The node pool name to target for the Pathways head job. |
1127
-
|`--pathways-mtc-enabled`|`flag`| If present, enables Multi-Tier Checkpointing (MTC) for the Pathways workload. |
1128
-
|`--pathways-ramdisk-directory`|`string`| The ramdisk directory path forlocal checkpointsin MTC (defaults to `/tmp/mtc_checkpoints`). |
1129
1135
1130
1136
#### 9.3.3 GPU Related Flags
1131
1137
*Use these flags to tune specialized multi-GPU topologies and related node parameters.*
returnfmt.Errorf("MTC is not enabled on cluster '%s'. If you created your cluster using Cluster Toolkit, you can enable MTC by updating your cluster blueprint's gke-cluster module settings with:\n enable_multi_tier_checkpointing: true\n mtc_target_bucket: \"gs://YOUR_BUCKET\"\n mtc_cache_size: \"50Gi\"\nThen run 'gcluster deploy'. For clusters provisioned otherwise or for underlying GKE concepts, see: https://docs.cloud.google.com/kubernetes-engine/docs/how-to/machine-learning/training/multi-tier-checkpointing", job.ClusterName)
0 commit comments