Running any query that updates the catalog ( say "grant" for example ) errors out with
ERROR: tuple concurrently updated (heapam.c:3210)
As indicated by the error message , when you ran the query some one else was concurrently updating the same tuple , this can be easily reproduced with below steps.
- open two terminals
- run the below script on both of them
while true; do psql -c 'grant all on <tablename> to <rolename>'; done
- Please try the query again after a few seconds.
- Wait for another time when the database is free to run the query.