Find Linux install date using terminal. Here is how to check os installation date in RedHat Linux or Ubuntu Systems.
Run any one of the following commands. You will have to replace /dev/sda1 with correct hdd drive partition in the following set of commands. When executed correctly, the command will display when the file system was originally created.
sudo fs=$(df / | tail -1 | cut -f1 -d' ') && tune2fs -l $fs | grep 'Filesystem created'
Or,
sudo tune2fs -l /dev/sda1 | grep 'Filesystem created:'
Or,
sudo dumpe2fs /dev/sda1 | grep 'Filesystem created:'
NOTE: The above following commands will work on all Linux distributions supporting ext4 filesystems.
Find Linux Installation Date and Time Using Anaconda Files
You can find Linux installation date and time from anaconda files. The anaconda-ks.cfg file is automatically created to save your installation settings.
Simply run the command:
sudo ls -l /root/anaconda-ks.cfg
You can also use start command to find installation date and time. Simply run the command “$ stat -c %w /”.