|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
Re: jdbc driver freezes in connect under linux
From: Alexey Gaidukov (gaid
dc.baikal.ru)
Date: Mon Jan 16 2006 - 19:48:23 CST
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Yesterday I tested jre-1.4.2. In java.security was line
securerandom.source=file:/dev/random
Now in jre-1.4.2 I can't reproduce the problem. But in jre-1.5.0 line is
already
securerandom.source=file:/dev/urandom
and problem there is.
But after the following commands the problem is not reproduceable in
jre-1.5.0.
rm /dev/random
ln -s /dev/urandom /dev/random
But I guess it is not good idea.
Thanks in advance,
Alexey Gaidukov.
Schroeder, Alexander пишет:
> Hello Alexey,
>
> there seems to be an issue with the secure random device /dev/random
> on Linux if there isn't enough entropy available. It will then block.
>
> You need to set in $JAVA_HOME/jre/lib/security/java.security the
>
> securerandom.source=file:/dev/random
>
> to
>
> securerandom.source=file:/dev/urandom
>
> (/dev/urandom is the non-blocking companion of /dev/random).
>
> Then it should work.
>
> Regards
> Alexander Schröder
> SAP DB, SAP Labs Berlin
>
>
> -----Original Message-----
> From: Alexey Gaidukov [mailto:gaid
dc.baikal.ru]
> Sent: Montag, 16. Januar 2006 11:12
> To: maxdb
lists.mysql.com
> Subject: jdbc driver freezes in connect under linux
>
> JDBC 7_6_00_16_4753. MaxDB 7.6.00.16 linux 32 and 64 bit. On client side
> linux kernels 2.6.14-1.1653_FC4smp and 2.6.14.4 from kernel.org were
> tested. Tested java runtime: jre-1.5.0-6, jre-1.5.0-4 and j2sdk1.4.2_10.
>
>
> When I run the following simple application then this application is
> freezed in "getConnection" and will waiting keyboard events. If there is
> no keyboard events then waiting can be very long. I'm waiting about half
> of hour. If to connect with NetBeans debugger then jre is waiting in
> com.sap.dbtech.util.security line 50 ( "while (true)" line). I have this
> problem with all programs on linux with JDBC driver - sync manager
> message server, sync manager GUI and other. In GUI programs mouse events
> can help. In console program only keyboard events can help. If I connect
> to linux with scp or telnet then nothing can help and waiting time is
> random.
>
>
> package javaapplication3;
> import java.sql.*;
> public class Main {
> static final java.util.Properties connectionInfo = new
> java.util.Properties();
> public Main() {}
> public static void main(String[] args) {
> try {
> String driver = "com.sap.dbtech.jdbc.DriverSapDB";
> String url = "jdbc:sapdb://maxdb/DCDB";
> Class.forName(driver);
> connectionInfo.put("driver", driver);
> connectionInfo.put("url", url);
> connectionInfo.put("user", "GIS");
> connectionInfo.put("password", "1");
> Connection connection = DriverManager.getConnection(url,
> connectionInfo);
> System.out.println("connection:"+connection);
> }
> catch (Exception e) {
> e.printStackTrace();
> }
> }
> }
>
>
>
--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]