Sometimes for some unknown reason alfresco crashes after I upload some documents. To be able to work with alfresco again each time this happens I need to reinstall alfresco which takes quite a long time. But basically what I want to do is to wipe alfresco database. To do it I’ve created a following script:
Here are some explanations.
First thing you need to do is to stop alfresco just to be sure that it’s not running:
Then start postgres and recreate database by dropping it and create. Be sure that the proper user owns the database you create. You can also keep the table and just drop all the tables in it. But first method works better. And then stop postgres.