If you're working with PostgreSQL and want to get a better a sense of what's going on under the hood in your database, here's something cool: PgHero, created by Andrew Kane on GitHub, offers a variety of insights into running queries, used and unused resources, and things like that. The GitHub page lists the following commands:
PgHero.running_queries PgHero.long_running_queries PgHero.index_usage PgHero.missing_indexes PgHero.unused_indexes PgHero.unused_tables PgHero.database_size PgHero.relation_sizes PgHero.index_hit_rate PgHero.table_hit_rate # kill queries PgHero.kill(pid) PgHero.kill_all
And the end result is something like this:
(Source: PgHero on GitHub)
You'll need PostgreSQL 9.2 or better to run PgHero, and it's definitely still a work in progress - there's a TODO section on the GitHub page, after all - but still worth checking out.