Monday, November 21, 2011

The uname command

The command uname prints the name of the current unix system.

Syntax:
uname[-amnprsv]
uname[-S system_name]
uname prints the current system name of the unix system to standard output.It is mainly useful to determine which system one is using.The options cause selected information returned by uname and/or sysinfo command to be printed:
  • -a : Print all information.
  • -m: Print the machine hardware name.
  • -n:  Print the node name(name by which the system is known to the communication  network)   .This is the default setting.
  • -p: Print the processor type of the current host.
  • -r: Print the operating system release.
  • -s:Print the name of the operating system.
  • -v: Print the version of the operating system.
 On your computer specifying a system name argument to the -S option may change the node name. The system name argument is restricted to SYS_NMLN  characters.SYS_NMLN is an implementation specific value defined in <sys/utsname.h>  file. Only the super-user is allowed to use this capability.

The next post will talk about the passwd command.

No comments:

Post a Comment