asp问题:Unable to open Registry key 

Temporary volatile Jet DSN for process - Unable to open Registry key [原创 2008-12-20 10:34:27]   
我顶 字号:
Error codes in ASP can drive you crazy sometimes. How do you fix it if you see the error Temporary volatile Jet DSN for process - Unable to open Registry key ?

First, this in general means there is a permission problem getting to the database. Usually this happens when you do a security patch on your server, reboot your server, or install firewall software. All of these things can cause your web user to lose permission to access the critical files.

So first, check the basics. Make sure that IUSR has write permission to both the directory holding the database file and to any temp directories being used. Make sure that the DSN connection string is actually pointed at the diretory you are working on!

Even if you thought these were set properly, a reboot or a security upgrade might have unset them. Check again.

Next, look into any other security blocks that may have been added. Have you added any antivirus or firewall software recently? Try turning it off and see if that helps. If it does, turn the software back on and then go into its configuration, and allow access to the directories in question.
-----------------------
1.错误信息(错误信息我不用翻译成中文了把,呵呵,大家谅解)
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Microsoft Access 97 Driver] The Microsoft Jet database
engine cannot open the file '(unknown)'. It is already opened exclusively
by another user, or you need permission to view its data.
原因:
这个错误发生在当IIS使用匿名帐号(通常是IUSR)时,该帐号在NT中对数据库所在的目录
没有正确的权限.(这就是为什么在Win95和PWS下没问题,因为win95根本就没有目录权限这一说)
检查文件和目录的权限. 确定你能够在该目录中有能够新建和删除临时文件的权限。
这些临时文件其实是数据库建立在同一个目录下的文件, 但是要注意的是,有可能这些文件
也可能建立在别的目录,例如 /Winnt.
使用NT的文件监视程序监视文件失败时到底是访问了什么目录。
这个NT的文件监视程序可以在这个地方下载http://www.sysinternals.com.
如果你对数据库使用了一个网络地址,例如映射地址,就要检查一下共享文件和目录的权限,
还要检查一下数据源文件(DSN)是否被别的程序标志成为正在使用中,
这些别的程序一般是Visual InterDev,关闭任何一个InterDev中的正打开和数据库连接的项目。
这个错误还可能发生在这种情况:如果在DSN中使用了一个UNC路径(就是通用命名协议),请改用
本地路径进行测试,因为如果对本地数据库使用UNC也可能出错。
还可能发生在这种情况,如果服务器要访问Access中的一个表,而这个表却联接在一个网络服务器上。
2.错误信息:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Microsoft Access 97 Driver] Couldn't use '(unknown)'; file
already in use.
原因:
多人使用时数据库被锁定。
3.错误信息:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no default
driver specified.
原因:
最可能的原因是ConnectString是一个在global.asa中初始化的Session变量,但是global.asa
却没有正常工作。解决办法是,检查赋值时是否正确:(在你的asp中加入下面的代码)
<%= "'auth_user' is " & request.servervariables("auth_user")%>
<P>
<%= "'auth_type' is " & request.servervariables("auth_type")%>
<P>
<%= "connection string is " & session("your_connectionstring")%>
<P>
还有一个原因就是你在你的ConnectString中加入了多余的空格,例如
DSN = MyDSN; Database = Pubs;
试试改成下面这个样子:
DSN=MyDSN;Database=Pubs;
如果是global.asa还没有工作,检查该文件是否在运用程序的根目录中,或者是虚拟目录的根目录中。
还有可能错误出现的原因是DSN名称没找着,这可以采用我提供的id=36767的办法解决。
最后是检查是否安装了最新的驱动程序,既是否是最新的MDAC版本。
4.错误信息
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not ??
原因:
这个错误有可能是出现在你的计算机上软件安装(或则反安装)的顺序上。
如果ODBC的版本不一致的话,就会发生该错误。
解决办法是安装最新版本的MDAC
5.错误信息:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Access 97 ODBC driver Driver]General error Unable to open
registry key 'DriverId'.
原因:
这个错误发生在爱从注册表中读取数值的时候。 使用regedit32.exe检查你的注册表的权限。
你也可以使用NT中的注册表监视程序(NTRegMon)来看读取失败信息。该程序到这找:http://www.sysinternals.com
6.错误信息:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][dbnmpntw]ConnectionOpen (CreateFile()).
原因:
两个原因:当一个数据库中包含有分别在不用机器上的许可关系时,
这也可能发生在同一台机器上,当你给一个关系设置了UNC路径,而另一个关系却是本地路径。
错误原因是:
当用户使用IIS匿名帐号登录后,对本地这台机器而言他是有权的,但是对于一个UNC路径的机器,
另外这台机器是不会认为你当前匿名登录的帐号在它那上面也是合法的。
这样它就不允许你访问它上面的资源,导致错误。
两个解决办法:
1。在IIS工具中,改变IIS匿名帐号成另外一个基于域的帐号。(也就是不使用匿名登录)
2。或则在那台你要访问资源的机器上也创建一个和当前匿名帐号同样的帐号,使用同样的密码。
7.错误信息
Microsoft OLE DB Provider for ODBC Drivers error '80004005' Microsoft][ODBC
Microsoft SQL Driver] Logon Failed()
原因:
该错误是由SQL Server产生的,当它不接受或则不能够认识这个登录帐号的时候,或者没有使用管理员身份登录,
也可能是在NT中没有SQL影射帐号造成的。
使用系统管理员帐号(SA)登录,一般密码应该为空.注意,这时必须使用CoonectString而不能够使用DSN文件。
因为DSN中没有保存用户名和密码。
检查NT是否给SQL映射了帐号。
8.错误信息
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][SQL Server] Login failed- User: Reason:
Not defined as a valid user of a trusted SQL Server connection.
原因:
原因同上。
试试这个办法:在SQL Server的Enterprise Manager中,选择Server/SQL Server/Configure[ASCII
133]/Security Options/Standard.
如果是运行在IIS4中,取消选择该项目的Password Synchronization选项。
9.错误信息
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Microsoft Access 97 Driver] Couldn't lock file.
原因:
也许是没有正确的权限生成Access数据库的锁定文件(.ldb)
默认时,该文件和你的数据库是同一个目录的。
给匿名帐号全权访问数据库共享目录的权限。
有时是因为文件是因为共享时有意使用了只读的权限限制。试试使用下面的代码。
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Mode = adModeShareDenyWrite '8
10.错误信息
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Microsoft Access 97 Driver] '(unknown)' isn't a valid
path. Make sure that the path name is spelled correctly and that you are
connected to the server on which the file resides.
原因:
路径非法。最可能发生在当Global.asa和CoonecntString被使用到另外一台机器上的时候。
11.错误信息
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][SQL Server] The query and the views in
it exceed the limit of 16 tables.
原因:
查询太复杂了,对查询有限制。
12.错误信息:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][DBMSSOCN] General network error. Check
your network document
原因:
当装有SQL Server的机器改名的时候。但是DSN还使用了原来的机器名。
来源:http://zhidao.baidu.com/question/38136589.html



文章来自: 互联网
引用通告地址: http://www.niaochao2008.com/trackback.asp?tbID=827
Tags:
评论: 0 | 引用: 0 | 查看次数: 3285
 
扫码领红包!领到大红包的小伙伴赶紧使用哦!