OleDbException | file.mdb'不是有效的路径

如何解决OleDbException | file.mdb'不是有效的路径

我将网站的位置更改为E盘。 我们正在将 Plesk Asp.net comp。

一起使用。

我已将IIS -> Basic settings中的位置更改为正确的位置。 我的连接字符串是:

LocalSQLSerer = data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true

我从asp.net收到此错误

[OleDbException (0x80004005): 'C:\Inetpub\vhosts\domain.com\httpdocs\dir\App_Data\WebExpl.mdb' is not 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.]
   System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr,OleDbConnection connection) +971317
   System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options,Object poolGroupProviderInfo,DbConnectionPool pool,DbConnection owningObject) +86
   System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection,DbConnectionPoolGroup poolGroup) +29
   System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +4911356
   System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory) +117
   System.Data.OleDb.OleDbConnection.Open() +40
   Aster.Data.Access.DataSetAccess.OpenConnection(IDbConnection conn) +72
   Aster.Data.Access.DataSetAccess.FillData(DataTable dt,String order) +266
   Aster.Data.Access.DataSetAccess.FillData(DataSet ds,DataTable dt,String order) +63
   Aster.Data.Rules.DataSetRules.FillDataDirect(DbSettings dbSettings,DataSet ds,String order) +86
   AppCache.InitCache() +166
   AppCache.get_MultiLanguages() +8
   BasePage.InitializeCulture() +190
   ASP.default_aspx.__BuildControlTree(default_aspx __ctrl) +93
   ASP.default_aspx.FrameworkInitialize() +22
   System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint,Boolean includeStagesAfterAsyncPoint) +56
   System.Web.UI.Page.ProcessRequest() +80
   System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +21
   System.Web.UI.Page.ProcessRequest(HttpContext context) +49
   ASP.default_aspx.ProcessRequest(HttpContext context) +4
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +181
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step,Boolean& completedSynchronously) +75

