Open System Services System Calls Reference Manual (G06.29+, H06.08+, J06.03+)
System Functions (u) uname(2)
NAME
uname - Gets information identifying the current system
LIBRARY
G-series native OSS processes: system library
H-series OSS processes: implicit libraries
SYNOPSIS
#include <sys/utsname.h>
int uname(
struct utsname *name);
PARAMETERS
name Points to the utsname structure, where information about the current system is
stored.
DESCRIPTION
The uname( ) function stores information identifying the current system in the structure pointed
to by the name parameter.
The uname( ) function uses the utsname structure, which is defined in the sys/utsname.h file as
follows:
struct utsname {
char sysname [32];
char nodename[32];
char release [8];
char version [8];
char machine [16];
};
The uname( ) function returns null-terminated character strings describing the current system.
The sysname[ ] array indicates the operating system. For example, the HP implementation uses
the value "NONSTOP_KERNEL" on G-series release version updates (RVUs) through at least
G06.25.
The nodename[ ] array contains the name that the system is known by on an Expand communi-
cations network; for example, "boston".
The release[] array identifies the release version (RV); for example, "H06" might appear for an
H-series release version update.
The version[] array contains the version update number of the RVU. For example, "25" appears
for the G06.25 RVU.
The machine[] array indicates the processor hardware type being used; for example, "NSR-N"
or "NSR-T" might be used for a NonStop S-series server, while "NSE-A" might be used for a
NonStop Integrity NS-series server.
Because the format and content of the utsname structure can change from release to release, it is
not advisable to make programmatic choices based on the layout of the fields in this structure.
527186-023 Hewlett-Packard Company 9−5