cancel
Showing results for 
Search instead for 
Did you mean: 

Restored PostgreSQL .sql Backup – Database Tables Exist but Alfresco Share Shows No Data

billybill07
Confirmed Champ
Confirmed Champ

 

Hello everyone,

I recently performed a backup and restore operation for an Alfresco Community instance and ran into an issue I can’t resolve. Here is what I did step-by-step:


Backup Process:

On the source server (Alfresco + PostgreSQL), I created a SQL dump using:

pg_dump -U alfresco -d alfresco > alfresco_backup.sql

Transfer to VM:

I copied the backup file to a clean Linux VM using:

scp alfresco_backup.sql user@vm-ip:/home/user/

Restore Process:

Inside the VM, I created a new PostgreSQL database, then restored the dump using:

psql -U alfresco -d alfresco < /home/user/alfresco_backup.sql

Note: I used the same database name and user credentials as the original instance.

Verification:

After the restore, I verified that the database contains the expected tables and data using:

docker exec -it <your-postgres-container> psql -U alfresco -d alfresco

Inside the PostgreSQL shell:

 

SELECT COUNT(*) FROM alf_node;
SELECT COUNT(*) FROM alf_authority;
SELECT COUNT(*) FROM alf_store;

These queries returned valid counts, indicating that the node metadata and authorities were restored.

Problem:

Even though the database seems to contain all the data (e.g., alf_node has thousands of rows), Alfresco Share shows no  folders, or users or aspects after starting the containers.

25 REPLIES 25

LeoMattioli
Employee
Employee

Hi, but you see no folder at all or just an empty repository with the out-of-the-box folders?

A couple of silly questions: are you sure you are connecting to the correct DB? Have you started the DB container before repository tomcat?

Any error in the alfresco.log during startup?


Leo Mattioli - Technical Account Manager @Hyland.

billybill07
Confirmed Champ
Confirmed Champ

Thanks for your reply.

Yes, I’m connected to the correct PostgreSQL database — I verified by checking tables like alf_node and alf_store, which contain valid data.

I restored the database using:

docker cp alfresco_backup.sql postgres-container:/tmp/
docker exec -it postgres-container psql -U alfresco -d alfresco -f /tmp/alfresco_backup.sql

Then I started all containers with docker compose up. No errors appear in the logs, but when I access Share, I only see the default folders (e.g., "Data Dictionary", "Guest Home"). None of the actual content or user-created folders are visible.

I suspect something is missing in the restore process — maybe related to contentstore or Solr?

Appreciate your help!

LeoMattioli
Employee
Employee

I think the restore has not really happened as intended, seems you see just an empty Alfresco. Do in the Alfresco.log you see the message:

INFO [domain.schema.SchemaBootstrap] [main] Creating Alfresco tables took xxx ms

Are the containers with postgresql and alfresco in the same docker network?

In any case Solr and contentstore are not involved when listing the repo from Share.


Leo Mattioli - Technical Account Manager @Hyland.

billybill07
Confirmed Champ
Confirmed Champ

I can confirm that the backup/restore process finally worked correctly when I used DBeaver to restore the database. I now see all the expected tables and data in the server-side database, which suggests the restore was successful.

However, after the restore, I'm unable to log into the Share platform. It returns the following error:

"Your authentication details haven't been recognized or Alfresco Content Services may not be available at this time."

At this point, do you still believe Solr is not involved in this behavior? If not, what could cause this login issue after a valid DB restore?

Appreciate your guidance on what to check next.

LeoMattioli
Employee
Employee

Solr is not involved during login. Search in the alfresco.log and the share.log for an ERROR or SEVERE.

That error usually means that Alfresco is not started. Try to connect to /alfresco instead of /share: do you see the admin page? This is an example for ACS 7.4.1, but you should have one similar

LeoMattioli_1-1747919719482.png

 

 


Leo Mattioli - Technical Account Manager @Hyland.

billybill07
Confirmed Champ
Confirmed Champ

All the containers (Alfresco, Share, Solr, and PostgreSQL) are started and running without issues. I can confirm that I am able to access the /alfresco endpoint and I do get an interface similar to the one in your screenshot when everything is working properly.

However, the problem begins immediately after I restore the database using DBeaver. The restore completes successfully — I can see all the tables and data clearly in DBeaver. But once I try to log in via /share or the Admin Console, I consistently get the following error:

"Your authentication details haven't been recognized or Alfresco Content Services may not be available at this time."

This error only happens after the database restore. Before the restore, the system is fully functional and I can log in and navigate Share and the admin panel without any issues.

So it seems that while the data is present in the database post-restore, Alfresco fails to authenticate users or complete the startup process properly. Could this indicate an issue with how identity, authority, or schema data is being restored or interpreted?

I’ve also searched both alfresco.log and share.log for any ERROR or SEVERE messages after the restore. If needed, I can provide the relevant log excerpts.

LeoMattioli
Employee
Employee

Hi billybill07, maybe another silly one from me: You can't restore the DB while Alfresco is running. First you restore the DB, then you switch on Alfresco and Share. Are you following that order?


Leo Mattioli - Technical Account Manager @Hyland.

Thanks again for your help — and not silly at all, your suggestion was very logical.

I made sure to follow the correct order this time: I stopped both the Alfresco and Share containers, performed the database restore using DBeaver, and then started the containers again. The database restore completes successfully, and I can confirm that all the data is correctly present in the external PostgreSQL database (verified via DBeaver).

However, after starting the containers and navigating to http://192.168.2.1:8080/share, the login still fails with the same error:

"Your authentication details haven't been recognized or Alfresco Content Services may not be available at this time."

I also tried accessing /alfresco, and I do see the admin page, which confirms that Alfresco is running.

To summarize:

  • All containers (alfresco, share, solr, external postgres) are up and running.

  • The data looks fine in the database.

  • The issue only occurs after performing the restore, even when done with Alfresco and Share fully stopped beforehand.

  • The logs don’t show any major SEVERE or ERROR

LeoMattioli
Employee
Employee

If Share stops working after the restore, maybe there's some configuration persisted in the DB. Connect to /alfresco Admin Console and open the "JMX Settings". If there is any configuration, that is taking precedence against your docker file. You can click "Revert" to remove it and fall back to alfresco-global.properties. 


Leo Mattioli - Technical Account Manager @Hyland.