带有 Docker 容器和 windowsservercore 和 iis 服务器的 Service Fabric 集群

Posted

技术标签:

【中文标题】带有 Docker 容器和 windowsservercore 和 iis 服务器的 Service Fabric 集群【英文标题】:Service Fabric Cluster with Docker Containers with windowsservercore and iis server 【发布时间】:2017-01-09 02:12:09 【问题描述】:

我正在尝试创建一个带有 3 个 docker 容器的服务结构集群,该容器运行一个 windowsservercore 映像和安装在顶部的 iis 服务器。

我已经在所有容器上启用了Remote Registry Service,并且暴露了 135-20063 的端口。

我在创建集群时遇到以下问题:

System.IO.IOException:找不到网络路径。

在 Microsoft.Win32.RegistryKey.Win32ErrorStatic(Int32 errorCode, String str) 在 Microsoft.Win32.RegistryKey.OpenRemoteBaseKey(RegistryHive hKey, String machineName, RegistryView view) 在 System.Fabric.FabricDeployer.ConfigurationDeployer.GetTempPathInner(字符串 machineName) 在 System.Fabric.FabricDeployer.ConfigurationDeployer.GetTempPath(字符串机器名) System.IO.IOException:找不到网络路径。

在 Microsoft.Win32.RegistryKey.Win32ErrorStatic(Int32 errorCode, String str) 在 Microsoft.Win32.RegistryKey.OpenRemoteBaseKey(RegistryHive hKey, String machineName, RegistryView view) 在 System.Fabric.FabricDeployer.ConfigurationDeployer.GetTempPathInner(字符串 machineName) 在 System.Fabric.FabricDeployer.ConfigurationDeployer.GetTempPath(字符串机器名) RPC 无法访问机器 172.24.186.140。检查网络连接。 HRESULT=53 ERROR_BAD_NETPATH RPC 无法访问机器 172.28.166.142。检查网络连接。 HRESULT=53 ERROR_BAD_NETPATH System.IO.IOException:找不到网络路径。

在 Microsoft.Win32.RegistryKey.Win32ErrorStatic(Int32 errorCode, String str) 在 Microsoft.Win32.RegistryKey.OpenRemoteBaseKey(RegistryHive hKey, String machineName, RegistryView view) 在 System.Fabric.FabricDeployer.ConfigurationDeployer.GetTempPathInner(字符串 machineName) 在 System.Fabric.FabricDeployer.ConfigurationDeployer.GetTempPath(字符串机器名) RPC 无法访问机器 172.25.205.155。检查网络连接。 HRESULT=53 ERROR_BAD_NETPATH 创建集群失败。有关更多信息,请查看 FabricLogRoot 中的跟踪。 创建集群失败并出现异常:System.AggregateException:发生一个或多个错误。 ---> System.AggregateExcep 化:发生了一个或多个错误。 ---> System.IO.IOException:RPC 无法访问机器 172.24.186.140。检查 k 网络连通性。 HRESULT=53 ERROR_BAD_NETPATH 在 System.Fabric.DeploymentManager.b__5f(串机) 在 System.Threading.Tasks.Parallel.c__DisplayClass17_01.<ForWorker>b__1() at System.Threading.Tasks.Task.InnerInvokeWithArg(Task childTask) at System.Threading.Tasks.Task.<>c__DisplayClass176_0.<ExecuteSelfReplicating>b__0(Object ) --- End of inner exception stack trace --- at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallel Options, Action1 body, Action2 bodyWithState, Func4 bodyWithLocal, Func1 localInit, Action1 localFinally) 在 System.Threading.Tasks.Parallel.ForEachWorker[TSource,TLocal](IEnumerable1 source, ParallelOptions parallelOption s, Action1 body, Action2 bodyWithState, Action3 bodyWithStateAndIndex, Func4 bodyWithStateAndLocal, Func5 bodyWithE 非常,Func1 localInit, Action1 localFinally) 在 System.Threading.Tasks.Parallel.ForEach[TSource](IEnumerable1 source, Action1 正文) 在 System.Fabric.DeploymentManager.CheckRPCAccess(IEnumerable1 machineNames) at System.Fabric.DeploymentManager.<CreateClusterAsyncInternal>d__a.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Fabric.DeploymentManager.<CreateClusterAsync>d__0.MoveNext() --- End of inner exception stack trace --- at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) at Microsoft.ServiceFabric.Powershell.ClusterCmdletBase.NewCluster(String clusterConfigurationFilePath, String fabric PackageSourcePath, Boolean rollbackOnFailure) ---> (Inner Exception #0) System.AggregateException: One or more errors occurred. ---> System.IO.IOException: Machine 17 2.24.186.140 could not be reached for RPC. Check network connectivity. HRESULT=53 ERROR_BAD_NETPATH at System.Fabric.DeploymentManager.<CheckRPCAccess>b__5f(String machine) at System.Threading.Tasks.Parallel.<>c__DisplayClass17_01.b__1() 在 System.Threading.Tasks.Task.InnerInvokeWithArg(任务子任务) 在 System.Threading.Tasks.Task.c__DisplayClass176_0.b__0(Object ) --- 内部异常堆栈跟踪结束 --- 在 System.Threading.Tasks.Task.ThrowIfExceptional(布尔 includeTaskCanceledExceptions) 在 System.Threading.Tasks.Task.Wait(Int32 毫秒超时,CancellationToken 取消令牌) 在 System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive,Int32 toExclusive,ParallelOptions 并行 选项,Action1 body, Action2 bodyWithState,Func4 bodyWithLocal, Func1 localInit,Action1 localFinally) at System.Threading.Tasks.Parallel.ForEachWorker[TSource,TLocal](IEnumerable1 source,ParallelOptions 并行选项 s, Action1 body, Action2 bodyWithState, Action3 bodyWithStateAndIndex, Func4 bodyWithStateAndLocal, Func5 bodyWithE verything, Func1 localInit, Action1 localFinally) at System.Threading.Tasks.Parallel.ForEach[TSource](IEnumerable1 source, Action1 body) at System.Fabric.DeploymentManager.CheckRPCAccess(IEnumerable1 machineNames) 在 System.Fabric.DeploymentManager.d__a.MoveNext() --- 从先前抛出异常的位置结束堆栈跟踪 --- 在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务) 在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(任务任务) 在 System.Fabric.DeploymentManager.d__0.MoveNext() --->(内部异常 #0)System.IO.IOException:RPC 无法访问机器 172.24.186.140。检查网络连接 活动性。 HRESULT=53 ERROR_BAD_NETPATH 在 System.Fabric.DeploymentManager.b__5f(串机) 在 System.Threading.Tasks.Parallel.c__DisplayClass17_0`1.b__1() 在 System.Threading.Tasks.Task.InnerInvokeWithArg(任务子任务) 在 System.Threading.Tasks.Task.c__DisplayClass176_0.b__0(Object )

--->(内部异常 #1)System.IO.IOException:RPC 无法访问机器 172.28.166.142。检查网络连接 活动性。 HRESULT=53 ERROR_BAD_NETPATH 在 System.Fabric.DeploymentManager.b__5f(串机) 在 System.Threading.Tasks.Parallel.c__DisplayClass17_0`1.b__1() 在 System.Threading.Tasks.Task.InnerInvokeWithArg(任务子任务) 在 System.Threading.Tasks.Task.c__DisplayClass176_0.b__0(Object )

--->(内部异常 #2)System.IO.IOException:RPC 无法访问机器 172.25.205.155。检查网络连接 活动性。 HRESULT=53 ERROR_BAD_NETPATH 在 System.Fabric.DeploymentManager.b__5f(串机) 在 System.Threading.Tasks.Parallel.c__DisplayClass17_0`1.b__1() 在 System.Threading.Tasks.Task.InnerInvokeWithArg(任务子任务) 在 System.Threading.Tasks.Task.c__DisplayClass176_0.b__0(Object )

【问题讨论】:

【参考方案1】:

显示从您的控制器到 172.28.166.142 的 RPC 已关闭。试试“test-netconnection 172.28.166.142 -port 135”

【讨论】:

以上是关于带有 Docker 容器和 windowsservercore 和 iis 服务器的 Service Fabric 集群的主要内容,如果未能解决你的问题,请参考以下文章

Windows Server 2019 容器化探索-Docker安装

如何在 AWS Windows Server 环境中运行 Docker?

Windows Server 2016 安装 Docker

带有 Docker 容器和 windowsservercore 和 iis 服务器的 Service Fabric 集群

Windows Container 和 Docker

将带有数据的 Docker 容器克隆到另一个主机