[rt-users] Monitor disc space on RT/SQL database

Toby Darling darling at ccdc.cam.ac.uk
Thu Feb 21 10:49:08 EST 2008



 >> I need to know how to monitor available space for my RT database.  I
 >> am very much a novice regarding SQL db administration.  Are there any
 >> other areas I should keep my eye on to avoid any future RT db problems?

> If this is mysql, you can do something like this in mysql client:
> 
> use rt3; (or whatever your rt3 database is)
> show table status;

Providing you've got $HOME/.my.cnf setup correctly to give to direct 
access to the RT mysql database:

$ echo "show table status;" | mysql | \
    awk '{tot+=$7}END{print "DB using " tot / (1024 * 1024) "Mb"}'; \
    df -h /var/lib/mysql

Cheers
Toby

LEGAL NOTICE
Unless expressly stated otherwise, information contained in this
message is confidential. If this message is not intended for you,
please inform postmaster at ccdc.cam.ac.uk and delete the message.
The Cambridge Crystallographic Data Centre is a company Limited
by Guarantee and a Registered Charity.
Registered in England No. 2155347 Registered Charity No. 800579
Registered office 12 Union Road, Cambridge CB2 1EZ.



More information about the rt-users mailing list