How can I get the machine serial number and CPU ID in a Linux system?
Sample code is highly appreciated.
The Informations about the processor you could extract from /proc/cpuinfo.
/proc/cpuinfo
To get the Serial Number you should have a look at dmidecode. I didn't look in there right now, but dmidecode is able to show you the serial number, so i would start there.
dmidecode