Possible Duplicate:
How can I return system information in Python?
For example, to see if a Solaris is a Solaris X86 or Solaris SPARC?
>>> import platform
>>> platform.system()
'Darwin'
>>> platform.processor()
'i386'
>>> platform.platform()
'Darwin-10.8.0-i386-64bit'
>>> platform.machine()
'i386'
>>> platform.version()
'Darwin Kernel Version 10.8.0: Tue Jun 7 16:33:36 PDT 2011; root:xnu-1504.15.3~1/RELEASE_I386'
>>> platform.uname()
('Darwin', 'Hostname.local', '10.8.0', 'Darwin Kernel Version 10.8.0: Tue Jun 7 16:33:36 PDT 2011; root:xnu-1504.15.3~1/RELEASE_I386', 'i386', 'i386')
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With