https://bugzilla.novell.com/show_bug.cgi?id=757094
https://bugzilla.novell.com/show_bug.cgi?id=757094#c6
--- Comment #6 from Donovan Cameron 2012-05-05 20:15:08 UTC ---
I have to create any new databases from scratch without a template and can then
successfully insert postgis and postgis_topology:
createdb postgis_new -O saultdon
psql postgis_new -c "CREATE EXTENSION postgis;"
psql postgis_new -c "CREATE EXTENSION postgis_topology;"
I believe now that this error is due to the ROLES or SCHEMA privileges...
I created a new role:
CREATE ROLE saultdon LOGIN CREATEDB;
As postgres user:
CREATE DATABASE template_postgis TEMPLATE template1;
CREATE EXTENSION postgis;
CREATE EXTENSION postgis_topology;
SELECT postgis_full_version(); # WORKS!
Now, here is the part where I am confused:
As postgres user, make a new database for ROLE saultdon from template:
CREATE DATABASE postgis_new TEMPLATE template_postgis OWNER saultdon;
As postgres user, postgis_full_version() for database postgis_new reports
everything normal. So that's nice!
When I access the postgis_new database from user saultdon:
SELECT postgis_full_version(); #ERROR!
NOTICE: Function postgis_topology_scripts_installed() not found. Is topology
support enabled and topology.sql installed?
CREATE EXTENSION postgis_topology; #ERROR!
ERROR: extension "postgis_topology" already exists
I am thinking this is because the database user saultdon has unprivileged
access to the 'topology schema'!
As user saultdon in database postgis_new:
postgis_new=> \dn
List of schemas
Name | Owner
----------+----------
gis | saultdon
public | postgres
topology | postgres
(3 rows)
I am not sure where to proceed from here, so I will most likely post in the
postgis mailing list for further troubleshooting as these errors are most
likely due to my lack of understanding in postgresql database administration.
--
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.