← Back to team overview

openerp-india team mailing list archive

[Bug 944073] Re: v61 restore database broke

 

Hi, just tried again using postgreSQL 9.1.2 with the final source kit openerp-6.1-1
tried both web and gtk 

backup works fine, but restore gives:
2012-05-24 15:24:43,806 3812 INFO ? openerp.service.web_services: DUMP DB successful: sasBAOU
2012-05-24 15:24:44,080 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:24:44] "POST /web/database/backup HTTP/1.1" 200 -
2012-05-24 15:26:14,840 3812 WARNING test2 openerp.sql_db: __nonzero__() is deprecated. (It is too expensive to test a connection.)
2012-05-24 15:26:14,852 3812 ERROR test2 openerp.sql_db: Connection to the database failed
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/openerp-6.1_1-py2.6.egg/openerp/sql_db.py", line 421, in borrow
    result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
  File "/usr/lib/python2.6/site-packages/psycopg2/__init__.py", line 179, in connect
    connection_factory=connection_factory, async=async)
OperationalError: FATAL:  database "test2" does not exist

2012-05-24 15:26:15,735 3812 INFO template1 openerp.service.web_services: RESTORE DB: test2
2012-05-24 15:26:15,740 3812 INFO template1 werkzeug: 192.168.0.8 - - [24/May/2012 15:26:15] "POST /web/database/restore HTTP/1.1" 200 -
2012-05-24 15:26:23,952 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:23] "GET /web/webclient/home HTTP/1.1" 200 -
2012-05-24 15:26:24,070 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "GET /web/webclient/css HTTP/1.1" 304 -
2012-05-24 15:26:24,075 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "GET /web/webclient/js HTTP/1.1" 304 -
2012-05-24 15:26:24,534 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "POST /web/session/get_session_info HTTP/1.1" 200 -
2012-05-24 15:26:24,583 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "POST /web/webclient/qweblist HTTP/1.1" 200 -
2012-05-24 15:26:24,748 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "POST /web/proxy/load HTTP/1.1" 200 -
2012-05-24 15:26:24,907 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "POST /web/session/get_lang_list HTTP/1.1" 200 -
2012-05-24 15:26:24,928 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "GET /web/static/src/img/pattern.png HTTP/1.1" 304 -
2012-05-24 15:26:24,929 3812 INFO ? werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "GET /web/static/src/img/logo2.png HTTP/1.1" 304 -
2012-05-24 15:26:24,936 3812 INFO template1 werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "POST /web/database/get_list HTTP/1.1" 200 -
2012-05-24 15:26:24,946 3812 INFO template1 werkzeug: 192.168.0.8 - - [24/May/2012 15:26:24] "POST /web/database/get_list HTTP/1.1" 200 -
2012-05-24 15:26:30,754 3812 INFO test2 openerp.modules.loading: init db


and when opening the restored db, it's like a newly created one that
needs everying to be installed/configured again.


If I do a createdb and restoredb from the command line things work dandy.

I think the problem is clear now, openerp restore is having problems
with creation of the new db during the restore, the creation seems to
happen afterwards (during a failed restore).

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/944073

Title:
  v61 restore database broke

Status in OpenERP Server:
  Incomplete

