file command
file command can be used to determine filetype.
For example.
# file file.txt
file.txt: ASCII text
# file testfile.pdf
testfile.pdf PDF document, version 1.5
You can also check disk files.: ( you need root permission though)
file -s /dev/sda1
$ sudo file -s /dev/sda1
/dev/sda1: Linux rev 1.0 ext4 filesystem data, UUID=ABCD-ABCD-XYZ (needs journal recovery) (extents) (large files) (huge files)
No comments:
Post a Comment