Web.config

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <configSections>
    <sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup,System.Web.Extensions,Version=1.0.61025.0,Culture=neutral,PublicKeyToken=31bf3856ad364e35">
      <sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup,PublicKeyToken=31bf3856ad364e35">
        <section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection,PublicKeyToken=31bf3856ad364e35" requirePermission="false" allowDefinition="MachineToApplication" />
        <sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup,PublicKeyToken=31bf3856ad364e35">
          <section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection,PublicKeyToken=31bf3856ad364e35" requirePermission="false" allowDefinition="Everywhere" />
          <section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection,PublicKeyToken=31bf3856ad364e35" requirePermission="false" allowDefinition="MachineToApplication" />
          <section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection,PublicKeyToken=31bf3856ad364e35" requirePermission="false" allowDefinition="MachineToApplication" />
        </sectionGroup>
      </sectionGroup>
    </sectionGroup>
    <section name="RewriterConfig" type="URLRewriter.Config.RewriterConfigSerializerSectionHandler,URLRewriter" />
  </configSections>
  <appSettings>
    <add key="errordetails" value="0" />
  </appSettings>
  <RewriterConfig>
    <!--  Url Rewrite rules: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/urlrewriting.asp -->
    <Rules>
      <RewriterRule>
        <LookFor>(.*taxon)-(.*)\.aspx\??(.*)</LookFor>
        <SendTo>$1.aspx?t=$2$3</SendTo>
      </RewriterRule>
      <RewriterRule>
        <LookFor>(.*taxalist)-(.*)\.aspx\??(.*)</LookFor>
        <SendTo>$1.aspx?l=$2$3</SendTo>
      </RewriterRule>
    </Rules>
  </RewriterConfig>
  <system.codedom>
    <compilers>
      <compiler language="c#;cs;csharp" extension=".cs" compilerOptions="/d:TRACE" warningLevel="1" type="Microsoft.CSharp.CSharpCodeProvider,System,Version=2.0.0.0,PublicKeyToken=b77a5c561934e089">
        <providerOption name="CompilerVersion" value="v3.5" />
        <providerOption name="WarnAsError" value="false" />
      </compiler>
    </compilers>
  </system.codedom>
  <system.web>
    <machineKey validationKey="4E7389973C005359F87CF6F715FB0360C330E2FC37EA40E313121537A78FCCC9FEF91DA2147DDD5D5D944D6A7A144D88616FF6775A1346A3B3D9832958332851" decryptionKey="A69F535808919FAE767057615E73283AC9B3CABE975C7E8BF3EF11CAB445F283" validation="SHA1" decryption="AES" />
    <browserCaps userAgentCacheKeyLength="256" />
    <pages theme="default" enableEventValidation="true" validateRequest="true" enableViewStateMac="true">
      <controls>
        <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions,PublicKeyToken=31bf3856ad364e35" />
      </controls>
    </pages>
    <!-- 50MB in Kbytes. Should be equal maxAllowedContentLength -->
    <httpRuntime maxRequestLength="51200" enableVersionHeader="false" />
    <customErrors mode="Off" defaultRedirect="errmsg.aspx" />
    <httpHandlers>
      <!-- IIS 6 -->
      <remove verb="*" path="*.asmx" />
      <add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory,PublicKeyToken=31bf3856ad364e35" />
      <add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory,PublicKeyToken=31bf3856ad364e35" />
      <add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler,PublicKeyToken=31bf3856ad364e35" validate="false" />
      <add verb="*" path="MapHandler.ashx" type="MapHandler,App_Code" />
      <add verb="*" path="*js.axd" type="ScriptCompressorHandler" />
    </httpHandlers>
    <httpModules>
      <!-- IIS 6 -->
      <remove name="WindowsAuthentication" />
      <remove name="PassportAuthentication" />
      <remove name="AnonymousIdentification" />
      <remove name="UrlAuthorization" />
      <remove name="FileAuthorization" />
      <add type="URLRewriter.ModuleRewriter,URLRewriter" name="ModuleRewriter" />
    </httpModules>
    <httpCookies httpOnlyCookies="true" requireSSL="true" />
    <sessionState mode="InProc" cookieless="false" timeout="10" />
    <!--<sessionState mode="StateServer" stateConnectionString="tcpip=localhost:42424" cookieless="false" timeout="10" />-->
  </system.web>
  <system.net>
    <connectionManagement>
      <add address="*" maxconnection="40" />
    </connectionManagement>
  </system.net>
  <system.web.extensions>
    <scripting>
      <webServices>
        <jsonSerialization maxJsonLength="2097152" />
      </webServices>
      <scriptResourceHandler enableCompression="true" enableCaching="true" />
    </scripting>
  </system.web.extensions>
  <!-- IIS 7 -->
  <system.webServer>
    <urlCompression doDynamicCompression="true" doStaticCompression="true" dynamicCompressionBeforeCache="true" />
    <validation validateIntegratedModeConfiguration="false" />
    <modules runAllManagedModulesForAllRequests="true">
      <remove name="WindowsAuthentication" />
      <remove name="PassportAuthentication" />
      <remove name="AnonymousIdentification" />
      <remove name="UrlAuthorization" />
      <remove name="FileAuthorization" />
      <remove name="UrlAddwww" />
      <remove name="ModuleRewriter" />
      <add name="ScriptModule" preCondition="integratedMode" type="System.Web.Handlers.ScriptModule,PublicKeyToken=31bf3856ad364e35" />
      <add type="URLRewriter.ModuleRewriter,URLRewriter" name="ModuleRewriter" />
    </modules>
    <handlers accessPolicy="Read,Write,Script,Execute">
      <remove name="WebServiceHandlerFactory-Integrated" />
      <add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory,PublicKeyToken=31bf3856ad364e35" />
      <add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory,PublicKeyToken=31bf3856ad364e35" />
      <add name="ScriptResource" preCondition="integratedMode" verb="GET,PublicKeyToken=31bf3856ad364e35" />
      <add name="MapHandler" verb="*" path="MapHandler.ashx" type="MapHandler,App_Code" />
      <add name="StrawberryPerl" path="*.pl" verb="GET,HEAD,POST" modules="CgiModule" scriptProcessor="C:\Strawberry\perl\bin\perl.exe &quot;%s&quot; %s" resourceType="Either" />
    </handlers>
    <staticContent>
      <clientCache cacheControlCustom="public" cacheControlMode="UseMaxAge" cacheControlMaxAge="30.00:00:00" />
    </staticContent>
    <rewrite>
      <rules>
        <rule name="HTTP/S to HTTPS Redirect" enabled="true" stopProcessing="true">
          <match url="(.*)" />
          <conditions logicalGrouping="MatchAll">
            <add input="{HTTPS}" pattern="off" ignoreCase="true" />
            <add input="{REQUEST_URI}" negate="true" pattern="\.asmx$" ignoreCase="true" />
          </conditions>
          <action type="Redirect" url="https://{HTTP_HOST}/{R:1}" appendQueryString="true" redirectType="Permanent" />
        </rule>
        <rule name="Rewrite https imagelib request to http" enabled="true" stopProcessing="true">
          <match url="(.*)" />
          <conditions logicalGrouping="MatchAll">
            <add input="{URL}" pattern="^/unimusbilder/(.*)$" ignoreCase="true" />
          </conditions>
          <action type="Rewrite" url="http://www.unimus.no/felles/bilder/{C:1}" appendQueryString="true" />
        </rule>
      </rules>
      <outboundRules>
        <rule name="Add Strict-Transport-Security when HTTPS" enabled="true">
          <match serverVariable="RESPONSE_Strict_Transport_Security" pattern=".*" />
          <conditions>
            <add input="{HTTPS}" pattern="on" ignoreCase="true" />
          </conditions>
          <action type="Rewrite" value="max-age=31536000" />
        </rule>
      </outboundRules>
    </rewrite>
    <httpProtocol>
      <customHeaders>
        <remove name="X-Powered-By" />
        <remove name="X-Powered-By-Plesk" />
        <add name="X-UA-Compatible" value="IE=Edge" />
        <add name="X-XSS-Protection" value="1;mode=block" />
        <add name="X-Frame-Options" value="SAMEORIGIN" />
        <add name="X-Content-Type-Options" value="nosniff" />
        <add name="Content-Security-Policy" value="default-src 'none'; connect-src 'self'; img-src *; script-src 'unsafe-inline' 'unsafe-eval' *; style-src 'self' 'unsafe-inline'; font-src *; base-uri 'self'; form-action 'self'; frame-ancestors 'self'; " />
      </customHeaders>
    </httpProtocol>
    <security>
      <requestFiltering>
        <!-- 50MB in bytes,default is 30000000 (28.6102 Mb). Should be equal maxRequestLength -->
        <requestLimits maxAllowedContentLength="52428800" />
      </requestFiltering>
    </security>
  </system.webServer>
  <connectionStrings>
    <remove name="LocalMySqlServer" />
  </connectionStrings>
