Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Run the metadata report

# ssh to the prod machine as deploy user

$ cd /opt/sufia-project/current

$ bundle exec rake chf:metadata_report RAILS_ENV=production

Restart passenger without restarting apache

...

Note: If Reindexing due to a server move, import the Postgres database of users prior to reindexing. Otherwise you will need to reindex again once the users have been moved over.

 


Delete all the data

(Don't do this on prod!)

...

$ bundle exec rails c[onsole] production
# Or if you use my dev box, mess around on a development instance with just $bundle exec rails c
# Get a count of users
> User.all.count
# List all users (you can also work with users directly in pgsql)
> User.find_each { |u| p u.email } 
# Get a count of files
> GenericFile.all.count
# Inspect a file
> f = GenericFile.find(id='3b5918567')
> f.depositor
> f.filename
# etc.

...


State File

The state file (formerly in /tmp) has been moved to /var/sufia. It is currently being backed up nightly. It must be included in any server migrations to avoid generating errors when uploading (a new state file may try to use an already used fedora ID).