Answer the question
In order to leave comments, you need to log in
Why won't the client connect to the Oracle database?
Kind everyone! Help, this is the problem. There is an Oracle 11G enterpise server, it is installed on the Centos 6 operating system. The database is up and running on it. Opened ports 1158 and 1521. Oracle client was installed on another Windows7 machine. In the /etc/hosts file on Centos and in the c:....etcdriverhosts file on Windows, respectively, my test server centos6.dbaora.com is registered. Ping from Windows7 to Centos6 passes by server name. So when I try to connect in the Oracle client via the Oracle Net Configuration Assistant, I write a connection error, and I enter the correct login and password. What could be the problem? Thank you. Ps added screenshots and logs.
pastebin.com/auMFPKeg
pastebin.com/LNsFWYEM
Answer the question
In order to leave comments, you need to log in
Point by point:
1. Try to connect to the database locally (connect via SSH, in the su - oracle command line, jump to the sqlplus location folder, run sqlplus / nolog, then conn / as sysdba, enter the SYS password.
If, OK means the database can accept connections.
At the same time, check that the instance is running.
2. In the same place, from SSH, try to connect through the listener (sqlplus / nolog, enter [email protected], if you receive a password prompt, then everything is OK.
3. If not, then tnsping dbname If there is no ping, then configure tnsnames.ora.I recommend to store only one copy of the file with this name on the host.The path to the file can be set through the TNS_ADMIN environment variable.4.If
in step 2. OK, then repeat step 3 from the remote host.
5. If in clause 4. OK, then expel the aliens from the computer)
6. If in paragraph 4 is not OK. Try "telnet hostname 1521" first. There is an invitation - there is access to the host. No invitation - smoke the firewall.
7. If you have access to the host and no connection, set up a remote tnsnames.ora. The recommendations are the same.
tnsnames.ora is located in ORA_HOME/NETWORK/ADMIN or the path in the TNS_ADMIN environment variable.
Here is an example of one setting from the file
DB_name=
(DESCRIPTION=
(ADDRESS=(PROTOCOL=TCP)(HOST=IP_host_or_domain_name)(PORT=1521))
(CONNECT_DATA=(SID=SID_DB)(SERVER=DEDICATED))
)
SID_DB can be viewed with the lsnrctl command status on command line over SSH
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question