Ways to resolve 0x80004005 problems in an Access database

Source: Internet
Author: User
Tags define error code iis ole variables variable web services access
This forum article highlights the solution to the 0x80004005 problem in the Access database, please refer to the following:

This forum article highlights the solution to the 0x80004005 problem in the Access database, please refer to the following:

The project has been done for three months, and finally almost finished, handed over to the test yesterday, the results of the following problems appeared:

[OleDbException (0x80004005): Unspecified ERROR]

System.Data.OleDb.OleDbConnection.ProcessResults (Int32 hr) +20

System.Data.OleDb.OleDbConnection.InitializeProvider () +57

System.Data.OleDb.OleDbConnection.Open () +203

Webb.WAVE.Controls.OleDBManager.FillDataTable (DataTable i_datatable) +85

Webb.WAVE.Controls.WaveExpire.LoadExpireDateForClient (DataTable i_table, Int64 i_clientid) +189

Webb.WAVE.inc_Client_AccessManage.LoadExpireDate (String i_sortkey) +99

Webb.WAVE.inc_Client_AccessManage.Page_Load (Object sender, EventArgs e) +85

System.Web.UI.Control.OnLoad (EventArgs e) +67

System.Web.UI.Control.LoadRecursive () +35

System.Web.UI.Control.LoadRecursive () +98

System.Web.UI.Control.LoadRecursive () +98

System.Web.UI.Page.ProcessRequestMain () +750

Explain: This error always occurs after a period of time, and wait for a work (indefinite time), or restart IIS or the server, the problem is resolved. And then run for a while and it will be (less time) this problem arises.

And I am in my own computer is running, basically did not appear such a problem, so repeatedly look for the reason, not its solution, in MSDN found three related articles: one of the article also has some truth:

Symptoms

When trying to connect to a Access. mdb file, an ODBC error is returned stating "Disk or network Error". The Microsoft OLE DB Provider for the Microsoft Jet database engine could also return of "Unspecified Error" (Error code = 0 X80004005) message.

The problem can occur only if the data source is opened under the Microsoft Internet information Server (IIS) or a Micro Soft Windows NT Service but not under a logged-on user account. Cause

Jet creates a temporary file when the engine is started. In doing so, it checks the TMP environment variable and uses this path to define where the temporary file is created . If it doesn ' t a TMP environment variable, it looks for the TEMP environment variable. If TEMP is not defined, it then uses Windows folder (\ Windows or \WINNT).

If tmp/temp is defined but points to a nonexistent folder, the error occurs.

Moreover when opening the Access database through IIS or a Windows NT service, and if IIS or the service is running und Er the Local System account, the TMP or TEMP system environment variable is used. When the Web services or Windows NT service are started using a user account, the Tmp/temp user profile environment Variab Les is used. Resolution

Define a TMP or TEMP environment variable and assign the variable to a existing folder. If you are are accessing the Access database from IIS, being certain to check the system environment settings rather than environ ment variables of the logged-on user. Also ensure the Iuser anonymous IIS account has access to the temporary folder.

You are must restart the computer after changing any environment variables.

Environment variables are set under Windows NT 4.0 by going to the control Panel and clicking System and then th E Environment tab.

What I don't understand, though, is why there was no problem with the tests in the last few weeks, and more and more frequently in recent days.

On the internet to find a few related articles (there are many forum posts have discussed this issue, but I have not been able to find a solution to the answer):

After thinking about it for a few minutes, I wonder if it's the reason why I can't create a temporary document? In fact, as long as I can make mistakes on my own computer appear, then I can do it, but the problem is, only occasionally appeared on my computer, and soon good, and from beginning to end only appeared two or three times. But on the server there are more and more problems, a few minutes will not. Based on some of the previous articles, I decided to do one of the following tests:

1. Delete File Write permissions for IIS accounts under Windows (Internet Guest account) Of course, only the directory for the project.

2, also delete it in the temporary directory (C:\Documents and settings\webb-country-wu\aspnet\local Settings\Temp, not all the different machines) write permission.

Well, I finally got the same error on my computer, and all the database-related pages were inaccessible. And according to the MSDN instructions, this is because there is no permission to write files in the temp directory, and it is the same. However, the problem is that the server is not always wrong, but a momentary error is normal.

The only thing that can be explained is that the server temp file is full!!!! And this is not easy to prove, I can not always test, so that my temporary files are full (even if the copy file to the temporary directory, it is not an IIS account, but the operator's), and the temporary file itself (OLE DB chain wiring) will also be deleted. Have to find another way, is to use disk quotas. To the IIS account: Internet Guest accounts has only 10K write permission in C disk, and then test, the problem is due to the timely ...

To this, you can be sure: there are too many temporary files on the server, it seems to be to restart the server, or to clean up temporary files or to adjust disk space ...

Hopefully this article will help those who haven't solved the problem yet. At the same time, MS Web sites and several articles on MSDN are also helpful, especially for a few other reasons for the error.



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.