Accesing MySQL through java
Hi everybody, I'm having some problems accesing my MySQL sever (version 3.20.32). From a terminal i can log into MySQL with mysql -u root db_name, which works fine. But when I try to Connect to the same database through a Java app, then I get Access Denied errors - why? I use the mmMySQL JDBC driver and JDK 1.2.2 RC3 on Linux RedHat 6.1 Does anyone know a solution to my problem - I'm sure it's just a minor problem, but me being a beginner and all ;-)) Med Venlig Hilsen / Best Regards Henrik Krobath Olesen Datalogistuderende Web: www.cs.auc.dk/~krobath E-mail: [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Java3D examples
Gerald Quintana wrote: > > Hi, > > I've just installed java3d on my JDK 1.2.2 RC2 (Linux Mandrake 6.x), but > the examples which use texture doesn't work. For example BillBoard, > TextureTest... > > The error message is: > method unknown (eip = 65000a0b) > SIGSEGV 11* segmentation violation > si_signo [11]: SIGSEGV 11* segmentation violation > si_errno [0]: Succčs > si_code [0]: SI_USER [pid: 0, uid: 0] > stackpointer=0x2f6ac098 I've seen the similar error once yestersday while testing my own application: Running Potato uptodate glibc with JDK1.2.2 RC4 My errror is here SIGSEGV 11* segmentation violation si_signo [11]: SIGSEGV 11* segmentation violation si_errno [0]: Success si_code [0]: SI_USER [pid: 0, uid: 0] stackpointer=0xbe3ff5f4 Full thread dump Classic VM (Linux_JDK_1.2.2_RC4, native threads): "Screen Updater" (TID:0x428c4390, sys_thread_t:0x868f7f0, state:R, native ID:0x340c) prio=4 at sun.awt.ScreenUpdater.run(ScreenUpdater.java, Compiled Code) "Thread-1" (TID:0x428b7848, sys_thread_t:0x4d007108, state:CW, native ID:0x280b) prio=1 at java.lang.Object.wait(Native Method) at java.lang.Object.wait(Object.java, Compiled Code) at com.terabeam.town.MyThread.run(MyThread.java, Compiled Code) "TimerQueue" (TID:0x428e6f20, sys_thread_t:0x4ce84b00, state:CW, native ID:0x240a) prio=5 at java.lang.Object.wait(Native Method) at javax.swing.TimerQueue.run(TimerQueue.java, Compiled Code) at java.lang.Thread.run(Thread.java, Compiled Code) "Thread-0" (TID:0x428e8d40, sys_thread_t:0x4ce22020, state:CW, native ID:0x2009) prio=1 at java.lang.Object.wait(Native Method) at java.lang.Object.wait(Object.java, Compiled Code) at com.terabeam.town.GUIBeamLocation$UpdateThread.run(GUIBeamLocation.java, Compiled Code) "Image Fetcher 0" (TID:0x428f8f30, sys_thread_t:0x8359030, state:CW, native ID:0x1c08) prio=8 at java.lang.Object.wait(Native Method) at sun.awt.image.ImageFetcher.nextImage(ImageFetcher.java, Compiled Code) at sun.awt.image.ImageFetcher.fetchloop(ImageFetcher.java, Compiled Code) at sun.awt.image.ImageFetcher.run(ImageFetcher.java, Compiled Code) "AWT-Motif" (TID:0x428ee420, sys_thread_t:0x82baec8, state:R, native ID:0x1807) prio=5 at sun.awt.motif.MToolkit.run(Native Method) at java.lang.Thread.run(Thread.java, Compiled Code) "SunToolkit.PostEventQueue-0" (TID:0x428edf78, sys_thread_t:0x82a9ee0, state:CW, native ID:0x1406) prio=5 at java.lang.Object.wait(Native Method) at java.lang.Object.wait(Objec
RE: JNI & .so Files
Thanks, Weiqi. Yes it works. Is it for two threads only? Regards, Lee -Original Message- From: Weiqi Gao [mailto:[EMAIL PROTECTED]] Sent: Friday, February 04, 2000 12:57 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: JNI & .so Files [EMAIL PROTECTED] wrote: > > [accessing global variables from different threads] Your so1_beep.c is not thread-safe. And sure enough it crashes when called from multiple threads. Making it thread safe means that you have to make the changes specified in the Multithreaded Programming Guide. Linux doesn't seem to have a guide like this. Balenhof's Pthreads book or the Sun Multithreaded programming guide (http://docs.sun.com) are good starting points. But then we are not talking about Java anymore. Maybe comp.programming.threads is a more appropriate forum. I have made jsut enough of the changes to make the program 'work'. See the attachment. -- Weiqi Gao [EMAIL PROTECTED] = Weiqi Gao [EMAIL PROTECTED] __ Do You Yahoo!? Talk to your friends online with Yahoo! Messenger. http://im.yahoo.com -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
BlackDown JDK and Linux on IA64
Hi, Got two general questions here. Could someone provide some info? Thank you. Lee === Q1: If the current Balckdown JDK will be compatible with Linux64 and Intel IA64 platform? If not, any plan or info. on this? Q2: Can we freely distribute BlackDown jre (not jdk) to customers to let them run our java applications? I think someone may already asked similar questions before. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
JNI & _init() function in .so file
Hi, Got two questions on JNI and .so file. It would be appreciated if someone could help. Q1: I was told that when java jni loads .so file, the first function been called is _init(). Can I use it as a constructor to setup something when java app loads the .so file? If I put _init() func in .so C source file, compiler generates an error msg "multiple definition of '_init', /usr/lib/crti.o:first definition here". Q2: After java jni loads a .so file, how can I find the number of links to the .so file from a command line command and a lib call? Thank you. Lee -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: BlackDown JDK and Linux on IA64
On 2000-02-07 10:03:13 -0600, [EMAIL PROTECTED] wrote: > Q2: Can we freely distribute BlackDown jre (not jdk) to customers to let > them run our java applications? I think someone may already asked similar > questions before. The jre comes with a file LICENSE. It should tell you everything about this. :-) At least the jdk1.2pre2 can be distributed. Best regards Martin -- Martin Schröder, [EMAIL PROTECTED] ArtCom GmbH, Grazer Straße 8, D-28359 Bremen Voice +49 421 20419-44 / Fax +49 421 20419-10 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
occasional SEGVs in 122rc4
I'm seeing occasional SEGVs in (blackdown) JDK 1.2.2RC4 (green threads, sunwjit). Question 1: The JCK status page says that sunwjit is implicated in two JCK test segfaults. Is there any detail available on which tests/operations elicit this? I'd like to know what to avoid or even if I'm seeing a known problem case. The "known bugs and workarounds" page doesn't seem to deal with these cases and I cannot find any obvious matches in the jitterbug DB. Question 2: Is there anything I can do generate useful debugging information on this case for the blackdown team? Would the jdk-debug package (e.g. corefile) help? Afterthought question 3: In some strange situations (unrelated to the above issues), I occasionally get StackOverflowErrors. The reported stack frame has nothing obviously wrong with it - e.g. ten frames into initializing a new RMI server thread. Clearly, something other than deep recursion can result in a SOE. The question is, what? I've assumed that Lots of live threads can do it. Also, I cannot find out what the java stack size limit is or how to change it (yes, I already know how to set the *native* stack limits). Thanks much, -mik -- Michael Thome ([EMAIL PROTECTED]) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Free MSSQL JDBC driver
Hi I looked for production quality JDBC drivers for that RDBMS half a year ago. The best available are those sold by BEA. No freely available drivers exist for MsSQL that can be trusted for real world usage. M$ did not make that RDBMS themself, it's Sybase in disquise. It would be interesting to know what they had to pay for that ;-) Therefore you might be able to swap the M$SQL server for a Linux box with Sybase11 without too much trouble. That will give you good documentation, a _lower_ price ;-), better performance, better stability, and a vendor from whom you can purchase support and courses schould the need arise. --- http://www.image.dk/~elof -- Kristian Elof Soerensen [EMAIL PROTECTED] (+45) 45 93 92 02 On Sun, 23 Jan 2000, Marek Gmyrek wrote: > Hi, > > is there any free JDBC driver for MS SQL Server 7.0. I am looking > for a driver with a good national character support. The standard > JDBC-ODBC bridge (jdk1.1) does not support national characters at > all. Alternatively a one without national character support would > do either (I could do the rest myself). > > I appreciate any help and hints, > Marek. > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > > -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JNI & _init() function in .so file
At 10:17 02 Feb 2000 -0600, [EMAIL PROTECTED] wrote: > Q1: I was told that when java jni loads .so file, the first function been > called is _init(). Can I use it as a constructor to setup something when > java app loads the .so file? If I put _init() func in .so C source file, > compiler generates an error msg "multiple definition of '_init', > /usr/lib/crti.o:first definition here". That's right, this isn't going to happen - find another way. One suggestion is to use a C++ object constructor (singleton style). Another is to wait until the JVM calls your DLL and to do your work there. _init is used by the C compiler to do it's own initialisation - you can't provide your own implementation of it unless you don't link against the c runtime library (which you probably want to do) > Q2: After java jni loads a .so file, how can I find the number of links to > the .so file from a command line command and a lib call? huh? Paul -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: JNI & _init() function in .so file
On Mon, Feb 07, 2000 at 10:17:53AM -0600, [EMAIL PROTECTED] wrote: > Q2: After java jni loads a .so file, how can I find the number of links to > the .so file from a command line command and a lib call? I think you're asking: who has the .so open... true? The only way I know to get that info is to look at the memory map for each process. For all running processes, the /proc//maps file shows how memory is laid out (replace with process ID), including what shared libraries are loaded by that process. Nathan -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
