< class="prominent-subhead ">

File access causes 'A database error occurred'

~~repeating-content.html~~
LEGACY/ARCHIVED CONTENT
This article has been archived, and/or refers to legacy products, components or features. The content in this article is offered "as is" and will no longer be updated. Archived content is provided for reference purposes only. This content does not infer that the product, component or feature is supported, or that the product, component or feature will continue to function as described herein.

“A database error occurred” exception/message can be caused by insufficient file system access rights for the user context that the K2.net 2003 Server runs as.

     Symptoms:
    • The K2.net® 2003 Server service fails to start when tracing is enabled in the K2Server.config file
    • When attempting to run K2.net 2003 Server in console mode (with tracing disabled), the server starts successfully. However when trying to plan a new process, the following error message "A database error occurred" is displayed
    • In the client application "A database error occurred" System.Exception is thrown when trying to plan a K2.net® process
    • K2Error.txt file is not created
     
    Solution:
    Provide the K2.net® 2003 Service user write access to the folders where K2.net 2003 was installed. The default installation directory is: "C:\Program Files\K2.net 2003\Bin"
     
    Additional Information:
    A possible exception stack trace:
     
    System.Exception: A database error occured
     at Client.Throw(String s, Exception e)
     at Client.InternalCall(UInt32 sock, ArchiveX ar, Int32 hdr)
     at SourceCode.K2ROM.Connection.CreateProcessInstance(String ProcName, Int32 Version)
     at SourceCode.K2ROM.Connection.CreateProcessInstance(String ProcName)
     
    Shown below is the error while K2.net 2003 Server is running in console mode.
    Note: The K2.net® Service must not be running or else console mode will fail to start.

      

     
    The following browser error may also result:
    Note: You will need to turn off custom error handling in the web.config file, this is case sensitive.
     
    <customErrors defaultRedirect="Error_Page.htm" mode="Off"/>