| 1 |
pajs |
1.1 |
general_stat_t *get_general_stats(); |
| 2 |
|
|
|
| 3 |
|
|
This call returns details omn the OS, e.g. hostname and uptime. |
| 4 |
|
|
|
| 5 |
|
|
It returns a static buffer general_stat_t |
| 6 |
|
|
|
| 7 |
|
|
typedef struct{ |
| 8 |
|
|
char *os_name; |
| 9 |
|
|
char *os_release; |
| 10 |
|
|
char *os_version; |
| 11 |
|
|
char *platform; |
| 12 |
|
|
char *hostname; |
| 13 |
|
|
time_t uptime; |
| 14 |
|
|
}general_stat_t; |
| 15 |
|
|
|
| 16 |
|
|
os_name is the operating system name, eg, SunOS, or Linux |
| 17 |
|
|
os_release is the operationg system release, eg 5.8 or 5.9 for solaris 8 and 9 |
| 18 |
|
|
os_version is the info revision of that OS release. |
| 19 |
|
|
platform is the hardware platform the OS runs on. E.g. Sun4U or i386 |
| 20 |
|
|
hostname is the name of the machine that it think it is called (nodename) |
| 21 |
|
|
uptime is uptime of the machine in seconds |