Opened 12 years ago

Closed 12 years ago

#428 closed defect (invalid)

sudo -u goblinartists ./bin/gmg dbupdate returns sqlalchemy.exc.ProgrammingError: (ProgrammingError) exception

Reported by: Jorge Araya Navarro Owned by: Jorge Araya Navarro
Priority: critical Milestone:
Component: component1 Keywords: postgres, sqlalchemy
Cc: jorgean@… Parent Tickets:


I'm trying to deploy Postgres in my mediagoblin instance, but I have this problem.

[shackra@abrilhost mediagoblin]$ sudo -u goblinartists ./bin/gmg dbupdate
** Message: pygobject_register_sinkfunc is deprecated (GstObject)
/srv/http/ SAWarning: Unicode type received non-unicode bind param value.
Traceback (most recent call last):
  File "./bin/gmg", line 8, in <module>
    load_entry_point('', 'console_scripts', 'gmg')()
  File "/srv/http/", line 100, in main_cli
  File "/srv/http/", line 93, in dbupdate
  File "/srv/http/", line 88, in run_dbupdate
  File "/srv/http/", line 196, in init_or_migrate
    migration_number = self.database_current_migration
  File "/srv/http/", line 104, in database_current_migration
    if self.migration_data is None:
  File "/srv/http/", line 80, in migration_data
  File "build/bdist.linux-x86_64/egg/sqlalchemy/orm/", line 2107, in first
  File "build/bdist.linux-x86_64/egg/sqlalchemy/orm/", line 2001, in __getitem__
  File "build/bdist.linux-x86_64/egg/sqlalchemy/orm/", line 2176, in __iter__
  File "build/bdist.linux-x86_64/egg/sqlalchemy/orm/", line 2191, in _execute_and_instances
  File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/", line 1450, in execute
  File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/", line 1583, in _execute_clauseelement
  File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/", line 1697, in _execute_context
  File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/", line 1690, in _execute_context
  File "build/bdist.linux-x86_64/egg/sqlalchemy/engine/", line 335, in do_execute
sqlalchemy.exc.ProgrammingError: (ProgrammingError) permission denied for relation core__migrations
 'SELECT AS core__migrations_name, core__migrations.version AS core__migrations_version \nFROM core__migrations \nWHERE = %(name_1)s \n LIMIT %(param_1)s' {'name_1': '__main__', 'param_1': 1}
[shackra@abrilhost mediagoblin]$

this could be a bug?

Change History (2)

comment:1 by Jorge Araya Navarro, 12 years ago

more info about the database

mediagoblin-# \du
                               List of roles
   Role name   |                   Attributes                   | Member of 
 goblinartists |                                                | {}
 mediagoblin   |                                                | {}
 postgres      | Superuser, Create role, Create DB, Replication | {}

mediagoblin-# \dt
                 List of relations
 Schema |          Name          | Type  |  Owner   
 public | ascii__mediadata       | table | postgres
 public | core__attachment_files | table | postgres
 public | core__file_keynames    | table | postgres
 public | core__media_comments   | table | postgres
 public | core__media_entries    | table | postgres
 public | core__media_tags       | table | postgres
 public | core__mediafiles       | table | postgres
 public | core__migrations       | table | postgres
 public | core__tags             | table | postgres
 public | core__users            | table | postgres
 public | image__mediadata       | table | postgres
 public | video__mediadata       | table | postgres
(12 rows)


Last edited 12 years ago by Jorge Araya Navarro (previous) (diff)

comment:2 by Jorge Araya Navarro, 12 years ago

Resolution: invalid
Status: newclosed

just be careful and create everything (database and schemas) under the same user which is going to run the MediaGoblin instance

Note: See TracTickets for help on using tickets.