4

私が直面しているシナリオは、永続化された状態変数を格納するためにCacheManager /IsolatedStorageストアを使用しているW2k3サーバーでASP.NETWebサービス(.NET 3.5)を実行していることです。この構成は、物理マシンを変更するまで、かなり長い間正常に機能していました。これで、その値にアクセスするコードが実行されるたびに、IsolatedStorageExceptionがスローされます(以下に投稿)。私が理解しているように、ユーザー/アセンブリストアはアクセスされているものであり、実行中のユーザーはローカル管理者グループのメンバーです。どの特権が欠けているかについて誰かが提案を持っていますか?

エラー

ストアディレクトリを作成できません。(HRESULTからの例外:0x80131468)

スタックトレース

タイプ:Microsoft.Practices.ObjectBuilder2.BuildFailedException。エラー:現在のビルド操作(ビルドキービルドキー[Microsoft.Practices.EnterpriseLibrary.Caching.ICacheManager、キャッシュマネージャー])が失敗しました:ストアディレクトリを作成できません。(HRESULTからの例外:0x80131468)(ストラテジータイプConfiguredObjectStrategy、インデックス2)。トレース:Microsoft.Practices.ObjectBuilder2.ExecuteBuildUp(IBuilderContext context)、Microsoft.Practices.ObjectBuilder2.Builder.BuildUp(IReadWriteLocatorロケーター、ILifetimeContainerライフタイム、IPolicyListポリシー、IStrategyChain戦略、オブジェクトbuildKey、オブジェクト既存)。 MicrosoftのObjectBuilder2.Builder.BuildUp[TTypeToBuild](IReadWriteLocatorロケーター、ILifetimeContainerライフタイム、IPolicyListポリシー、IStrategyChain戦略、オブジェクトbuildKey、既存のオブジェクト)。1.CreateDefault() at Microsoft.Practices.EnterpriseLibrary.Caching.CacheFactory.GetCacheManager() at Ept.Commands.SettlementCommand.BeginSettlement() in c:\Projects\EPT\Ept.Framework.Services\Commands\SettlementCommand.cs:line 102 at Ept.Commands.SettlementCommand.ExecuteKernel(SettlementRequest request) in c:\Projects\EPT\Ept.Framework.Services\Commands\SettlementCommand.cs:line 188 at Ept.Command2. c:\ Projects \ EPT \ Ept.Framework.Services \ Commands \ Command.cs:line 79のExecute(TRequest request)。ExecutingStrategyTypeName:ConfiguredObjectStrategy ExecutingStrategyIndex:2 BuildKey:Build Key [Microsoft.Practices.EnterpriseLibrary.Caching.ICacheManager 、キャッシュマネージャー]タイプ:System.IO.IsolatedStorage.IsolatedStorageException。エラー:ストアディレクトリを作成できません。(HRESULTからの例外:0x80131468)。トレース:System.IO.IsolatedStorage.IsolatedStorageFile.GetRootDir(IsolatedStorageScopeスコープ)at System.IO.IsolatedStorage.InitGlobalsNonRoamingUser(IsolatedStorageScopeスコープ)at System.IO.IsolatedStorage.IsolatedStorageFile.GetRootDir(IsolatedStorageScopeスコープ)at System.IO.I System.IO.IsolatedStorageの.IsolatedStorageFile.GetGlobalFileIOPerm(IsolatedStorageScopeスコープ)。2.Create(IBuilderContext context, TConfiguration objectConfiguration, IConfigurationSource configurationSource, ConfigurationReflectionCache reflectionCache) at Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.AssemblerBasedCustomFactory2.Microsoft.Practices.EnterpriseLibrary.EnterpriseLibraryでMicrosoft.Practices.EnterpriseLibrary.Caching.Configuration.CacheManagerAssembler.Assemble(IBuilderContext context、CacheManagerDataBase objectConfiguration、IConfigurationSource configurationSource、ConfigurationReflectionCache ReflectionCache)でCreate(IBuilderContext context、String name、IConfigurationSource configurationSource、ConfigurationReflectionCachereflectionCache)。 Common.Configuration.ObjectBuilder.AssemblerBasedObjectFactory2.Create(IBuilderContext context, TConfiguration objectConfiguration, IConfigurationSource configurationSource, ConfigurationReflectionCache reflectionCache) at Microsoft.Practices.EnterpriseLibrary.Caching.CacheManagerCustomFactory.Create(IBuilderContext context, CacheManagerDataBase objectConfiguration, IConfigurationSource configurationSource, ConfigurationReflectionCache reflectionCache) at Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.AssemblerBasedCustomFactory2.MicrosoftのMicrosoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.AssemblerBasedCustomFactory`2.CreateObject(IBuilderContextコンテキスト、文字列名、IConfigurationSource configurationSource、ConfigurationReflectionCache ReflectionCache)でCreate(IBuilderContextコンテキスト、文字列名、IConfigurationSource configurationSource、ConfigurationReflectionCache ReflectionCache)。 Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContextコンテキスト)のPractices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.ConfiguredObjectStrategy.PreBuildUp(IBuilderContextコンテキスト)。

4

4 に答える 4

7

この問題の根本的な原因は、Webサービスが実行されているアカウントにローカルユーザープロファイルが作成されていないため、ユーザーアセンブリストアが存在しなかったことです。簡単な修正は、サービスアカウントでボックスにログオンすることでした。

于 2010-07-14T15:12:41.080 に答える
2

Windows 2012R2およびIIS8.5を使用している場合、アプリが独自のIDで特定のアプリケーションプールで実行されている場合は、 [プールの詳細パラメーター]の[ユーザープロファイルの読み込み]オプションが[ True ]に設定されていることを確認する必要があります。そうすることで、WindowsはC:\ Usersの下にアプリプールID名を持つフォルダーを作成し、アプリがローカルストレージ内に書き込むことができるようにします。

于 2016-02-28T21:38:04.860 に答える
1

この問題が発生しましたが、ある時点でプロファイル名が変更されたため、「C:\ Documents andSettings \ DefaultUser \ LocalSettings \ ApplicationData\IsolatedStorage」を作成しても問題は解決しませんでした。このサーバーの実際の場所は、「C:\ Documents andSettings \ DefaultUser.WINDOWS \ LocalSettings \ ApplicationData\IsolatedStorage」でした。

それでも問題が解決しない場合は、「IsolatedStorage」のフィルターを使用してProcess Monitorを使用し、アクセス拒否エラーの正しいパスを見つけました。

于 2012-06-05T02:05:08.417 に答える
0

Windows 10では、IISアプリケーションプールの設定「ユーザープロファイルの読み込み」はデフォルトでTrueです。しかし、Windows2012ではFalseですTrueに切り替えると、問題が解決しました。

于 2017-10-04T14:28:46.890 に答える