Connecting to Oracle database from another machine on LAN - oracle

Am a newbie to oracle, I've Oracle Database installed on my windows machine and I can connect to the database without any problem from my machine using the sqlPlus / SQL Developer. And I have a java application in my machine which needs to connect to the Database using JDBC driver. After downloading the ojdbc driver I can connect to the java application by providing the connection url as jdbc:oracle:thin:#127.0.0.1:1521:orcl
Now, I want to know how can I connect to my oracle database that is installed in my machine (ip address:10.0.xx.xx) from the java application which is running in another machine (ip address:10.0.yy.yy). BTW both the machines are connected in LAN.
Do I need to change anything in listener configuration or in tnsnames.ora file?
I checked these links for reference before posting this question:
How to connect to an Oracle DB from another system
also Cannot access oracle using sqlplus from another machine on the LAN
Please Suggest me how can I do this one. Thanks in advance.

The JDBC url has this form
jdbc:oracle:thin:#HOST:PORT:SID
So if you wanted to connect to an oracle server running on 10.1.2.3, on port 1521 (the default one), and on a database named 'stackoverflowdb' you'd use:
jdbc:oracle:thin:#10.1.2.3:1521:stackoverflowdb

Related

VM Informatica power centre client to data source connectivity issue in different server

In my Windows virtual machine, one Unix server hosted where Informatica is installed.
I want to connect oracle exadata dB which is present in different server.
I opened firewalls between Unix server to oracle exadata server. While trying to connect from Unix server using SQL client (sqlplus), I am able to connect. But from Informatica client which is present in same windows virtual machine, it is not working.
My doubt is do I need to open firewall from vm window also for client? If so does this mean, for new data source connectivity for informatica client and server we need to treat them separately?

remote oracle database connection

I am working on a project using oracle.The remote host pc ip address is 10.100.59.30 where my database exists.I want to connect the database from my computer(ip:10.100.59.150). How should I do it?Oracle listener is working fine.But Showing network adapter is not connecting.I checked the firewall.It is off.All is fine but database connection is not building up.I have tried every possible solution.Am I missing some silly things?I have tried with sqlplus username/password#hostA:1521 /XE in cmd.but not working.And I do not have oracle installed in my pc.
Do you have tnsnames.ora? Or here is AskTom answer how to connect to oracle without one.

To access the oracle database from one machine to another (with LAN)

I installed oracle11g in one machine and also created the database on it.Now I have to access the already created database from another machine(Remote).
Note: In second machine I'm not install anything for oracle.
Both systems are connected with LAN.
I have to install anything for Remote machine(2nd machine)? ( i.e. Instant Client)
Is this possible to connect the oracle database from one machine to another machine?
1) If you want to connect using some third party tool like Toad, SQL Tools etc., then you need to install Oracle Client in 2nd Machine and copy the tnsnames.ora content from your server machine.
2) If you want to use SQL*Plus only, login to the Server machine using SSH or TELNET and then fire sqlplus username/password#database to access oracle.
There can be more options, may be some other person can tell you here.

Connecting to remote Oracle database using Oracle Client

I have to connect to a remote Oracle database. Connection will only work with a VPN access to the remote network. I have already setup the VPN, and that is working.
Remote team has passed TNS.ORA settings. I have hardly worked on configuring oracle and neither I am aware of the setup that I need to have on my machine. I just need to run few queries to test the data.
Can somebody guide me on the setup and the configuration I need to have on my windows 7 to connect to a remote Oracle database ?.
My first assumption was to download Oracle client. I downloaded Oracle Insta Client files, but I have no idea how to configure it to connect to a remote database. I couldn't even find any ORA file in the installed files of Insta client.
One you installed the instant client and installed it, you can conect to the remote database by using an easyconnect string. If you are in sqlplus you can do the following:
CONNECT username#[//]host[:port][/service_name][:server][/instance_name]
Lets assume your remote host is remote1 and the service_name is test (This can be retrieved from the tnsnames.ora)
connect username#//remote1/test

Cannot connect to Oracle server

I have a Oracle server which can be accessed locally (i.e. from the computer where Oracle installed) using SQLPlus and default port 1521.
From a client computer, I can access shared folders on that server, but I cannot access the oracle database using SQLPlus or SQL Developer. "IO Error: The network Adapter could not establish the connection."
I am sure that there are problems on the Oracle server, because I can access other similar Oracle servers from the same client.
There is no problem with network connection as well.
Tnsnames.ora files are also OK. Three oracle services are started (same as other similar Oracle servers): listener, DBConsole and Service.
All are Windows systems.
How can I figure it out?
P.S.:
No firewall on server;
tnsping is OK.
I think the listener on the server or tnsnames.ora on client is the problem. When connecting from the server the sql*net protocol is bypassed.
On server run :
c:\lsnrctl status
and check if database is serviced by the listener and check if parameters are the same as in tnsnames.ora, use fully qualified host names.
EDIT
Check
c:\lsnrctl services
May be your firewall block your port. you can enable this by changing firewall setting.
This is windows 7 configuration to access port
Control panel->system and security->windows firewall->advanced setting->In bound rules-> new Rule(On right hand side)-> select port option with value as "1521" -> next next....

Resources