MyQuerySolution
Monday, 15 December 2014
Enable Query Logging in MySQL
To enable query logging in MYSQL. Use the following command:
SET
GLOBAL
general_log
=
'ON'
;
Linux helpful space utililization commands
Command to
find all log files
that are older than two days
find –name '*.log' –mtime +2 -exec ls –l {} \;
Command to
find and delete all log files
that are older than two days
find -name '*.log' -mtime +2 -exec rm {} \;
Command to find files with
size more than 50 MB
find . -type f -size +50000k -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'
Command to display dir structure with size in GB
du -h ./ | grep ^[0-9.]*G
Newer Posts
Home
Subscribe to:
Posts (Atom)