If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > problem with jdbc driver on linux suse 7.2

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-20-02, 08:07
tomekz tomekz is offline
Junior Member
 
Join Date: Aug 2002
Location: Berlin
Posts: 2
problem with jdbc driver on linux suse 7.2

I use databasepilot (jbuilder - tool) to connect informix database. databasepilot work with jdbcdriver - ifxjdbc.jar.
informix database is suse 7.2 linux machine.

I can't connect to database
java - errormessage:
java.sql.SQLException: Database not found or no system permission.

at com.informix.jdbc.IfxSqliConnect.<init>(IfxSqliCon nect.java)

at sun.reflect.NativeConstructorAccessorImpl.newInsta nce0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInsta nce(NativeConstructorAccessorImpl.java:39)

at sun.reflect.DelegatingConstructorAccessorImpl.newI nstance(DelegatingConstructorAccessorImpl.java:27)

at java.lang.reflect.Constructor.newInstance(Construc tor.java:274)

at com.informix.jdbc.IfxDriver.connect(IfxDriver.java )

at java.sql.DriverManager.getConnection(DriverManager .java:512)

at java.sql.DriverManager.getConnection(DriverManager .java:171)

at com.borland.dx.sql.dataset.Database.openConnection (Unknown Source)

at com.borland.jdbcx.metadata.DatabaseInfo.openConnec tion(Unknown Source)

at com.borland.jdbcx.metadata.e****n(Unknown Source)



informix on aix machines work without any problems.
It is linux problem?
Reply With Quote
  #2 (permalink)  
Old 08-20-02, 08:29
Roelwe Roelwe is offline
Registered User
 
Join Date: Aug 2002
Location: Belgium
Posts: 534
Is your Informix database on the linux machine?
Which user is in the connection statement of your jdbc url?
Does this user have CONNECT permissions in the database you want to connect to?
If you are executing it from a different machine, is your machine trusted?
Can you show me the URL?
I 've done this so many times, this must work!
__________________
rws
Reply With Quote
  #3 (permalink)  
Old 08-20-02, 08:47
Roelwe Roelwe is offline
Registered User
 
Join Date: Aug 2002
Location: Belgium
Posts: 534
I just checked some cases:
Could you try and set DBPATH=<path-to-db> in your URL.
If this doesn't work could you create a symbolic link to yr database in yr users home directory?
__________________
rws
Reply With Quote
  #4 (permalink)  
Old 08-20-02, 10:03
tomekz tomekz is offline
Junior Member
 
Join Date: Aug 2002
Location: Berlin
Posts: 2
Quote:
Originally posted by Roelwe
Is your Informix database on the linux machine?

yes


Which user is in the connection statement of your jdbc url?

root

Does this user have CONNECT permissions in the database you want to connect to?

yes

If you are executing it from a different machine, is your machine trusted?

???

Can you show me the URL?

jdbc:informix-sqli://192.168.1.4:1543/u1a/database/8/hcsdb:INFORMIXSERVER=tuxinfx_net;user=????;passwor d=????

I 've done this so many times, this must work!
with odbc driver work's everywhere! with jdbc only on aix machine/OS
Reply With Quote
  #5 (permalink)  
Old 08-21-02, 05:40
Roelwe Roelwe is offline
Registered User
 
Join Date: Aug 2002
Location: Belgium
Posts: 534
Is it possible to connect just to the server?
Maybe you shouldn't set informixserver in uppercase.
Best way to test a connection is with user informix.
try:

jdbc:informix-sqli://192.168.1.4:1543:informixserver=tuxinfx_net;user=i nformix;password=<password-of-informix>
__________________
rws
Reply With Quote
  #6 (permalink)  
Old 10-21-02, 03:46
sanjeevmpatil sanjeevmpatil is offline
Registered User
 
Join Date: Oct 2002
Posts: 5
Re: problem with jdbc driver on linux suse 7.2

I am also finding the same problem can you help me if find the solution
I am using suselinux7.3 ,InformixSE5.0 and jdbcdriver(type-4)
after running the jdbc java program to connect database .jdbc driver is getting loaded successfully ,but it gives the exception that can not find the database server.
thanks in advance
sanjeev



Quote:
Originally posted by tomekz
I use databasepilot (jbuilder - tool) to connect informix database. databasepilot work with jdbcdriver - ifxjdbc.jar.
informix database is suse 7.2 linux machine.

I can't connect to database
java - errormessage:
java.sql.SQLException: Database not found or no system permission.

