How to connect to Oracle database created to Azure from Azure portal

Ajay Gera 0 Reputation points
2024-12-04T13:57:13.3333333+00:00

I have created oracle database on Azure using Azure portal.

I have connection string / DataSource of that database.

On Trying to Connect to Oracle Database from Azure data Studio I am getting

"Connection request timed out" error.

Please let me know how to resolve this error so that I can connect to Oracle database?

Please note, while creating database in Azure, I had to select Virtual network and Subnet based upon my Subscription.

I am not sure if I need to configure some ip addresses(s) in Azure portal to connect to the oracle database or some other settings are needed?

Kindly help me in resolving this issue

Azure Data Studio
Azure Data Studio
A cross-platform database tool for data professionals using on-premises and cloud data platforms on Windows, macOS, and Linux.
124 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Mahesh Kurva 1,470 Reputation points Microsoft Vendor
    2024-12-04T18:21:08.2333333+00:00

    Hi @Ajay Gera,

    Welcome to the Microsoft Q&A and thank you for posting your questions here.You are facing a 'Connection request timed out' error when trying to connect to your Oracle database from Azure Data Studio.

    Here are some steps you can take to troubleshoot and resolve this issue:

    Check Network Security Group (NSG) Rules: Ensure that the Network Security Group (NSG) associated with your Virtual Network and Subnet allows inbound traffic on the port used by Oracle (default is 1521). You may need to add a rule to allow this traffic.

    Configure Firewall Rules: Verify that the firewall settings for your Oracle database allow connections from the IP address of your machine or the Azure Data Studio client. You might need to add your IP address to the allowed list.

    Enable Remote Access: Make sure that remote access is enabled for your Oracle database. This can typically be configured in the database settings.

    Connection String Configuration: Double-check your connection string to ensure it is correctly formatted. It should include the correct DataSource, port, and any required parameters.

    Increase Connection Timeout: Try increasing the connection timeout value in Azure Data Studio. Sometimes, the default timeout might be too short for the connection to be established.

    Verify Oracle Extension Installation: Ensure that the Oracle extension in Azure Data Studio is properly installed and configured. Sometimes, reinstalling the extension can resolve connectivity issues.

    Test Connectivity: Use tools like tnsping or SQL*Plus to test connectivity to your Oracle database from your machine. This can help identify if the issue is specific to Azure Data Studio or a broader network issue.

    Review Oracle Logs: Check the Oracle database logs for any errors or warnings that might provide more insight into why the connection is timing out.

    For more information, please refer the documents:

    https://learn.microsoft.com/en-us/azure/mysql/flexible-server/how-to-troubleshoot-common-connection-issues?source=recommendations

    https://learn.microsoft.com/en-us/azure-data-studio/quickstart-oracle?source=recommendations

    Hope this helps. Do let us know if you any further queries.

    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.