Introduction
If a Redshift extract fails in Kleene with an error such as "ERROR: Load into table '<tablename>' failed. Check 'stl_load_errors' system table for details.", you can use Amazon Redshift system tables to find the underlying cause. This article explains how to inspect the error details and identify the logged reason for the failure.
Issue description
A Redshift extract load error usually means Redshift could not load data into the target table. The message shown in Kleene is often high level, while the specific failure details are stored in the Redshift system table STL_LOAD_ERRORS.
Signs
You may be experiencing this issue if you see one or more of the following:
- An extract job fails with a Redshift load error message.
- The message mentions STL_LOAD_ERRORS or a failed load into a table.
- You need more detail than the error shown in Kleene provides.
Basic troubleshooting steps
Use the following checklist to investigate the failure:
- Confirm the extract error message mentions a Redshift load failure.
- Connect to the Redshift cluster or database used by the extract.
- Run a query against the Redshift system table STL_LOAD_ERRORS.
- Review the err_reason column for the logged error details.
Advanced troubleshooting steps
Step 1: Query STL_LOAD_ERRORS
Run the following SQL statement in Redshift:
SELECT * FROM STL_LOAD_ERRORS;This returns the load error records captured by Redshift.
Step 2: Review err_reason
Inspect the err_reason column in the query results. This field contains the extra information logged about the error and should help you identify the cause of the failed extract load.
Summary
When a Redshift extract fails in Kleene, the detailed cause is often stored in Redshift rather than in the extract error message itself. Query STL_LOAD_ERRORS and check err_reason to find the additional logged detail.
Next steps
If the err_reason message does not clearly explain the failure, review the source data, table definition, and load configuration used by the extract. You can also contact Kleene support with the Redshift error details for further assistance.
Additional information
For best results, keep a copy of the full Redshift error output and the value returned in err_reason when you investigate or report the issue.