Recently I was speaking with other instance operators and one was a single-user instance operator that stated that they find that running pgsql with RUM indices allowed for fast searching.
I thought to give it a try as well, so I tried to upgrade my existing instance to run with RUM indices but when running the migrate command, I get the following error:
su akkoma -s $SHELL -lc "./bin/pleroma_ctl migrate --migrations-path priv/repo/optional_migrations/rum_indexing/"
23:23:50.835 [info] == Running 20190510135645 Pleroma.Repo.Migrations.AddFtsIndexToObjectsTwo.up/0 forward
23:23:50.838 [info] execute "create extension if not exists rum"
** (Postgrex.Error) ERROR 42501 (insufficient_privilege) permission denied to create extension "rum"
hint: Must be superuser to create this extension.
(ecto_sql 3.9.1) lib/ecto/adapters/sql.ex:913: Ecto.Adapters.SQL.raise_sql_call_error/1
(elixir 1.14.2) lib/enum.ex:1658: Enum."-map/2-lists^map/1-0-"/2
(ecto_sql 3.9.1) lib/ecto/adapters/sql.ex:1005: Ecto.Adapters.SQL.execute_ddl/4
(ecto_sql 3.9.1) lib/ecto/migration/runner.ex:326: Ecto.Migration.Runner.log_and_execute_ddl/3
(ecto_sql 3.9.1) lib/ecto/migration/runner.ex:117: anonymous fn/6 in Ecto.Migration.Runner.flush/0
(elixir 1.14.2) lib/enum.ex:2468: Enum."-reduce/3-lists^foldl/2-0-"/3
(ecto_sql 3.9.1) lib/ecto/migration/runner.ex:116: Ecto.Migration.Runner.flush/0
nofile:1: (file)
Sounds like there’s a permission error, not sure if it’s wise to run this command as root to get around this. Didn’t want to do the wrong thing here and mess up my Akkoma instance.
Was wondering if anyone knows how best to proceed, any assistance is much appreciated!
After reading up on RUM just now I think using these indices requires specific queries, CREATE INDEX tsts_idx ON tsts USING rum…
Does Akkoma automatically use such queries if RUM is enabled?