Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
3 Răspunsuri
14128 Vizualizări

 Hi Community,

I get this "500 Internal Server Error", can anyone please help to find out how to solve this issue ?
Thanks
 

Odoo

Odoo Server Error

Traceback (most recent call last):
  File "/opt/odoo/odoo/openerp/http.py", line 539, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/opt/odoo/odoo/openerp/http.py", line 576, in dispatch
    result = self._call_function(**self.params)
  File "/opt/odoo/odoo/openerp/http.py", line 312, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/opt/odoo/odoo/openerp/service/model.py", line 118, in wrapper
    return f(dbname, *args, **kwargs)
  File "/opt/odoo/odoo/openerp/http.py", line 309, in checked_call
    return self.endpoint(*a, **kw)
  File "/opt/odoo/odoo/openerp/http.py", line 805, in __call__
    return self.method(*args, **kw)
  File "/opt/odoo/odoo/openerp/http.py", line 405, in response_wrap
    response = f(*args, **kw)
  File "/opt/odoo/odoo/addons/web/controllers/main.py", line 944, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/opt/odoo/odoo/addons/web/controllers/main.py", line 936, in _call_kw
    return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/werkzeug/local.py", line 338, in __getattr__
    return getattr(self._get_current_object(), name)
  File "/opt/odoo/odoo/openerp/http.py", line 248, in cr
    self._cr = self.registry.cursor()
  File "/opt/odoo/odoo/openerp/modules/registry.py", line 272, in cursor
    return self._db.cursor()
  File "/opt/odoo/odoo/openerp/sql_db.py", line 609, in cursor
    return Cursor(self.__pool, self.dbname, self.dsn, serialized=serialized)
  File "/opt/odoo/odoo/openerp/sql_db.py", line 181, in __init__
    self._cnx = pool.borrow(dsn)
  File "/opt/odoo/odoo/openerp/sql_db.py", line 498, in _locked
    return fun(self, *args, **kwargs)
  File "/opt/odoo/odoo/openerp/sql_db.py", line 560, in borrow
    result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
  File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 179, in connect
    connection_factory=connection_factory, async=async)
OperationalError: FATAL:  remaining connection slots are reserved for non-replication superuser connections
Imagine profil
Abandonează
Cel mai bun răspuns

The problem is on your postgres max_connections limit... You need to increase that value and restart the server. It'll work.

If you are on Ubuntu: /etc/postgresql/9.x/main/postgresql.conf

Imagine profil
Abandonează
Cel mai bun răspuns

For now just restart your PostgreSQL which will close the all active connection 
For permanent solution You either need to increase the max_connections

 configuration setting or (probably better)  use connection polling  (PgBouncer and Pgpool) to route a large number of user requests through a smaller connection pool.

Imagine profil
Abandonează
Autor Cel mai bun răspuns

Hi Guys,

thank you for your reply. I'm running odoo on Ubuntu server in the cloud: 2 GB Memory / 2 CPUs / 40 GB SSD Disk. We are 10 users.

I have edit default installation postgresql.conf file as follow and this has generated the problem:

max_connections = 15

shared_buffers = 512MB

effective_cache_size = 1024MB

checkpoint_segments = 10

checkpoint_completion_target = 0.9

work_mem = 8MB

maintenance_work_mem = 32MB 

I will now change max_connections to 30 and let me ask you, the other configuration you see above do you think they are correct ?

Thank you


Imagine profil
Abandonează

According to the forum guidelines please do not add another question in the answer section but please post a new question.

Related Posts Răspunsuri Vizualizări Activitate
0
oct. 23
4770
1
mai 25
2204
0
oct. 15
3904
2
feb. 16
4835
2
mar. 15
6569