Main Page | See live article | Alphabetical index

Uname

Uname is a computer program in Unix operating systems or Windows NT operating system that prints the name of the running operating system. It is useful when building software from source.

In the Windows Cygwin environment, uname is included in the "shellsutils" (may be called sh-utils) package available from the package manager (in this case, installer and the package manager are the same thing). Uname itself is not available as a separate package.

Example

Darwin Takuya-Muratas-Computer.local. 6.8 Darwin Kernel Version 6.8: Wed Sep 10 
15:20:55 PDT 2003; root:xnu/xnu-344.49.obj~2/RELEASE_PPC  Power Macintosh powerpc

This is the result with the -a option set.

man uname

UNAME(1)                System General Commands Manual                UNAME(1)

NAME
     uname - Print operating system name

SYNOPSIS
     uname [-amnpsrv]

DESCRIPTION
     The uname utility writes symbols representing one or more system charac-
     teristics to the standard output.

     The following options are available:

     -a      Behave as though all of the options -mnrsv were specified.

     -m     print the machine hardware name.

     -n      print the nodename (the nodename may be a name that the system is
             known by to a communications network).

     -p      print the generic processor type.

     -s      print the operating system name.

     -r      print the operating system release.

     -v      print the operating system version.

     If no options are specified, uname prints the operating system name as if
     the -s option had been specified.

SEE ALSO
     hostname(1), machine(1), uname(3)

STANDARDS
     The uname utility conforms to IEEE Std 1003.2-1992 (``POSIX.2'').

BSD                            January 26, 1994                            BSD