compute_os_id
Alias of os_id
### This function is deprecated. Please use os_id
Arguments
None
Returns
Always 0Displays
OS ID stringfind_posix_shell
Find a Posix-compatible shell on the current host
Search a bash shell first, then ksh
Arguments
None
Returns
Always 0Displays
Shell path if found, nothing if not foundos_arch
Display the current OS architecture (aka 'hardware platform')
Arguments
None
Returns
0Displays
OS distribos_distrib
Display the current OS distribution
Arguments
None
Returns
0Displays
OS distribos_family
Display the current OS family (Linux, SunOS,...)
Arguments
None
Returns
0Displays
OS distribos_id
Computes and displays a string defining the curent system environment
The displayed string is a combination of the OS name, version, system architecture and may also depend on other parameters like, for instance, the RedHat ES/AS branches. It is an equivalent of the 'channel' concept used by RedHat. I personnally call it 'OS ID' for 'OS IDentifier' and use it in every script where I need a single string to identify the system environment the script is currently running on.
If the current system is not recognized, the program aborts.
By convention, environments recognized by this function support the rest of the library.
**Contributors welcome !** Feel free to enhance this function with additional recognized systems, especially with other Linux distros, and send me your patches.
Arguments
None
Returns
Always 0Displays
OS ID stringos_version
Display the current OS version
Arguments
None
Returns
0Displays
OS distribpoweroff
Shutdown and poweroff the host
Arguments
None
Returns
does not returnDisplays
nothingreboot
Shutdown and restart the host
Arguments
None
Returns
does not returnDisplays
nothingshutdown
Shutdown and halt the host
Arguments
None