How to use PostGIS without being a superuser

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

How to use PostGIS without being a superuser

Christopher BROWN
Hello,

I've tried finding the solution on my own, but have been unable to
understand (from PostGIS and PostgreSQL documentation, and from web
searches).  Basically, no problem installing or using PostGIS with a
superuser account (not the "postgres" user however), but can't event
run select postgis_full_version(); in some cases as a "normal" user.

In one case, the DBA ran the "create extension postgis" command as the
"postgres" superuser, but although the "normal" user could create
tables with default PostgreSQL types, impossible to create anything
like a geometry or geography column (permissions error: type
"geography" doesn't exist).

Unless I've been looking in the wrong places (not impossible), the
guides quickly run through the installation steps without going into
detail.  I'd like to understand how to do this without resorting to
the superuser, and without blindy running random commands from
different forums.

I'm using PostgreSQL 9.6.1 with PostGIS 2.3.1 from ppa repositories on
Ubuntu 14.04 LTS.

Thanks in advance.

--
Christopher
_______________________________________________
postgis-users mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-users
Reply | Threaded
Open this post in threaded view
|

Re: How to use PostGIS without being a superuser

Christopher BROWN
Hello,

Problem seems solved, mainly by reinstalling.  After that, just needed to be PostgreSQL "superuser" to run CREATE EXTENSION, and after that, no other permission problems with normal user (as long as superuser ran the CREATE EXTENSION command with the search_path set to the target schema in the target database).

--
Christopher


On 10 January 2017 at 20:11, Christopher BROWN <[hidden email]> wrote:
Hello,

I've tried finding the solution on my own, but have been unable to
understand (from PostGIS and PostgreSQL documentation, and from web
searches).  Basically, no problem installing or using PostGIS with a
superuser account (not the "postgres" user however), but can't event
run select postgis_full_version(); in some cases as a "normal" user.

In one case, the DBA ran the "create extension postgis" command as the
"postgres" superuser, but although the "normal" user could create
tables with default PostgreSQL types, impossible to create anything
like a geometry or geography column (permissions error: type
"geography" doesn't exist).

Unless I've been looking in the wrong places (not impossible), the
guides quickly run through the installation steps without going into
detail.  I'd like to understand how to do this without resorting to
the superuser, and without blindy running random commands from
different forums.

I'm using PostgreSQL 9.6.1 with PostGIS 2.3.1 from ppa repositories on
Ubuntu 14.04 LTS.

Thanks in advance.

--
Christopher


_______________________________________________
postgis-users mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/postgis-users