Skip to content

Instantly share code, notes, and snippets.

View wweidendorf's full-sized avatar

William Weidendorf wweidendorf

  • San Francisco, CA
View GitHub Profile
[xspond@autodata1 current]$ passenger start
*** ERROR ***
Could not start Passenger Nginx core:
[alert]: Unable to start the Phusion Passenger watchdog because it encountered
the following error during startup: Unable to start the Phusion Passenger
logging agent: unable to read its startup information: Connection reset by peer
(104) (-1: Unknown error 18446744073709551615)
Stopping web server... done
# Run rake db:size to get a print of your database size in bytes.
# Run rake db:tables:size to get the sizes for individual tables
# Works for MySQL and PostgreSQL. Not tested elsewhere.
namespace :db do
desc 'Print data size for entire database'
task :size => :environment do
database_name = ActiveRecord::Base.connection.instance_variable_get("@config")[:database]
adapter = ActiveRecord::Base.connection.adapter_name.downcase