Since 5.1 query logging can be enabled at runtime.
Login to your MySQL server
mysql -uroot -pSee current setup
mysql> SHOW VARIABLES LIKE "general_log%";At this point make sure log file is created and mysql can write to this file.
mysql> SET GLOBAL general_log = 'ON';In case MySQL crapps out:
apt-get purge mysql-server mysql-common mysql-client-<version>then
apt-get install mysql-server mysql-common mysql-clientIn case MySQL upgrade is required:
apt-get install mysql-client-core-5.6
apt-get install mysql-client-5.6
apt-get install mysql-server-5.6