Linux: Get Last File System Check

Objective: Get the last time the ext2/ext3/ext4 filesystem was checked on Linux using e2fsck (a tool to check and repair a Linux ext2/ext3/ext4 file system).

The filesystem superblock holds a lot of parameters like block size, filesystem UUID, filesystem creation time, mount count, last checked time and many others. To determine when was the file system last checked or repaired using fsck, we will need to look at the “Last checked” field.

The device /dev/sda1 is used as an example. Replace it with the device in question. The filesystem devices on your system will be defined under the /etc/fstab file. For currently mounted file system devices, use the mount command.

If you want to update the last checked time to the current time, use the following syntax with the now keyword

If you want to update the last checked time to a custom time, use the time specifier YYYYMMDD[HH[MM[SS]]]. The below example sets the time to Dec 1 2014, 12 PM.

ibrahim = { interested_in(unix, linux, android, open_source, reverse_engineering); coding(c, shell, php, python, java, javascript, nodejs, react); plays_on(xbox, ps4); linux_desktop_user(true); }