oracle ORA-12638: 凭证检索失败

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/379164/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-10 01:41:09  来源:igfitidea点击:

ORA-12638: Credential retrieval failed

oracle

提问by Mike

I have a legacy VB6 application which I've inherited. The issue I'm facing is that I'm getting the infamous

我有一个继承的旧版 VB6 应用程序。我面临的问题是我得到了臭名昭著的

ORA-12638: Credential retrieval failed

error message whenever it tries to connect to one of our Oracle databases. I can connect fine from SQLPlus and Toad, however. I've Googled around and everyone seems to say that modifying their sqlnet.ora file to

每当它尝试连接到我们的 Oracle 数据库之一时都会出现错误消息。但是,我可以从 SQLPlus 和 Toad 正常连接。我用谷歌搜索了一下,似乎每个人都说将他们的 sqlnet.ora 文件修改为

SQLNET.AUTHENTICATION_SERVICES=(NONE)

did the trick. I have yet to find anyone with an alternative fix. Here is what my connection string looks like:

成功了。我还没有找到任何有替代解决方案的人。这是我的连接字符串的样子:

"PROVIDER=OraOLEDB.Oracle;DATA SOURCE=(DESCRIPTION = " & _
"(ADDRESS = (PROTOCOL = TCP)(HOST = server1)
(PORT = 1521))" & _
"(ADDRESS = (PROTOCOL = TCP)(HOST = server2)
(PORT = 1521))" & _
"(LOAD_BALANCE = yes) " & _
"(CONNECT_DATA = " & _
"(SERVER = DEDICATED) " & _
"(SERVICE_NAME = database_name_here) " & _
") " & _
"); " & _
"User Id=username_here;Password=password_here;"

As for my VB code, it's quite simple.

至于我的VB代码,很简单。

Private oracleDatabaseConnection As ADODB.Connection

Set oracleDatabaseConnection = New ADODB.Connection
oracleDatabaseConnection.Open oracleConnectionString

Anyone have any ideas?

谁有想法?

Thank you. :)

谢谢你。:)

采纳答案by Dave Costa

Honestly this is one of those errors that can be caused by lots of different root problems.

老实说,这是可能由许多不同的根本问题引起的错误之一。

On the assumption your database server is Windows, check its event log, both System and Application. You may find something there that is useful.

假设您的数据库服务器是 Windows,请检查其事件日志,包括系统和应用程序。您可能会在那里找到有用的东西。

I have encountered this error in some cases because the account under which the Oracle service was running got locked.

在某些情况下,我遇到此错误是因为运行 Oracle 服务的帐户被锁定。

I have also encountered it in cases where we never found the explanation, but we were always able to clear up the issue by having the user lock and unlock their PC.

在我们从未找到解释的情况下,我也遇到过这种情况,但我们总是能够通过让用户锁定和解锁他们的 PC 来解决问题。

Is the VB application running on a different machine than the client that can connect? If so, is it possible to test using a different client program on the same machine -- or is it possible to try the VB application on your machine?

VB 应用程序是否在与可以连接的客户端不同的机器上运行?如果是这样,是否可以在同一台机器上使用不同的客户端程序进行测试——或者是否可以在您的机器上尝试 VB 应用程序?

回答by Mark Kram

I know this is a very old post but I have found a solution that has worked for me (Legacy VB6 Application):

我知道这是一篇很老的帖子,但我找到了一个对我有用的解决方案(旧版 VB6 应用程序):

Change the following entry in the sqlnet.ora file:

更改 sqlnet.ora 文件中的以下条目:

Original Entry - SQLNET.AUTHENTICATION_SERVICES= (NTS)

Modified Entry - SQLNET.AUTHENTICATION_SERVICES= (NONE)

Here is a LINKto the solution

这是解决方案的链接

回答by Manulak

Know it's an old question but it has started appearing with the recent Windows update. The way to easily solve it is to set

知道这是一个老问题,但它已经开始出现在最近的 Windows 更新中。轻松解决的方法是设置

SQLNET.AUTHENTICATION_SERVICES= (NONE)

in the sqlnet.ora.

在 sqlnet.ora 中。

回答by alvalongo

I installed Oracle Database 11g Express Edition 32-bit on Windows 10 professional 64-bit (spanish edition).

我在 Windows 10 专业版 64 位(西班牙语版)上安装了 Oracle 数据库 11g 快捷版 32 位。

After restart PC all works ok.
But the next day I get error using SQL*PLus and SQLTools 1.9 build 15:

重启电脑后一切正常。
但是第二天我在使用 SQL*PLus 和 SQLTools 1.9 build 15 时遇到错误:

 ORA-12638: Credential retrieval failed

I modified the sqlnet.ora file so:

我修改了 sqlnet.ora 文件,因此:

SQLNET.AUTHENTICATION_SERVICES= (NONE)

and now I can connect using SQLPlus, SQLTools 1.9 build 15.

现在我可以使用 SQLPlus、SQLTools 1.9 build 15 进行连接。

回答by user209612

If you are running a web app under IIS, restarting IIS seem to help. But this is one sucker of an issue that has not much reasoning behind.

如果您在 IIS 下运行 Web 应用程序,重新启动 IIS 似乎有帮助。但这是一个没有太多理由的问题的傻瓜。