</configuration>

任何人都知道这里可能有什么问题吗? 我主要使用WP页面和Linux,这对我来说很希腊。 这些都是政府站点,因此反馈很容易得到

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐


依赖报错 idea导入项目后依赖报错,解决方案:https://blog.csdn.net/weixin_42420249/article/details/81191861 依赖版本报错:更换其他版本 无法下载依赖可参考:https://blog.csdn.net/weixin_42628809/a
错误1:代码生成器依赖和mybatis依赖冲突 启动项目时报错如下 2021-12-03 13:33:33.927 ERROR 7228 [ main] o.s.b.d.LoggingFailureAnalysisReporter : *************************** APPL
错误1:gradle项目控制台输出为乱码 # 解决方案:https://blog.csdn.net/weixin_43501566/article/details/112482302 # 在gradle-wrapper.properties 添加以下内容 org.gradle.jvmargs=-Df
错误还原:在查询的过程中,传入的workType为0时,该条件不起作用 &lt;select id=&quot;xxx&quot;&gt; SELECT di.id, di.name, di.work_type, di.updated... &lt;where&gt; &lt;if test=&qu
报错如下,gcc版本太低 ^ server.c:5346:31: 错误:‘struct redisServer’没有名为‘server_cpulist’的成员 redisSetCpuAffinity(server.server_cpulist); ^ server.c: 在函数‘hasActiveC
解决方案1 1、改项目中.idea/workspace.xml配置文件,增加dynamic.classpath参数 2、搜索PropertiesComponent,添加如下 &lt;property name=&quot;dynamic.classpath&quot; value=&quot;tru
删除根组件app.vue中的默认代码后报错:Module Error (from ./node_modules/eslint-loader/index.js): 解决方案:关闭ESlint代码检测,在项目根目录创建vue.config.js,在文件中添加 module.exports = { lin
查看spark默认的python版本 [root@master day27]# pyspark /home/software/spark-2.3.4-bin-hadoop2.7/conf/spark-env.sh: line 2: /usr/local/hadoop/bin/hadoop: No s
使用本地python环境可以成功执行 import pandas as pd import matplotlib.pyplot as plt # 设置字体 plt.rcParams[&#39;font.sans-serif&#39;] = [&#39;SimHei&#39;] # 能正确显示负号 p
错误1:Request method ‘DELETE‘ not supported 错误还原:controller层有一个接口,访问该接口时报错:Request method ‘DELETE‘ not supported 错误原因:没有接收到前端传入的参数,修改为如下 参考 错误2:cannot r
错误1:启动docker镜像时报错:Error response from daemon: driver failed programming external connectivity on endpoint quirky_allen 解决方法:重启docker -&gt; systemctl r
错误1:private field ‘xxx‘ is never assigned 按Altʾnter快捷键,选择第2项 参考:https://blog.csdn.net/shi_hong_fei_hei/article/details/88814070 错误2:启动时报错,不能找到主启动类 #
报错如下,通过源不能下载,最后警告pip需升级版本 Requirement already satisfied: pip in c:\users\ychen\appdata\local\programs\python\python310\lib\site-packages (22.0.4) Coll
错误1:maven打包报错 错误还原:使用maven打包项目时报错如下 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources (default-resources)
错误1:服务调用时报错 服务消费者模块assess通过openFeign调用服务提供者模块hires 如下为服务提供者模块hires的控制层接口 @RestController @RequestMapping(&quot;/hires&quot;) public class FeignControl
错误1:运行项目后报如下错误 解决方案 报错2:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project sb 解决方案:在pom.
参考 错误原因 过滤器或拦截器在生效时,redisTemplate还没有注入 解决方案:在注入容器时就生效 @Component //项目运行时就注入Spring容器 public class RedisBean { @Resource private RedisTemplate&lt;String
使用vite构建项目报错 C:\Users\ychen\work&gt;npm init @vitejs/app @vitejs/create-app is deprecated, use npm init vite instead C:\Users\ychen\AppData\Local\npm-