Working with the CLI

Prerequisite

Install ADS CLI

Running a Pre Defined Job

ads opctl run --ocid <job ocid>

Delete Job or Job Run

ads opctl delete <job-id or run-id>

Cancel Job Run

ads opctl cancel <run-id>

Cancel Distributed Training Job

Stop a running cluster using cancel subcommand.

Option 1: Using Job OCID and Work Dir

ads opctl cancel <job ocid> --work-dir <Object storage working directory specified when the cluster was created>

Option 2: Using cluster info file

Cluster info file is a yaml file with output generated from ads opctl run -f

ads opctl cancel <job ocid> --work-dir <Object storage working directory specified when the cluster was created>

This command requires an api key or resource principal setup. The logs are streamed from the logging service. If your job is not attached to logging service, this option will show only the lifecycle state.