[ome-users] Recovering omero with a slightly out of data postgres dump?

Josh Moore josh at glencoesoftware.com
Thu Sep 25 11:58:13 BST 2014


On Sep 24, 2014, at 9:51 PM, Jake Carroll wrote:

> Hi all,

Hi Jake,

> A simple question this morning. Hopefully a simple answer ;).
> 
> The platform I was running my OMERO stack on last night suffered a failure.
> 
> 1. My omero config is current and backed up.
> 2. My omero binary data store is current and backed up.
> 3. My omero postgres DB is about 1.5 days old - but backed up.
> 
> What do I need to do to “put humpty back together again” such that it is consistent for end users?

Assuming you keep the backups safe, there's not too terribly much to do other than turn it all back on again and kick the tires.

You can run:

  bin/omero admin cleanse --dry-run /OMERO

to see which files are present in your data directory which the PostgreSQL DB doesn't know about.
This will point to anything that you might want to delete from the DB manually.

This doesn't yet take imports into account imports, unfortunately. To see if there are any filesets which need to be reimported, you can list the last imports by date:

 $ bin/omero fs sets 

 #  | Id    | Prefix                                        | Images | Files | Transfer 
----+-------+-----------------------------------------------+--------+-------+----------
 0  | 83053 | XXXXXXXXXXXXXXXXX_52/2014-09/25/11-44-35.090/ | 3      | 1     |      
...

Depending on what's present in that output, you may well need to re-import some of the filesets. This shows that the last registered import was at 11:44 today. To find the directories which were created roughly since then use:

find /OMERO/ManagedRepository/ -mindepth 4 -maxdepth 4 -type d -ctime -1
/OMERO/ManagedRepository/XXXXXXXXXXXXXXXXX_52/2014-09/25/11-44-35.090
/OMERO/ManagedRepository/XXXXXXXXXXXXXXXXX_52/2014-09/25/11-44-16.174
/OMERO/ManagedRepository/XXXXXXXXXXXXXXXXX_52/2014-09/25/11-43-45.692

Here -1 means "within the last 1 day".

Another fairly sensitive piece of the puzzle is the indexer. You might check var/log/Indexer-0.log to make sure that it is running smoothly, since the backup could have left a lock file in place. A glance at bin/omero admin diagnostics would also be a good idea.

Hope the recovery goes well!

> http://www.openmicroscopy.org/site/support/omero5/sysadmins/server-backup-and-restore.html
> 
> This doesn’t really tell me in detail about my scenario 3/part 3 issue with the fact that it is a couple of days old.

Understood. We'll try to clarify the docs. Thanks for pointing it out.

> Thank you.
> -jc

Cheers,
~Josh




More information about the ome-users mailing list