at com.informix.jdbc.IfxSqliConnect.<init>(IfxSqliCon nect.java)

at sun.reflect.NativeConstructorAccessorImpl.newInsta nce0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInsta nce(NativeConstructorAccessorImpl.java:39)

at sun.reflect.DelegatingConstructorAccessorImpl.newI nstance(DelegatingConstructorAccessorImpl.java:27)

at java.lang.reflect.Constructor.newInstance(Construc tor.java:274)

at com.informix.jdbc.IfxDriver.connect(IfxDriver.java )

at java.sql.DriverManager.getConnection(DriverManager .java:512)

at java.sql.DriverManager.getConnection(DriverManager .java:171)

at com.borland.dx.sql.dataset.Database.openConnection (Unknown Source)

at com.borland.jdbcx.metadata.DatabaseInfo.openConnec tion(Unknown Source)

at com.borland.jdbcx.metadata.e****n(Unknown Source)



informix on aix machines work without any problems.
It is linux problem?
Reply With Quote
  #7 (permalink)  
Old 10-21-02, 05:25
Roelwe Roelwe is offline
Registered User
 
Join Date: Aug 2002
Location: Belgium
Posts: 534
Excuse me, you are working with Informix SE. SE doesn't have the INFORMIXSERVER variable. It uses the DBPATH variable to connect to the correct databases.
__________________
rws
Reply With Quote
  #8 (permalink)  
Old 10-21-02, 08:25
sanjeevmpatil sanjeevmpatil is offline
Registered User
 
Join Date: Oct 2002
Posts: 5
sir
with respect your answer i.e instead of INFORMIXSERVER variable DBPATH.
where shall i need to change.

I have attcahed my java program.

I AM USING INFORMIX SERVER SE
Attached Files
File Type: txt jdbctest.txt (566 Bytes, 138 views)
Reply With Quote
  #9 (permalink)  
Old 10-21-02, 09:44
Roelwe Roelwe is offline
Registered User
 
Join Date: Aug 2002
Location: Belgium
Posts: 534
This might help you:

A. NETWORK INFORMATION
----------------------

Informix JDBC Driver supports only the TCP/IP protocol, which means
you can connect to SE database servers only through the "setlitcp" or
"sesoctcp" network protocols. Some platforms, such as Solaris, only
support "setlitcp"; other platforms only support "sesoctcp." Check
your SE database server machine notes to verify the network protocol
supported by your platform.

To use the TCP/IP protocol, you must bring up an SE daemon. First
define an SE database server name in the SQLHOSTS file, specifying
either "setlitcp" or "sesoctcp," as shown in the following example:

myserver_tli setlitcp myhost sqlexec

Assume that in the example, "sqlexec" has a port number of 1525. This
information will be used in a later example.

To bring up the SE tlitcp daemon, execute the following command as
the "root" user:

$INFORMIXDIR/lib/sqlexecd myserver_tli -l /tmp/selog_tli

Use the UNIX "ps" command to check whether the SE daemon has been
successfully started.

B. DATABASE DIRECTORIES
-----------------------

INFORMIX-SE database servers can only read from or write to the
local directories on the computer where the SE daemon was started.
This means, for example, that you cannot create a database on an
NFS-mounted directory on the computer where the SE daemon was started.

By default, when you create a database through Informix JDBC Driver,
the driver asks the SE database server to create the database in your
home directory. This means that your home directory cannot be an NFS-
mounted directory.

If you do not want the database to be created in your home directory,
you can specify another directory by using the following syntax
after connecting to the SE database server:

CREATE DATABASE '//server-name/path/database_name';

For example, the following statement creates the database called
MYDB in the directory "/tmp/mydb.dbs" using the SE database server
"myserver_tli":

CREATE DATABASE '//myserver_tli/tmp/mydb';

You can specify this database in a database URL in your Java program,
as shown in the following example:

url = "jdbc:informix-
sqli://myhost:1525//tmp/mydb:informixserver=myserver_tli;user=rdtest;passw ord=test";
__________________
rws
Reply With Quote
  #10 (permalink)  
Old 10-22-02, 03:34
sanjeevmpatil sanjeevmpatil is offline
Registered User
 
Join Date: Oct 2002
Posts: 5
Thnaks for your help

hello sir
Thank you very much sir,
I have don the setting as u told, I have got the out put also.
Now i am able connect infromix server from jdbc program .

once again thank you for your help from last 3-4 days

sanjeev
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On