5

DBD, and Oracle Masters:

I have a Perl web application that is behaving oddly. I am using it to read some stuff from an Oracle DB and report. I have version 11.1.0.6.0 of Oracle's Instant Client installed. I'm running on WinXP and have the PATH environment variable set to the instant client location. I have Apache2 for my webserver.

Here's the issue: when I run the app from a command line, it works without a hitch. However, when I run from http://127.0.0.1/cgi-bin/a.cgi, I get the following DB access error:

install_driver(Oracle) failed: Can't load 'C:/usr/lib/auto/DBD/Oracle/Oracle.dll' for module DBD::Oracle: load_file:The specified module could not be found at C:/usr/lib/DynaLoader.pm line 202. at (eval 9) line 3

Intuition tells me it's a permission issue, but I'm not sure where to look further. Can anyone shed some light on this? I would much appreciate any help.

Thanks, Saker Ghani

4

3 回答 3

2

The fact that the error shows the full path of the .DLL suggests that the system isn't having any trouble finding the DLL, so that does back your theory that file permissions are the issue.

To test whether it really is a permissions issue, try writing a trivial Perl CGI script which does nothing but directly open that specific .DLL file (with a normal open call) and reports whether it worked or not.

于 2008-11-16T22:17:39.450 回答
1

谢谢阿尔尼塔克。我尝试按照您的建议进行操作,并且“打开”成功打开了“C:/usr/lib/auto/DBD/Oracle/Oracle.dll”。我记得当我在另一台机器上开发时看到了这个确切的错误,但那是因为 Oracle Instant Client 库在它上面丢失了。在我安装这些并设置“路径”变量之后,一切都开始正常工作了。

于 2008-11-16T22:56:37.047 回答
1

我遇到了同样的问题,通过接口访问 cgi perl 程序时报告错误“Install_driver(Oracle) failed: Can't load 'C:/Perl/lib/auto/DBD/Oracle/Oracle.dll' for模块 DBD::Oracle: load_file:Access is denied at C:/Perl/lib/DynaLoader.pm line 201"。

我在带有 IIS 6 的 Window 2003 Server 上使用 Perl 5.10。

解决方案是将 Perl 目录的权限授予“所有人”以及 Oracle 安装文件夹。

于 2010-06-20T22:22:22.920 回答