-
Hi, I did two upgrades recently (Citus 11.1 -> 11.2, then PG 14 -> 15). The database works mostly normally but I experience a strange behaviour with some queries. While this one works: SELECT get_shard_id_for_distribution_column('my_table', 8);
get_shard_id_for_distribution_column
--------------------------------------
102008
(1 row) Using it in a larger query fails: SELECT get_shard_id_for_distribution_column('my_table', id), id FROM my_table ORDER BY id DESC LIMIT 10;
ERROR: relation is not distributed
CONTEXT: while executing command on worker-a:6006 Connecting to the worker directly, I can see all the tables from metadata as well as the shard tables (e.g. Where can I look further to figure out what's wrong? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Today, I hit another error while trying to add nodes to the Citus cluster. I can't rebalance shards because I hit:
|
Beta Was this translation helpful? Give feedback.
-
OK, so the issue was that I misread the PostgreSQL upgrade instructions and ran This is how I fixed it:
|
Beta Was this translation helpful? Give feedback.
OK, so the issue was that I misread the PostgreSQL upgrade instructions and ran
citus_prepare_pg_upgrade()
only on the coordinator node. This resulted in emptypg_dist_...
tables.This is how I fixed it:
Restore all workers to a point just before upgrade.
Run
SELECT citus_prepare_pg_upgrade()
on each restored node.Create a fixup script (on each restored node).