The following command allows non-root users to check the Linux version/release information.
$ cat etc`ls etc -F grep release$version$`
The following reasons explain why the above command gives the version and release information:
1. The release info is stored right under the etc directory.
The list below shows where the release info of each distribution is stored. You can see it stored right under the etc directory regardless of distribution type.
Location of the release info for each distribution
・Debian type (Ubuntu)
・RedHat type (CentOS)
2. Backquote syntax in bash
Backquote syntax in bash passes a certain command result as a parameter.
The above command means “show files with ‘release’ or ‘version’ at the end of their names which are stored under the directory ‘etc’”.