Trying to connect to Oracle on Windows server


 
Thread Tools Search this Thread
Special Forums UNIX and Linux Applications Trying to connect to Oracle on Windows server
# 1  
Old 11-22-2011
Trying to connect to Oracle on Windows server

Hi,

I am a newbie to Linux and still trying to learn. Here is my situation.

I have a windows server where I installed Oracle DB. On the same Windows server, I have a VM running linux. I can ping Windows server IP successfully from linux.

I installed sqlplus on linux and trying to access the oracle db tables on windows server. I am able to invoke sqlplus in linux but failing to connect to Oracle with an error message of target host doesnt exist. I configured all variables such as PATH, LD_LIBRARY_PATH correctly.

Please tell me where I am going wrong.

Thanks
# 2  
Old 11-22-2011
Can you post the exact command line you're using?
# 3  
Old 11-22-2011
I am invoking sqlplus by just typing sqlplus on the command line. Then it is asking for username and password which I am entering in and ending up with an error Target host doesn't exist. I see that I have to set environment variable called ORACLE_HOME to the directory where oracle was installed. This is exactly what my question was.

How do I set a environment variable in linux that points to a windows server directory assuming that windows and linux are in the same network?
# 4  
Old 11-22-2011
No, there's quite a bit more to it. ORACLE_HOME points to the location where the software was installed, either for the server or the client. It never points to any directory on the machine the database instance is running on.

Instead you'll have to set up /etc/tnsnames.ora to point to the listener of the instance.
# 5  
Old 11-22-2011
Okay.

Will you be able to help me in setting Oracle_home to the location where the oracle software was installed.

As I said earlier, Oracle is running on a windows server and linux on a vm.

As long as tnsnames and listener goes, here is what exactly I did. I went through the configuration directions from Oracle website and downloaded Oracle instant client basic, sqlplus package & odbc package for linux x86-64. Afterwards, I unzipped all the contents to one single directory called instantclient_11_2 and copied this directory to linux followed by setting environment variables PATH & LD_LIBRARY_PATH. Then, I copied tnsnames.ora file from network folder in windows and placed in linux instantclient_11_2 folder.

This is all what I did.

Please suggest where the things are going wrong.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Not able to connect to Oracle server from shell script

Hi, I am facing an issue in connecting to database from Linux shell script. Here is my code export ORACLE_BASE=xxx export ORACLE_SID=xxx export ORACLE_HOME=xxxx DB_PATH=xxx/'yyy@yy' UserId=`sqlplus -s $DB_PATH <<EOF set head off feedback off select max(USER_ID)+1 from USERS;... (6 Replies)
Discussion started by: yuvi
6 Replies

2. AIX

Connect from AIX 5.x to windows Server 2000 Shared Folder

Hi, I followed this procedure in order to mount in AIX a shared folder in windows server 2000. https://www-304.ibm.com/support/docview.wss?uid=isg3T1012550 Ive tested the shared folder from other windows Server, and its fine. What Ive do in AIX is: Logon as root Under /Home/spss/ I... (2 Replies)
Discussion started by: trevian3969
2 Replies

3. Linux

How to connect Linux server (configure two way authentication) with Windows server?

Hi my name is Manju. ->I have configure the two way authentication on my linux server. ->Now I am able to apply two way authenticator on particuler user. ->Now I want to map this linux server to my AD server. ->Kindly tell me how to map AD(Active Directory) with this linux server. ... (0 Replies)
Discussion started by: manjusharma128
0 Replies

4. Shell Programming and Scripting

Connect (SSH) to Windows server via Linux server through a script and passing command.. but failing

I am trying to connect to Windows server via Linux server through a script and run two commands " cd and ls " But its giving me error saying " could not start the program" followed by the command name i specify e g : "cd" i am trying in this manner " ssh username@servername "cd... (5 Replies)
Discussion started by: sunil seelam
5 Replies

5. Windows & DOS: Issues & Discussions

Connect to Windows server from Linux

Hi, We are running Linux server and are required to connect to Windows server and fetch the files from windows server. How can i connect to Windows server from Linux? I have to do this with a automated shell script on Linux I appreciate your response. (4 Replies)
Discussion started by: reachmexyz
4 Replies

6. Red Hat

Graphically connect RHEL server from Windows 7 Professional

I want to connect RHEL server from my windows 7 Professional machine graphically. I logged into 1 RHEL server with IP, 10.101.17.80 using Putty from my Windows 7 professional machine. Now from this server, 10.101.17.80, I want to connect to another RHEL server 10.101.17.79. I used, ssh -X... (1 Reply)
Discussion started by: RHCE
1 Replies

7. Shell Programming and Scripting

Connect to Oracle in Windows XP from Linux HOST

Hi everyone, I have oracle 9i installed in Windows XP and i have ubuntu in VM WARE. I would like to know how to connect to Oracle in windows xp from Linux through shel scripting...... (3 Replies)
Discussion started by: Zimbu
3 Replies

8. Shell Programming and Scripting

Connect windows server

Hi All, I need to connect windows server by unix shell script then search the directory for some keyword in all files in that directory... Windows Server is \\wh01ad04 Please help me and thanks in advance (2 Replies)
Discussion started by: Pratik4891
2 Replies

9. Windows & DOS: Issues & Discussions

To Connect to Windows server from Unix server

Hi i am writing a script in unix where after some validations, i require the script to connect to a windows server and then kich off a batch file there. i tried ftp and got the error message that "the remote host refused an attempted connect operation". I am able to connect to this unix... (4 Replies)
Discussion started by: vidzz911
4 Replies

10. Solaris

Connect smbclient to an windows server 2003 with active directory

Hello everybody .. i want connect with smbclient to an windows server 2003 with active directory. Exist a version of samba that can do this? Thank you very much for your time. Good Luck :b: (3 Replies)
Discussion started by: enkei17
3 Replies
Login or Register to Ask a Question