Contained WithinFind More DocumentationFeatured Support Resources | Download this book in PDF (7229 KB)
uname(1)Name | Synopsis | Description | Options | Examples | Environment Variables | Exit Status | Attributes | See Also | Notes Name
Synopsisuname [-aimnprsvX] uname [-S system_name] DescriptionThe uname utility prints information about the current system on the standard output. When options are specified, symbols representing one or more system characteristics will be written to the standard output. If no options are specified, uname prints the current operating system's name. The options print selected information returned by uname(2), sysinfo(2), or both. Options
The following options are supported: ExamplesExample 1 Printing the OS name and release levelThe following command:
prints the operating system name and release level, separated by one SPACE character. Environment Variables
See environ(5) for descriptions of the following environment variables that affect the execution of uname: LANG, LC_ALL, LC_CTYPE, LC_MESSAGES, and NLSPATH. Exit StatusAttributesSee attributes(5) for descriptions of the following attributes:
See Alsoarch(1), isalist(1), sys-unconfig(1M), sysinfo(2), uname(2), nodename(4), attributes(5), environ(5), standards(5) NotesIndependent software vendors (ISVs) and others who need to determine detailed characteristics of the platform on which their software is either being installed or executed should use the uname command. To determine the operating system name and release level, use uname -sr. To determine only the operating system release level, use uname -r. Notice that operating system release levels are not guaranteed to be in x.y format (such as 5.3, 5.4, 5.5, and so forth); future releases could be in the x.y.z format (such as 5.3.1, 5.3.2, 5.4.1, and so forth). In SunOS 4.x releases, the arch(1) command was often used to obtain information similar to that obtained by using the uname command. The arch(1) command output "sun4" was often incorrectly interpreted to signify a SunOS SPARC system. If hardware platform information is desired, use uname -sp. The arch -k and uname -m commands return equivalent values; however, the use of either of these commands by third party programs is discouraged, as is the use of the arch command in general. To determine the machine's Instruction Set Architecture (ISA or processor type), use uname with the -p option. Name | Synopsis | Description | Options | Examples | Environment Variables | Exit Status | Attributes | See Also | Notes |
|||||||||