Getting System Information with uname

Information about your Unix system might come in handy if you’re planning to try some new software or need to figure out system idiosyncrasies. Some systems tell you this information when you log in. Sometimes, however, especially if you’re using an ISP, you may not have been told any particulars about the Unix system. You can easily find out what kind of Unix system you’re using with uname, as shown in Code Listings 7.1 and 7.2.

Code Listing 7.1. Variants on the uname command provide all kinds of interesting or useful information about the system.
ejray@home $  ssh frizz
Last login: Wed Oct 10 09:59:09 from frazz
Sun Microsystems Inc.  SunOS 5.9  Generic
  → May 2002
ejray@frizz $ uname SunOS ejray@frizz $  ...

Get Unix Third Edition: Visual Quickstart Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.