Rescheduling an Inference Job

If a node, processor, or other fault occurs in an inference job, the MindCluster cluster scheduling components can isolate the faulty resource and automatically trigger rescheduling. For details about the fault detection principles, see Fault Detection.

Prerequisite

You have performed operations in Deploying MindIE Motor.

Supported Fault Type

Rescheduling Principles

Configuring Job-Level Rescheduling

Job-level rescheduling is enabled by default. You only need to prepare a job YAML file. The following uses MindIE Server as an example to describe how to configure job-level rescheduling.

apiVersion: mindxdl.gitee.com/v1
kind: AscendJob
metadata:
  name: mindie-server-0
  namespace: mindie
  labels:
    framework: pytorch        
    app: mindie-ms-server       # Role of MindIE Motor in the AscendJob, which cannot be changed.
    jobID: mindie-ms-test       # Unique ID of the MindIE Motor inference job in the cluster. Change the ID as required.
    fault-scheduling: force    # Enable rescheduling.
    ring-controller.atlas: ascend-910b
spec:
  schedulerName: volcano    # Scheduler selected when Ascend Operator enables gang scheduling.
  runPolicy:
    schedulingPolicy:     # This field takes effect only when Ascend Operator enables gang scheduling and Volcano is used as the scheduler.
      minAvailable: 2    # Total number of running job replicas
      queue: default
  successPolicy: AllWorkers
  replicaSpecs:
    Master:

Configuring Pod-Level Rescheduling

Currently, pod-level rescheduling is supported only by MS Controller and MS Coordinator. You are advised to enable this function when active/standby switchover is enabled. The following uses MS Coordinator as an example to describe how to configure pod-level rescheduling.

apiVersion: mindxdl.gitee.com/v1
kind: AscendJob
metadata:
  name: mindie-coordinator
  namespace: mindie
  labels:
    framework: pytorch        
    app: mindie-ms-coordinator        # Role of MindIE Motor in the AscendJob, which cannot be changed.
    jobID: mindie-ms-test             # Unique ID of the MindIE Motor inference job in the cluster. Change the ID as required.
   fault-scheduling: force           # Enable rescheduling.
   pod-rescheduling: "on"           # Enable pod-level rescheduling
    ring-controller.atlas: ascend-910b
spec:
  schedulerName: volcano    # Scheduler selected when Ascend Operator enables gang scheduling.
  runPolicy:
    schedulingPolicy:     # This field takes effect only when Ascend Operator enables gang scheduling and Volcano is used as the scheduler.
      minAvailable: 2       # Total number of running job replicas
      queue: default
  successPolicy: AllWorkers
  replicaSpecs:
    Master: