AppletTalk.com Forum Index AppletTalk.com
Java discussions newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The Network Adapter could not establish the connection

 
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java and Databases
View previous topic :: View next topic  
Author Message
kaeli
Guest





PostPosted: Tue Feb 24, 2004 4:00 pm    Post subject: The Network Adapter could not establish the connection Reply with quote




Hi all,

I copied some code from one (unix solaris) machine to another and am now
getting the following error:

The Network Adapter could not establish the connection

The exact same code works fine on the original machine, so the DB is up,
listeners are up, etc.
I am missing one vital thing - there is no Oracle installed on the new
machine. I just moved the classes111.zip file. I did not install Oracle.
I don't think I should have to, but obviously, I'm missing something I
need to connect.
(there is no tnsnames.ora, etc)

This fails on the new machine.
Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver());
Connection conn = DriverManager.getConnection
("jdbc:oracle:thin:url:port:instance", "username", "password");

Any ideas what I need to do to get a connection to a DB without having
to install oracle on the machine?

TIA

--
--
~kaeli~
She was engaged to a boyfriend with a wooden leg but broke
it off.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Back to top
Joe Weinstein
Guest





PostPosted: Tue Feb 24, 2004 5:10 pm    Post subject: Re: The Network Adapter could not establish the connection Reply with quote





kaeli wrote:

Quote:
Hi all,

I copied some code from one (unix solaris) machine to another and am now
getting the following error:

The Network Adapter could not establish the connection

The exact same code works fine on the original machine, so the DB is up,
listeners are up, etc.
I am missing one vital thing - there is no Oracle installed on the new
machine. I just moved the classes111.zip file. I did not install Oracle.
I don't think I should have to, but obviously, I'm missing something I
need to connect.
(there is no tnsnames.ora, etc)

This fails on the new machine.
Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver());
Connection conn = DriverManager.getConnection
("jdbc:oracle:thin:url:port:instance", "username", "password");

Check your URL. The one you print above seems broken.
It should be something like: "jdbc:oracle:thin:DBMSMACHINE:PORTNUMBER:SID

Joe Weinstein at BEA


Quote:

Any ideas what I need to do to get a connection to a DB without having
to install oracle on the machine?

TIA



Back to top
kaeli
Guest





PostPosted: Tue Feb 24, 2004 6:41 pm    Post subject: Re: The Network Adapter could not establish the connection Reply with quote



In article <MPG.1aa53113bf1f6ea9989c93 (AT) nntp (DOT) lucent.com>,
[email]tiny_one (AT) NOSPAM (DOT) comcast.net[/email] enlightened us with...
Quote:

Hi all,

I copied some code from one (unix solaris) machine to another and am now
getting the following error:

The Network Adapter could not establish the connection


Solved.

Solution: Had to add DNS entry for Oracle host machine to host files on
new machine. New machine was missing that entry.

Oops. :)

--
--
~kaeli~
Who is General Failure and why is he reading my hard disk?
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace


Back to top
Richard Wheeldon
Guest





PostPosted: Fri Feb 27, 2004 12:00 am    Post subject: Re: The Network Adapter could not establish the connection Reply with quote

kaeli wrote:
Quote:
Any ideas what I need to do to get a connection to a DB without having
to install oracle on the machine?

I'm having similar problems here. Which version of oracle are
you trying to connect to ?

Richard

Back to top
kaeli
Guest





PostPosted: Fri Feb 27, 2004 2:22 pm    Post subject: Re: The Network Adapter could not establish the connection Reply with quote

In article <403E88B8.41C6 (AT) rswheeldon (DOT) com>, [email]richard (AT) rswheeldon (DOT) com[/email]
enlightened us with...
Quote:
kaeli wrote:
Any ideas what I need to do to get a connection to a DB without having
to install oracle on the machine?

I'm having similar problems here. Which version of oracle are
you trying to connect to ?

Richard


I solved this problem. The machine I was on didn't "know" the machine
Oracle was on by it's name. Adding an entry to one of the config files
for the machine fixed it.
It was Oracle 8i.

--
--
~kaeli~
Contrary to popular opinion, the plural of 'anecdote' is
not 'fact'.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace


Back to top
Display posts from previous:   
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java and Databases All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.