Azure Server VM connection to OnPrem SQL

  • Hi

    i have a Azure VM that cannot connect to my onprem sql2016 server via SQL connection string i have tested the following from my Azure VM to my onprem SQL

    RDP - Works

    SQL MGMT Studio - Works

    Ping - Works

     

  • you don't state what is the application running on the VM that is trying to connect to the server - but assuming it uses standard connection strings and that you have validated them, the issue is then likely to be firewall between the VM and the on prem server, depending on the error the app gets. (which you should have supplied), or the user the app is running under does not have access to that sql server (this would be seen on the SQL Logs), or the SQL Instance has a login server script that prevents that VM from connecting.

  • sorry its a web server that needs to connect. the server had the permissions required to connect to the SQL

    Server Error in '/Apps' Application.

    Could not connect to database.  Please ensure that database is running, security is set appropriately, and that the configured connection string is accurate.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.Exception: Could not connect to database.  Please ensure that database is running, security is set appropriately, and that the configured connection string is accurate.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    • This reply was modified 2 years, 1 month ago by  hpatel.
  • This was removed by the editor as SPAM

  • This was removed by the editor as SPAM

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply