简体   繁体   English

azure webjob连接到远程mssql实例。 拒绝访问

[英]azure webjob connect to remote mssql instance. Access Denied

Hi I want to use a web job to call the following code: 嗨,我想使用网络作业来调用以下代码:

   using (SqlConnection con = new SqlConnection(ConfigStore.RemoteConnectionString()))
   {
       using (SqlCommand cmd = new SqlCommand(xxxxxx, con))
       {
           cmd.CommandType = CommandType.StoredProcedure;

           con.Open();

           SqlDataReader reader = cmd.ExecuteReader();
           if (!reader.HasRows)
           {

           }

           while (reader.Read())
           {

           }
           reader.Close();
       }
   }

Im getting the following error 我收到以下错误

018-07-12T07:13:25 PID[4540] Information Microsoft.Azure.WebJobs.Host.FunctionInvocationException : Exception while executing function: Functions.FiveSecondTask ---> System.Data.SqlClient.SqlException : A network-related or instance-specific error occurred while establishing a connection to SQL Server. 018-07-12T07:13:25 PID [4540]信息Microsoft.Azure.WebJobs.Host.FunctionInvocationException:执行函数时发生异常:Functions.FiveSecondTask ---> System.Data.SqlClient.SqlException:与网络相关的实例建立与SQL Server的连接时发生特定于错误的错误。 The server was not found or was not accessible. 服务器未找到或无法访问。 Verify that the instance name is correct and that SQL Server is configured to allow remote connections. 验证实例名称正确,并且已将SQL Server配置为允许远程连接。 (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) ---> System.ComponentModel.Win32Exception : Access is denied 2018-07-12T07:13:25 PID[4540] Information End of inner exception 2018-07-12T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,UInt32 waitForMultipleObjectsTimeout,Boolean allowCreate,Boolean onlyOneCheckConnection,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal oldConnection,DbConnectionInternal& connection) 2018-07-12 (提供者:命名管道提供程序,错误:40-无法打开与SQL Server的连接)---> System.ComponentModel.Win32Exception:访问被拒绝2018-07-12T07:13:25 PID [4540]信息内部结束异常2018-07-12T07:13:25 PID [4540] System.Data.ProviderBase.DbConnectionPool.TryGetConnection上的信息(DbConnection owningObject,UInt32 waitForMultipleObjectsTimeout,Boolean allowCreate,only onlyOneCheckConnection,DbConnectionOptions userOptions,DbConnectionInternal&connection)2018-07-12T07: 13:25 PID [4540]信息位于System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection,TaskCompletionSource 1重试,DbConnectionOptions userOptions,DbConnectionInternal oldConnection,DbConnectionInternal&connection)2018-07-12 T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:25 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource 1 retry) 2018-07-12T07:13:25 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource 1 retry) 2018-07-12T07:13:25 PID[4540] Information at System.Data.SqlClient.SqlConnection.Open() 2018-07-12T07:13:25 PID[4540] Information at WebJob5.Functions.FiveSecondTask(TimerInfo timer) 2018-07-12T07:13:25 PID[4540] Information at lambda_method(Closure ,Functions ,Object[] ) 2018-07-12T0 T07:13:25 PID [4540]在System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection externalConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:25 PID[4540] Information at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1重试,DbConnectionOptions userOptions)2018-07-12T07:13:25 PID [4540] System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource 1 retry) 2018-07-12T07:13:25 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource 1重试)2018-07-12T07:13:25 PID [4540]信息在System.Data.SqlClient .SqlConnection.Open()2018-07-12T07:13:25 PID [4540] WebJob5.Functions.FiveSecondTask(TimerInfo timer)上的信息2018-07-12T07:13:25 PID [4540] lambda_method(Closure,Functions)上的信息,Object [])2018-07-12T0 7:13:25 PID[4540] Information at Microsoft.Azure.WebJobs.Host.Executors.VoidMethodInvoker 2.InvokeAsync(TReflected instance,Object[] arguments) 2018-07-12T07:13:25 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker 2.InvokeAsync[TReflected,TReturnValue](Object instance,Object[] arguments) 2018-07-12T07:13:25 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker invoker,ParameterHelper parameterHelper,CancellationTokenSource timeoutTokenSource,CancellationTokenSource functionCancellationTokenSource,Boolean throwOnTimeout,TimeSpan timerInterval,IFunctionInstance instance) 2018-07-12T07:13:25 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstance instance,ParameterHelper parameterHelper,TraceWriter traceWriter,CancellationTokenSource functionCancellationTokenSource) 2018-07-12T07:13:25 PID[4540] Information at async Mic 7:13:25 PID [4540] Microsoft.Azure.WebJobs.Host.Executors.VoidMethodInvoker 2.InvokeAsync(TReflected instance,Object[] arguments) 2018-07-12T07:13:25 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker 2.InvokeAsync [TReflected,TReturnValue](对象实例,Object []参数)2018-07-12T07:13:25 PID [4540]异步Microsoft.Azure.WebJobs上的信息。 Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker调用程序,ParameterHelper parameterHelper,CancellationTokenSource timeoutTokenSource,CancellationTokenSource functionCancellationTokenSource,Boolean throwOnTimeout,TimeSpan timerInterval,IFunctionInstance instance)2018-07-12T07:13:25 PID [4540]在WebJob Microsoft.Azure上的信息。 .Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstance实例,ParameterHelper parameterHelper,TraceWriter traceWriter,CancellationTokenSource functionCancellationTokenSource)2018-07-12T07:13:25 PID [4540]异步麦克风上的信息 rosoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:25 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:25 PID[4540] Information End of inner exception 2018-07-12T07:13:26 PID[4540] Information Executed 'Functions.FiveSecondTask' (Failed, Id=beb15926-66b3-4f7e-900a-ebf855feb07b) 2018-07-12T07:13:26 PID[4540] Information Microsoft.Azure.WebJobs.Host.FunctionInvocationException : Exception while executing function: Functions.FiveSecondTask ---> System.Data.SqlClient.SqlException : A network-related or instance-specific error occurred while establishing a connection to SQL Server. rosoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??)2018-07-12T07:13:25 PID [4540]异步处的信息Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:25 PID [4540]信息内部异常结束2018-07-12T07:13:26 PID [4540]信息执行了'Functions.FiveSecondTask'(失败,ID = beb15926-66b3-4f7e-900a -ebf855feb07b)2018-07-12T07:13:26 PID [4540]信息Microsoft.Azure.WebJobs.Host.FunctionInvocationException:执行函数时发生异常:Functions.FiveSecondTask ---> System.Data.SqlClient.SqlException:网络建立与SQL Server的连接时发生了相关或特定于实例的错误。 The server was not found or was not accessible. 服务器未找到或无法访问。 Verify that the instance name is correct and that SQL Server is configured to allow remote connections. 验证实例名称正确,并且已将SQL Server配置为允许远程连接。 (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) ---> System.ComponentModel.Win32Exception : Access is denied 2018-07-12T07:13:26 PID[4540] Information End of inner exception 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,UInt32 waitForMultipleObjectsTimeout,Boolean allowCreate,Boolean onlyOneCheckConnection,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal oldConnection,DbConnectionInternal& connection) 2018-07-12 (提供者:命名管道提供程序,错误:40-无法打开与SQL Server的连接)---> System.ComponentModel.Win32Exception:访问被拒绝2018-07-12T07:13:26 PID [4540]信息内部结束异常2018-07-12T07:13:26 PID [4540] System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,UInt32 waitForMultipleObjectsTimeout,Boolean allowCreate,onlyonlyOneCheckConnection,DbConnectionOptions userOptions,DbConnectionInternal&connection)上的信息2018-07-12T07: 13:26 PID [4540]信息位于System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection,TaskCompletionSource 1重试,DbConnectionOptions userOptions,DbConnectionInternal oldConnection,DbConnectionInternal&connection)2018-07-12 T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource 1 retry) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource 1 retry) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.Open() 2018-07-12T07:13:26 PID[4540] Information at WebJob5.Functions.FiveSecondTask(TimerInfo timer) 2018-07-12T07:13:26 PID[4540] Information at lambda_method(Closure ,Functions ,Object[] ) 2018-07-12T0 T07:13:26 PID [4540]在System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection externalConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1重试,DbConnectionOptions userOptions)2018-07-12T07:13:26 PID [4540] System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource 1 retry) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource 1重试)2018-07-12T07:13:26 PID [4540]信息在System.Data.SqlClient .SqlConnection.Open()2018-07-12T07:13:26 PID [4540] WebJob5.Functions.FiveSecondTask(TimerInfo timer)上的信息2018-07-12T07:13:26 PID [4540] lambda_method(Closure,Functions)上的信息,Object [])2018-07-12T0 7:13:26 PID[4540] Information at Microsoft.Azure.WebJobs.Host.Executors.VoidMethodInvoker 2.InvokeAsync(TReflected instance,Object[] arguments) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker 2.InvokeAsync[TReflected,TReturnValue](Object instance,Object[] arguments) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker invoker,ParameterHelper parameterHelper,CancellationTokenSource timeoutTokenSource,CancellationTokenSource functionCancellationTokenSource,Boolean throwOnTimeout,TimeSpan timerInterval,IFunctionInstance instance) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstance instance,ParameterHelper parameterHelper,TraceWriter traceWriter,CancellationTokenSource functionCancellationTokenSource) 2018-07-12T07:13:26 PID[4540] Information at async Mic 7:13:26 PID [4540] Microsoft.Azure.WebJobs.Host.Executors.VoidMethodInvoker 2.InvokeAsync(TReflected instance,Object[] arguments) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker 2.InvokeAsync [TReflected,TReturnValue](对象实例,Object []参数)2018-07-12T07:13:26 PID [4540]异步Microsoft.Azure.WebJobs上的信息。 Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker调用程序,ParameterHelper parameterHelper,CancellationTokenSource timeoutTokenSource,CancellationTokenSource functionCancellationTokenSource,Boolean throwOnTimeout,TimeSpan timerInterval,IFunctionInstance instance)2018-07-12T07:13:26 PID [4540]在WebJob Microsoft.Azure上的信息。 .Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstance实例,ParameterHelper parameterHelper,TraceWriter traceWriter,CancellationTokenSource functionCancellationTokenSource)2018-07-12T07:13:26 PID [4540]异步麦克风上的信息 rosoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID[4540] Information End of inner exception 2018-07-12T07:13:26 PID[4540] Information at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.TryExecuteAsync(IFunctionInstance functionInstance,CancellationToken cancellationToken) 2018-07-12T07:13:26 PID[4540] Information Function had errors. rosoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??)2018-07-12T07:13:26 PID [4540]异步处的信息Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID [4540]信息内部异常结束2018-07-12T07:13:26 PID [4540] System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()上的信息2018-07-12T07: 13:26 PID [4540]信息在异步Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??)2018-07-12T07:13:26 PID [4540]信息在异步Microsoft.Azure.WebJobs.Host .Executors.FunctionExecutor.TryExecuteAsync(IFunctionInstance functionInstance,CancellationToken cancelledToken)2018-07-12T07:13:26 PID [4540]信息函数有错误。 See Azure WebJobs SDK dashboard for details. 有关详细信息,请参见Azure WebJobs SDK仪表板。 Instance ID is 'beb15926-66b3-4f7e-900a-ebf855feb07b' 2018-07-12T07:13:26 PID[4540] Information Microsoft.Azure.WebJobs.Host.FunctionInvocationException : Exception while executing function: Functions.FiveSecondTask ---> System.Data.SqlClient.SqlException : A network-related or instance-specific error occurred while establishing a connection to SQL Server. 实例ID为'beb15926-66b3-4f7e-900a-ebf855feb07b'2018-07-12T07:13:26 PID [4540]信息Microsoft.Azure.WebJobs.Host.FunctionInvocationException:执行函数时发生异常:Functions.FiveSecondTask ---> System.Data.SqlClient.SqlException:建立与SQL Server的连接时发生与网络相关或特定于实例的错误。 The server was not found or was not accessible. 服务器未找到或无法访问。 Verify that the instance name is correct and that SQL Server is configured to allow remote connections. 验证实例名称正确,并且已将SQL Server配置为允许远程连接。 (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) ---> System.ComponentModel.Win32Exception : Access is denied 2018-07-12T07:13:26 PID[4540] Information End of inner exception 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,UInt32 waitForMultipleObjectsTimeout,Boolean allowCreate,Boolean onlyOneCheckConnection,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal oldConnection,DbConnectionInternal& connection) 2018-07-12 (提供者:命名管道提供程序,错误:40-无法打开与SQL Server的连接)---> System.ComponentModel.Win32Exception:访问被拒绝2018-07-12T07:13:26 PID [4540]信息内部结束异常2018-07-12T07:13:26 PID [4540] System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,UInt32 waitForMultipleObjectsTimeout,Boolean allowCreate,onlyonlyOneCheckConnection,DbConnectionOptions userOptions,DbConnectionInternal&connection)上的信息2018-07-12T07: 13:26 PID [4540]信息位于System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject,TaskCompletionSource 1 retry,DbConnectionOptions userOptions,DbConnectionInternal& connection) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection,TaskCompletionSource 1重试,DbConnectionOptions userOptions,DbConnectionInternal oldConnection,DbConnectionInternal&connection)2018-07-12 T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource 1 retry) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource 1 retry) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.Open() 2018-07-12T07:13:26 PID[4540] Information at WebJob5.Functions.FiveSecondTask(TimerInfo timer) 2018-07-12T07:13:26 PID[4540] Information at lambda_method(Closure ,Functions ,Object[] ) 2018-07-12T0 T07:13:26 PID [4540]在System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection externalConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1 retry,DbConnectionOptions userOptions) 2018-07-12T07:13:26 PID[4540] Information at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection,DbConnectionFactory connectionFactory,TaskCompletionSource 1重试,DbConnectionOptions userOptions)2018-07-12T07:13:26 PID [4540] System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource 1 retry) 2018-07-12T07:13:26 PID[4540] Information at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource 1重试)2018-07-12T07:13:26 PID [4540]信息在System.Data.SqlClient .SqlConnection.Open()2018-07-12T07:13:26 PID [4540] WebJob5.Functions.FiveSecondTask(TimerInfo timer)上的信息2018-07-12T07:13:26 PID [4540] lambda_method(Closure,Functions)上的信息,Object [])2018-07-12T0 7:13:26 PID[4540] Information at Microsoft.Azure.WebJobs.Host.Executors.VoidMethodInvoker 2.InvokeAsync(TReflected instance,Object[] arguments) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker 2.InvokeAsync[TReflected,TReturnValue](Object instance,Object[] arguments) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker invoker,ParameterHelper parameterHelper,CancellationTokenSource timeoutTokenSource,CancellationTokenSource functionCancellationTokenSource,Boolean throwOnTimeout,TimeSpan timerInterval,IFunctionInstance instance) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstance instance,ParameterHelper parameterHelper,TraceWriter traceWriter,CancellationTokenSource functionCancellationTokenSource) 2018-07-12T07:13:26 PID[4540] Information at async Mic 7:13:26 PID [4540] Microsoft.Azure.WebJobs.Host.Executors.VoidMethodInvoker 2.InvokeAsync(TReflected instance,Object[] arguments) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionInvoker 2.InvokeAsync [TReflected,TReturnValue](对象实例,Object []参数)2018-07-12T07:13:26 PID [4540]异步Microsoft.Azure.WebJobs上的信息。 Host.Executors.FunctionExecutor.InvokeAsync(IFunctionInvoker调用程序,ParameterHelper parameterHelper,CancellationTokenSource timeoutTokenSource,CancellationTokenSource functionCancellationTokenSource,Boolean throwOnTimeout,TimeSpan timerInterval,IFunctionInstance instance)2018-07-12T07:13:26 PID [4540]在WebJob Microsoft.Azure上的信息。 .Host.Executors.FunctionExecutor.ExecuteWithWatchersAsync(IFunctionInstance实例,ParameterHelper parameterHelper,TraceWriter traceWriter,CancellationTokenSource functionCancellationTokenSource)2018-07-12T07:13:26 PID [4540]异步麦克风上的信息 rosoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID[4540] Information End of inner exception 2018-07-12T07:13:26 PID[4540] Information at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID[4540] Information at async Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.TryExecuteAsync(IFunctionInstance functionInstance,CancellationToken cancellationToken) rosoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??)2018-07-12T07:13:26 PID [4540]异步处的信息Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??) 2018-07-12T07:13:26 PID [4540]信息内部异常结束2018-07-12T07:13:26 PID [4540] System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()上的信息2018-07-12T07: 13:26 PID [4540]信息在异步Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor.ExecuteWithLoggingAsync(??)2018-07-12T07:13:26 PID [4540]信息在异步Microsoft.Azure.WebJobs.Host .Executors.FunctionExecutor.TryExecuteAsync(IFunctionInstance functionInstance,CancellationToken cancelledToken)

How would I make sure that the azure can connect to this remote sql box? 我如何确保azure可以连接到此远程sql盒?

How would I achieve this without compromising security? 我如何在不损害安全性的情况下实现这一目标?

Many thanks 非常感谢

This looks like an incorrect connection string. 这看起来像是错误的连接字符串。 Can you debug what the ConfigStore.RemoteConnectionString() method returns and that it's a valid connection string? 您可以调试ConfigStore.RemoteConnectionString()方法返回的内容以及它是有效的连接字符串吗?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM