0

I cannot add a connection in oracle SQL developer installed.
The error I am getting is:

IO Error :The network adapter could not establish connection.

Also can anyone help me as to what user name and password it is asking?
Is there anything else I need to install.

1

4 Answers 4

1

SQL Developer is a tool which enables you to connect to the database - let's presume an Oracle one. Did you install it? If not, is there any available on the network? If not, you'll have to do that first (i.e. install a database - 11g Express Edition might be your choice, download it here), and then let SQL Developer connect to it.

As of username and password you'd use: database owner is SYS, but - you shouldn't use it for coding training - you'd rather create a new user, or unlock one of pre-installed; unless I'm wrong, 11gXE contains the HR schema (Human Resources). In order to unlock it, establish a connection to the previously mentioned SYS user (remember which password you choose for it during the installation process) and choose the SYSDBA role. Then unlock the HR user and modify its password by issuing the following statements:

alter user hr account unlock;
alter user hr identified by hr;

Now create a new connection to HR user (this time choose the "default" role); you should be able to see its tables, run queries, etc.

Sign up to request clarification or add additional context in comments.

Comments

0

Make sure your oracle database is up and running.. if you are using docker you need to restart the oracle docker image in this case.

I had similar issue then i tried to restart the oracle using

docker-compose -f docker-image-oracle.yml -d up (in this case you might have a diff name).

or you can start docker image directly from cmd .

Comments

0

Make sure that your hostname, listener port, sid/service name, username/password are correct.

You can use lsnrctl status to get the port number.

Comments

0

There are four things that come to my mind:

  1. Is your Oracle Database installed and running? If not, install it and make sure it works.

  2. Have you entered the correct username and password? Have you entered the correct hostname and/ or port number? If hostname and port number are wrong, check the listener.ora file (if you have the permission). Alternatively, you can look into the tnsnames.ora file.

  3. Maybe your listener is not working after all. With the command "C:> lsnrctl status" (on cmd), you can check, if the listener works. If it doesn't, run the command "C:> lsnrctl start".

  4. Are you using the right URL?

The following link may help you:

https://community.oracle.com/tech/welcome/discussion/2547624/io-error-the-network-adapter-could-not-establish-the-connection

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.