slloyd has asked for the wisdom of the Perl Monks concerning the following question:

Is there a way to determine the age of a computer? In other words, when it was bought? I am specifically interested in detecting this on computers running windows. Is there a way to query the bios or motherboard to get an approximate age?

Replies are listed 'Best First'.
Re: How old is my computer?
by mr_mischief (Monsignor) on Sep 03, 2008 at 04:28 UTC
    I'm not sure about doing so programmatically that's portable among operating systems, but the boot information presented by most motherboards includes the copyright notice for the BIOS. You might need to disable the branded splash screen some mass-market pre-assembled PCs use to see it.

    If you need to know how to do so from code, you might need to find the call for your OS. Under Windows you can check the registry at HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System or the WMI class Win32_BIOS. For Linux I'm sure it's not too difficult, but I couldn't tell you without searching for it.

    Update: fixed a typo: s/Systemor/System or/

      Under GNU/Linux and FreeBSD you can use the "dmidecode" command, for example :
      ~ # dmidecode -s bios-release-date 02/09/2006
      Thanks a lot. Just what I needed!

      -------------------------------
      Sign up now for a free monthly newsletter service!
      http://www.bestgazette.com

Re: How old is my computer?
by planetscape (Chancellor) on Sep 03, 2008 at 06:35 UTC