pg_restore is slow after creating index "public.activities_visibility_index"
Follow-up to #3030 (closed).
I've moved to another server before and the restore process was fast.
Today I want to restore from an archive file that is less than 200MB:
sudo -Hu postgres pg_restore -d pleroma -v -1 /var/lib/postgresql/pleroma.pgdump
At first, everything worked fine, but after the creation of index "public.activities_visibility_index", hours passed and no new messages appeared.
Full log: pg_restore.txt
I don't understand what pg_restore is doing, and from the log file it looks like it's restoring the activities table, but it's stuck.