@avdp what filesystem did you bind /ps/tmp
and /ps/library
to?
Make sure /ps/tmp
is a fast local disk (SSD would be great).
If /ps/library
is a local filesystem (either an SSD or HDD), you can skip the whole “support SQLite on remote filesystems” codepaths by setting the environment variable PS_FORCE_LOCAL_DB_REPLICA=false
. This reduces the number of moving db parts dramatically.
I’d nuke the /ps/library/.photostructure
directory and re-import from scratch, btw: if key constraints are failing, assume the other database rows are garbage/invalid.