Discovering the platform profile from JavaWhat's the simplest way to get CPU speed, amount of RAM, OS version, and other hardware details from the running JVM? I'm putting together a yet-to-be-announced tool that will include hardware specs in its reporting.
So far, I've been able to get the hardware profile on Mac OS X using
sysctland on Linux using
java.vm.name: Java HotSpot(TM) Client VM
os.name: Mac OS X
host.cpu.names: Genuine Intel(R) CPU 1500 @ 2.00GHz
This comes from a quick-n-dirty Java app, HostInfo.java. Curious - anyone know of a simpler approach? Or a more reliable API? I'm not interested in JNI or nontrivial applications, since they complicate deployment.
Still to do - figure out what's necessary to discover this information on the Windows platform...