

 从补丁 198 开始，Amazon Redshift 将不再支持创建新的 Python UDF。现有的 Python UDF 将继续正常运行至 2026 年 6 月 30 日。有关更多信息，请参阅[博客文章](https://aws.amazon.com/blogs/big-data/amazon-redshift-python-user-defined-functions-will-reach-end-of-support-after-june-30-2026/)。

# STL\$1S3CLIENT\$1ERROR
<a name="r_STL_S3CLIENT_ERROR"></a>

记录从 Amazon S3 加载文件时切片遇到的错误。

使用 STL\$1S3CLIENT\$1ERROR 来查找在从 Amazon S3 传输数据（作为 COPY 命令的一部分）时遇到的错误的详细信息。

STL\$1S3CLIENT\$1ERROR 对所有用户可见。超级用户可以查看所有行；普通用户只能查看其自己的数据。有关更多信息，请参阅 [系统表和视图中的数据可见性](cm_chap_system-tables.md#c_visibility-of-data)。

## 表列
<a name="r_STL_S3CLIENT_ERROR-table-columns2"></a>

[\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/zh_cn/redshift/latest/dg/r_STL_S3CLIENT_ERROR.html)

## 使用说明
<a name="w2aac59c29b9c97c11"></a>

如果您看到多个包含“Connection timed out”的错误，您可能遇到了联网问题。如果您使用的是增强型 VPC 路由，请确认您在集群的 VPC 与数据资源之间具有有效的网络路径。有关更多信息，请参阅 [Amazon Redshift 增强型 VPC 路由](https://docs.aws.amazon.com/redshift/latest/mgmt/enhanced-vpc-routing.html)。

## 示例查询
<a name="w2aac59c29b9c97c13"></a>

以下查询返回当前会话期间完成的 COPY 命令中的错误。

```
select query, sliceid, substring(key from 1 for 20) as file, 
substring(error from 1 for 35) as error  
from stl_s3client_error 
where pid = pg_backend_pid()
order by query desc;
```

结果

```
 query  | sliceid |     file           |              error                             
--------+---------+--------------------+------------------------------------
 362228 |      12 | part.tbl.25.159.gz | transfer closed with 1947655 bytes 
 362228 |      24 | part.tbl.15.577.gz | transfer closed with 1881910 bytes 
 362228 |       7 | part.tbl.22.600.gz | transfer closed with 700143 bytes r 
 362228 |      22 | part.tbl.3.34.gz   | transfer closed with 2334528 bytes 
 362228 |      11 | part.tbl.30.274.gz | transfer closed with 699031 bytes r
 362228 |      30 | part.tbl.5.509.gz  | Unknown SSL protocol error in conne
 361999 |      10 | part.tbl.23.305.gz | transfer closed with 698959 bytes r
 361999 |      19 | part.tbl.26.582.gz | transfer closed with 1881458 bytes 
 361999 |       4 | part.tbl.15.629.gz | transfer closed with 2275907 bytes 
 361999 |      20 | part.tbl.6.456.gz  | transfer closed with 692162 bytes r
(10 rows)
```