javasysmon
javasysmon copied to clipboard
Uncompatible DLL loaded on Windows 64-bit
Windows monitor tries to load DLL depending on the system architecture. But I have Java 32-bit installed on Windows 64-bit. So I get next error: Can't load AMD 64-bit .dll on a IA 32-bit platform.
Hello,
there is also a 64 bit version of Java (SDK / SE) out there. Why don't you give it a try?
Greetz cj
I have a reason why I use that version. So because there is possibility to run both versions of JDK (32- and 64-bit) on Windows 64-bit, i think your library should work regardless which version it is used on.
From my point of view I don't see any good reason to run a 32 bit JDK on a 64 bit Windows system. And only because there is the possibility to do something one won't do anything just because it's possible ;-) switching to a 64 bit version is also possible and in my opinion preferable.
But if you really have a good reason why you need the 32 bit solution, you may feel free to branch the javasysmon lib and adapt / improve it to your needs. Again it's open source (and at least not my software ;-) )
- If you don't see something, it doesn't mean that it doesn't exist.
- Also it isn't evil to run 32-bit application on 64-bit system even there are 64-bit version of that application.
- And also Java program is executed by JVM first and then by OS, so it is more logical to check Java environment first especially when JNI is used.
P.S. I don't want to branch the library because it is unnecessary. P.S.S. You are a driver. :)
At 1. I like your philosophical approach :-) At 2. There is no EVIL (it's only in your head) At 3. Still I see some advantages (available memory) in using the 64 bit version but still none in the 32 (yeah I know, there are a lot of things out there I can't see :-) )
At the rest: I'm totally with you :-))
It isn't philosophy (electromagnetic waves, for example). And I'm not talking about reasons, advantages and so on. I'm just trying to think logically. :) Java apps run on JVM. But JVM is OS-specific. So if Java app uses OS-depended capabilities, i think it should check JVM abilities first. Sorry for my insistence. :)
The Windows DLLs were incorrectly recompiled in commit f50e6d4e8bd0c095523583d2e7076f32fc694a33, i.e.
dumpbin /headers lib\native\javasysmon.dll | find "machine"
8664 machine (x64)
dumpbin /headers lib\native\javasysmon64.dll | find "machine"
8664 machine (x64)
The lib\native\javasysmon.dll
version should be targeting x86
. Consequently, javasysmon
is broken on 32-bit Windows and with JRE 32-bit on 64-bit Windows.
Please can someone fix this problem ? I am using javasysmon 0.3.4
because of this . As @kwong-pfpt pointed the problem is this commit . How we can recompile these files to point the correct .dll ?
I created a fixed version and uploaded on this Github Repository -> https://github.com/goxr3plus/javasysmon
@goxr3plus's javasysmon2 (https://github.com/goxr3plus/javasysmon2), which appears to be an extension of project linked to above, has resolved this problem for me.
@sco-tt Nothing my dear friend, i mixed different stuff there 😂. It needs lot more work though to support all the features that i have added on readme, if you can help me ♥.
@goxr3plus plus direct me to some issues and I'll try to pitch in