How about finding out how long it's been since the system's last reboot? Well, patSysinfo allows you to duplicate the "uptime" command with its getUptime() function. Take a look:
The getUptime() method returns the time since the system's last reboot as an associative array with keys "days", "mins" and "hours". This can then easily be formatted into a readable string, as above. Here's the output:
Want to know a little bit more about the hardware and software running on the system? Take a look at the getKernelVersion() and getCpu() functions, which return the current kernel version and processor details respectively.
The getCpu() function, in particular, deserves closer attention. This function returns an array, each element of which is itself an associative array representing one of the processors in the CPU (most often, you will have a single-processor CPU and therefore only one element in this array). The associative array for each processor itself contains information on the processor name, clock speed, cache size and other relevant values. Here's the output:
blog comments powered by Disqus |