简体   繁体   English

cx_Oracle 和 Lambda 层错误 - aws lambda 找不到 64 位 oracle 客户端库

[英]cx_Oracle and Lambda Layer error - aws lambda cannot locate a 64-bit oracle client library

I created the lambda layer using cx_oracle and oracle-instantclient.我使用 cx_oracle 和 oracle-instantclient 创建了 lambda 层。 Created the lambda layer and am able import the cx_oracle but it is always gives me an error like 64-bit oracle client library is missing.创建了 lambda 层并能够导入 cx_oracle,但它总是给我一个错误,如 64 位 oracle 客户端库丢失。 below is my folder structure下面是我的文件夹结构

在此处输入图像描述

There could be several root causes of this issue.这个问题可能有几个根本原因。

  1. Check the file structure in the AWS console.检查 AWS 控制台中的文件结构。 You can also try to debug the lambda by listing the files from the layer you use.您还可以通过列出您使用的层中的文件来尝试调试 lambda。 Try to check the correctness of the path with - Including library dependencies in a layer .尝试使用- 在层中包含库依赖项来检查路径的正确性。
  2. For cx_Oracle you also need to set an env var LD_LIBRARY_PATH pointing to the place where the libs are placed.对于 cx_Oracle,您还需要设置一个指向库所在位置的环境变量LD_LIBRARY_PATH You can update it on the lambda page in AWS console.您可以在 AWS 控制台的 lambda 页面上更新它。 As the layer is in /opt folder provide the path where the module with libs is installed.由于该层位于/opt文件夹中,请提供安装带有 libs 的模块的路径。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 cx_Oracle 错误。 DPI-1047:找不到 64 位 Oracle 客户端库 - cx_Oracle error. DPI-1047: Cannot locate a 64-bit Oracle Client library cx_Oracle 连接失败并显示“DPI-1047:找不到 64 位 Oracle 客户端库” - cx_Oracle connection fails with 'DPI-1047: Cannot locate a 64-bit Oracle Client library' 使用即时客户端通过 Python3 (cx_Oracle) 连接到 Oracle 数据库时出现错误“DPI-1047:无法找到 64 位 Oracle 客户端库” - Error “DPI-1047: Cannot locate a 64-bit Oracle Client library” when connecting to Oracle Database with Python3 (cx_Oracle) using instant client 使用Python的Oracle DB连接错误-cx_Oracle:无法找到32位Oracle Client库 - Oracle DB connection error with Python - cx_Oracle: cannot locate a 32-bit Oracle Client library cx_Oracle.DatabaseError: DPI-1047: 无法找到 64 位 Oracle 客户端库 UBUNTU - cx_Oracle.DatabaseError: DPI-1047: Cannot locate a 64-bit Oracle Client library UBUNTU Linux。 连接到 Oracle。 cx_Oracle.DatabaseError:DPI-1047 找不到 64 位 Oracle 客户端库:“libclntsh.so - Linux. Connect ot Oracle. cx_Oracle.DatabaseError: DPI-1047 Cannot locate a 64-bit Oracle Client library: "libclntsh.so 当Python和Oracle均为64位时,为什么cx_Oracle会给出错误的体系结构错误? - Why is cx_Oracle giving incorrect architecture error when both Python and Oracle are 64-bit? 64位cx_Oracle:DLL加载失败 - 64-bit cx_Oracle: DLL load failed Crontab 错误:找不到 64 位 Oracle 客户端库:“libclntsh.so:无法打开共享 object 文件:没有这样的文件或目录 - Crontab error: Cannot locate a 64-bit Oracle Client library: "libclntsh.so: cannot open shared object file: No such file or directory Python cx_Oracle“无法加载32位Oracle Client库:“找不到指定的模块”” - Python cx_Oracle “32-bit Oracle Client library cannot be loaded: ”The specified module could not be found“”
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM