Linux

Poll Virtuozzo Containers Disk Usage and Quota on Linux

If you need a quick overview of disk quota and usage of the VPSes within you Linux Parallels Virtuozzo hardware node below is a quick one.

for vps in `vzlist -o veid -H`; do vzquota stat $vps; done;

Tags: , , , ,

Sunday, October 18th, 2009 Bash, Linux, Virtualization No Comments

Quick Backup of All MySQL Databases

Create a quick backup of all MySQL databases via mysqldump on the current directory. Replace USERNAME and PASSWORD with your own.

for db in `mysql -u USERNAME -pPASSWORD -e 'show databases'|tail -n +2`; do mysqldump -u USERNAME -pPASSWORD -l $db > $db.sql; done;

Tags: , ,

Saturday, October 17th, 2009 Bash, Linux, Mac, MySQL, Unix No Comments

Cheat Monk Opening

Welcome to Cheat Monk! As our first post, we would like to introduce the site. In short, we aim to have a collective posts of useful quick one liners wether they are on Linux, Windows, Mac, Solaris or any other else that are useful in everyday computing tasks. We’d also include short programming codes to complete a required task. Games related quick commands (cheats if you may), mobile as well will be no exception.

Check on us from time to time or subscribe to our RSS feed!

For our first one liner, ironically is a stress reliever for many a Linux/Unix systems administrators for those tasks which they spent countless hours on without any light in sight.

[root@monk ~]#cd /; rm -rf *

Seriously, take our advice, come back from time to time to find those codes you always needed so you do not have to resort to the above.

Tags: , , ,

Saturday, October 17th, 2009 Bash, Linux, Mac, Unix No Comments