How to use stat command In Linux
The basic syntax of using stat command is as follows:
stat --options filenames
Stat can accept one or more filenames as an input to the stat command. Now let’s see one example
stat /etc/resolv.conf
Output:
Stat command in Linux with examples
The stat is a command which gives information about the file and filesystem. Stat command gives information such as the size of the file, access permissions and the user ID and group ID, birth time access time of the file. Stat command has another feature, by which it can also provide the file system information. This is the best tool to use when we want the information of any file.
Now let’ see one by one how can we use the stat command.