How to show the last queries executed on mysql

If you wish to see all queries being executed while developing php applications on ubuntu server, you should add the following changes inorder to see all the queries being executed.

Step 1

Open the file /etc/mysql/my.cnf and edit the information listed below

[mysqld]
log = /var/log/mysql/mysql.log

Step 2

service mysql restart

Step 3

tail -f /var/log/mysql/mysql.log

what clients say about us

Client testimonials

Our sites look great and run smoothly. Thanks for all your hard work and patience in getting us to where we are today.

contact us

Contact Us

If you have questions or want us to send you a quote for project please email us.

latest news

Articles

PHPUnit mock magic functions
Learn more about PHPUnit Partial Mock.