First time install and I'm getting the error below when I try to run rendered as render account.
My test box is smaller so I imported each US state one by one. Not sure if this has an effect or not.
Mapnik LOG> 2019-06-27 16:21:41: warning: unable to find face-name 'unifont Medium' in FontSet 'fontset-2'
renderd[22208]: An error occurred while loading the map layer 'ajt': Postgis Plugin: ERROR: permission denied for relation planet_osm_polygon
in executeQuery Full sql was: 'SELECT ST_SRID("way") AS srid FROM planet_osm_polygon WHERE "way" IS NOT NULL LIMIT 1;'
encountered during parsing of layer 'landcover-low-zoom' in Layer at line 755 of '/home/renderaccount/src/openstreetmap-carto/mapnik.xml'
renderd[22208]: An error occurred while loading the map layer 'ajt': Postgis Plugin: ERROR: permission denied for relation planet_osm_polygon
in executeQuery Full sql was: 'SELECT ST_SRID("way") AS srid FROM planet_osm_polygon WHERE "way" IS NOT NULL LIMIT 1;'
encountered during parsing of layer 'landcover-low-zoom' in Layer at line 755 of '/home/renderaccount/src/openstreetmap-carto/mapnik.xml'
asked
27 Jun '19, 17:39
chavenor1
11●4●4●6
accept rate:
0%
"permission denied for relation planet_osm_polygon" implies that the accounts used for part of the installation didn't match the account used for another part. I'm guessing that you're following https://switch2osm.org/manually-building-a-tile-server-18-04-lts/ , perhaps recheck what accoun you used for each part of that? Maybe you did some things as root and therefore can't access them as a non-root user?
What account should be used through that guide? Not sure it's clear if I should be root or renderaccount. Should I delete and re-install? Is rendered run by root or render account?
From memory, everything to be done as root has a "sudo" at the front, such as "sudo apt-get install ...". If you type in the commands as written, everything will work.
As written, the guide uses a Linux user account called "renderaccount" to run things like renderd from. The postgres side of things is handled at "ALTER TABLE geometry_columns OWNER TO renderaccount;" and the Linux system side at "sudo useradd -m renderaccount".
I'm usually logged in as root is that a problem? Or should I make renderaccount part of the sudo group? What account root or renderaccount or Postgres should this command be run at?
osm2pgsql -d gis --create --slim -G --hstore --tag-transform-script ~/src/openstreetmap-carto/openstreetmap-carto.lua -C 1000 --number-processes 1 -S ~/src/openstreetmap-carto/openstreetmap-carto.style ~/data/delaware-latest.osm.pbf
You have a Postgres user issue, not a Linux user one: they are separate things. Running 'psql -l' will tell us who owns your gis database.