• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

obtain cpu id,mac id

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello,i would like to know how to retrieve my system's mac id,cpu id using java..thanking you in advance...take care
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
 
Sheriff
Posts: 11343
Mac Safari Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For the MAC address, see the getHardwareAddress() method in java.net.NetworkInterface class (new to Java 1.6).

According to devx.com - Preparing for Hyper-Threading...

The CPUID instruction is not visible from high-level languages such as C/C++, C#, or Java. Calling CPUID from these languages requires either support for inline assembly or the ability to call an assembly language routine.

 
Ranch Hand
Posts: 252
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can do it with C++ using Windows management instrumentation API.
Then,use JNI for communication between c++ and java.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!