This release adds PostgreSQL support for the vRAM service. PostgreSQL is a much better storage medium for this data because the integrity of the vRAM data is validated on chain. Postgres is scalable, has high integrity for not losing data, is easy to setup, and should fix the issues some have been having with lost IPFS data.

Unfortunately, it does not appear that this update will speed up the vRAM fetch/post process, but I'm happy with the integrity and scaling potential. Data is also stored in the IPFS node to still allow p2p sharing via swarm peers and/or the broader IPFS network.

As a DSP operator to use the new PostgreSQL feature, you'll need to first get a list of all accounts staked to the vRAM service for your DSP, you can use for this. Then you can set the following variables in your toml file and restart the DSP to begin replaying. You need to reset allow_api_non_broadcast and postgresql_force_replay to false after to avoid security issues, specifically related to CPU drain attacks and to also allow fetching from cache.

under [dsp] section

allow_api_non_broadcast = true

under [ipfs] section

postgresql = true postgresql_force_replay = true

After running setup-dsp you can replay each account by following the directions here:


  • updated zeus test flags, added --ipfs-postgres flag, PostgreSQL db must be run locally and manually, there is an install script provided to install go 1.19.4

  • updated DSP install guide to include section on installing Go dependencies and Go server for handling PostgreSQL data add/get

  • updated replay script to include new env var for bypassing DSP cache to force storing new data export IPFS_POSTGRESQL_FORCE_REPLAY=true

  • added section to PostgreSQL install instructions for creating blocks table and text_pattern_ops index

  • added section to PostgreSQL for setting up systemd process for go server process

  • added flag --ipfs-postgres to allow testing the feature locally, requires setting up your own local PostgreSQL instance configured to postgresql://postgres:password@localhost:5432/postgres

  • add start-localenv step to run 15-ipfs-ds-postgres if above flag set

  • added script to install go and dependencies at zeus/boxes/groups/microservices/ipfs-ds-postgres/scripts/

  • added new params to config.toml postgresql = true to enable feature

  • added postgresql_port = 8090 to set port at which go IPFS PostgreSQL instance is running

dappservices contract

DSP Services:

Last updated