Linux Commands Helper
💬 Your AI-powered Linux assistant
stat Command - Display File or File System Status
The stat command is used to display detailed information about files or file systems, such as size, permissions, timestamps, and more.
Syntax
stat [options] file...
Examples
stat myfile.txt
Show detailed status information for 'myfile.txt'.
stat /etc/passwd
Display status of the '/etc/passwd' file.
stat -f /
Show file system status for the root directory.
Notes
- Useful for checking file permissions, ownership, and timestamps.
- Can display file system information with the
-f
option. - Often used for troubleshooting and scripting.