You can use the following commands: Show the last 5 lines: tail -5 /var/log/mysqld.log Show the last 20 lines: tail -20 /var/log/mysqld.log