All Products
Search
Document Center

MaxCompute:ODPS-0123144

Last Updated:Aug 07, 2024

This topic describes the possible causes of the error code ODPS-0123144: Fuxi job failed and provides solutions.

Error message 1: kInstanceMonitorTimeout(errCode:252) at Odps/xxx/xxx. Detail error msg: CRASH_EXIT, usually caused by bad udf performance

Sample

ODPS-0123144: Fuxi job failed - kInstanceMonitorTimeout(errCode:252) at Odps/xxx/xxx. Detail error msg: CRASH_EXIT, usually caused by bad udf performance.

Description

Data processing by a MaxCompute user-defined function (UDF) times out. By default, the time for a UDF to process data is limited. In most cases, 1,024 records must be completely processed within 1,800s. This time limit is not imposed on the total duration in which a worker runs but is used to specify the maximum duration in which a small batch of records is processed. In most cases, an SQL job can process more than 10,000 records per second. This limit prevents infinite loop issues of MaxCompute UDFs and improves CPU utilization.

Solution

If PyODPS is used, add log information to the MaxCompute UDF code. This way, you can view logs to check whether an infinite loop occurs in the code. You can also check whether the duration in which the MaxCompute UDF processes a single record meets your expectation based on the time information recorded in the logs. Add the following information about logging to the code. After the job runs, you can view the logs in StdOut of the LogView UI.

If the error occurs when you use Java UDFs, implement the solution that is described in Performance issues.

  • Python 2

    sys.stdout.write('your log')
    sys.stdout.flush()
  • Python 3

    print('your log', flush=True)

If a large amount of data needs to be computed, the MaxCompute UDF may run for a long period of time to process the data. You can adjust the following configurations to prevent the timeout error.

Configuration

Description

set odps.function.timeout=xxx;

The timeout period of a MaxCompute UDF. Default value: 1800. Unit: seconds. You can set the parameter to a larger value based on your business requirements. Valid values: 1 to 3600.

set odps.sql.executionengine.batch.rowcount=xxx;

The number of data rows that a MaxCompute UDF can process at a time. Default value: 1024. You can set the parameter to a smaller value based on your business requirements.