Bug description:
  saved and tried to restore a database .. ( PostgreSQL 9.1.2 )
  save seems ok but restore is broke.

  here is the server output:
  2012-03-01 15:17:09,909 4345 INFO ? openerp: OpenERP version 6.1
  2012-03-01 15:17:09,909 4345 INFO ? openerp: addons paths: /home/richard/src/openerp/addons/6.1,/home/richard/src/openerp/web/6.1/addons
  2012-03-01 15:17:09,909 4345 INFO ? openerp: database hostname: localhost
  2012-03-01 15:17:09,909 4345 INFO ? openerp: database port: 5432
  2012-03-01 15:17:09,910 4345 INFO ? openerp: database user: richard
  2012-03-01 15:17:09,910 4345 INFO ? openerp.service.netrpc_server: starting NET-RPC service on 0.0.0.0:8070
  2012-03-01 15:17:09,911 4345 INFO ? openerp.netsvc: Starting 1 services
  2012-03-01 15:17:09,943 4345 INFO ? openerp.wsgi.core: HTTP service (werkzeug) running on 0.0.0.0:8069
  2012-03-01 15:17:10,258 4345 INFO ? openerp.addons.web: embedded mode
  2012-03-01 15:17:10,982 4345 INFO ? openerp: OpenERP server is running, waiting for connections...
  2012-03-01 15:17:25,398 4345 INFO ? werkzeug: 127.0.0.1 - - [01/Mar/2012 15:17:25] "GET /web/static/src/img/throbber2.gif HTTP/1.1" 304 -
  2012-03-01 15:17:25,809 4345 WARNING nouveau openerp.sql_db: __nonzero__() is deprecated. (It is too expensive to test a connection.)
  2012-03-01 15:17:25,816 4345 ERROR nouveau openerp.sql_db: Connection to the database failed
  Traceback (most recent call last):
    File "/home/richard/src/openerp/server/6.1/openerp/sql_db.py", line 421, in borrow
      result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
    File "/usr/lib/python2.6/site-packages/psycopg2/__init__.py", line 179, in connect
      connection_factory=connection_factory, async=async)
  OperationalError: FATAL:  database "nouveau" does not exist

  pg_restore: [archiver] WARNING: invalid creation date in header
  pg_restore: [archiver] entry ID -1297435727 out of range -- perhaps a corrupt TOC
  2012-03-01 15:17:26,489 4345 ERROR template1 openerp.netsvc: 32
  Pipe cassé
  2012-03-01 15:17:26,526 4345 INFO template1 werkzeug: 127.0.0.1 - - [01/Mar/2012 15:17:26] "POST /web/database/restore HTTP/1.1" 500 -
  2012-03-01 15:17:26,532 4345 ERROR template1 werkzeug: Error on request:
  Traceback (most recent call last):
    File "/usr/lib/python2.6/site-packages/Werkzeug-0.7-py2.6.egg/werkzeug/serving.py", line 159, in run_wsgi
      execute(app)
    File "/usr/lib/python2.6/site-packages/Werkzeug-0.7-py2.6.egg/werkzeug/serving.py", line 146, in execute
      application_iter = app(environ, start_response)
    File "/home/richard/src/openerp/server/6.1/openerp/wsgi/core.py", line 397, in application
      result = handler(environ, start_response)
    File "/home/richard/src/openerp/web/6.1/addons/web/common/http.py", line 467, in __call__
      return self.dispatch(environ, start_response)
    File "/usr/lib/python2.6/site-packages/Werkzeug-0.7-py2.6.egg/werkzeug/wsgi.py", line 409, in __call__
      return self.app(environ, start_response)
    File "/home/richard/src/openerp/web/6.1/addons/web/common/http.py", line 503, in dispatch
      response.set_cookie(self.session_cookie, session.sid)
    File "/usr/lib/python2.6/contextlib.py", line 34, in __exit__
      self.gen.throw(type, value, traceback)
    File "/home/richard/src/openerp/web/6.1/addons/web/common/http.py", line 353, in session_context
      yield request.session
    File "/home/richard/src/openerp/web/6.1/addons/web/common/http.py", line 494, in dispatch
      result = handler( request, self.config)
    File "/home/richard/src/openerp/web/6.1/addons/web/common/http.py", line 327, in http_handler
      return HttpRequest(request, config).dispatch(controller, f)
    File "/home/richard/src/openerp/web/6.1/addons/web/common/http.py", line 287, in dispatch
      _logger.debug("<-- size: %s", len(r))
  TypeError: object of type 'NoneType' has no len()

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/944073/+subscriptions


References