Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

AuthenticationError: Authentication failure with Zato 2.0.7 and Odoo

By
rafal
on 2/10/16, 8:11 AM 479 views

I'm trying to create an outgoing Odoo connection with Zato:

https://zato.io/docs/web-admin/outgoing/odoo.html

but I'm repeatedly getting "AuthenticationError: Authentication failure".

Whole procedure:

Ubuntu 14.04 64-bit Vagrant box

Zato 2.0.7

Odoo 9.0c.20160209

1. in the box with PostgreSQL and Zato already installed and set up, I install Odoo

2. I create 'test_odoo' database with owner 'odoo' and set password to the db to 'test'

3. I change settings in /etc/odoo/openerp-server.conf  to:

db_host = localhost

db_port = 5432

db_user = odoo

db_password = test

4. in Zato web-admin I create an outgoing Odoo connection (see the link to Zato docs above) passing the following parameters:

Host: localhost

Port: 8069

User: odoo

Database: test_odoo

Full traceback:

"""

2016-02-10 08:08:47,504 - ERROR - 5063:MainThread - zato.admin.web.views:470 - Could not ping the Odoo connection, e:[Traceback (most recent call last):

File "/home/vagrant/zato/code/zato-web-admin/src/zato/admin/web/views/__init__.py", line 463, in id_only_service

result = req.zato.client.invoke(service, {'id': id})

File "/home/vagrant/zato/code/zato-web-admin/src/zato/admin/middleware.py", line 72, in invoke

raise Exception('CID: {}\nDetails: {}'.format(zato_env.get('cid'), zato_env.get('details')))

Exception: CID: K072CD3XDCM3AT3NXM0GZT9W01PS

Details: Traceback (most recent call last):

File "/home/vagrant/zato/code/zato-server/src/zato/server/connection/http_soap/channel.py", line 198, in dispatch

payload, worker_store, self.simple_io_config, post_data)

File "/home/vagrant/zato/code/zato-server/src/zato/server/connection/http_soap/channel.py", line 350, in handle

params_priority=channel_item.params_pri)

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 401, in update_handle

self._invoke(service, channel)

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 344, in _invoke

service.handle()

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/internal/service.py", line 271, in handle

response = func(id_, payload, channel, data_format, transport, serialize=True)

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 499, in invoke

return self.invoke_by_impl_name(self.server.service_store.name_to_impl_name[name], *args, **kwargs)

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 483, in invoke_by_impl_name

return self.update_handle(*invoke_args, **kwargs)

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 428, in update_handle

raise Exception(exc_formatted)

Exception: Traceback (most recent call last):

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 401, in update_handle

self._invoke(service, channel)

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/__init__.py", line 344, in _invoke

service.handle()

File "/home/vagrant/zato/code/zato-server/src/zato/server/service/internal/outgoing/odoo.py", line 84, in handle

ping_odoo(client)

File "/home/vagrant/zato/code/zato-common/src/zato/common/util.py", line 1002, in ping_odoo

ids = user_model.search([('login', '=', conn.login)])

File "/home/vagrant/zato/code/eggs/openerp_client_lib-1.1.2-py2.7.egg/openerplib/main.py", line 305, in proxy

self.connection.check_login(False)

File "/home/vagrant/zato/code/eggs/openerp_client_lib-1.1.2-py2.7.egg/openerplib/main.py", line 245, in check_login

raise AuthenticationError("Authentication failure")

AuthenticationError: Authentication failure

]

"""


Am I missing something?

Hello @Axel Mendoza,

Thank you for your answer. Could you explain, please, what do you mean by creating the user odoo *in* test_odoo database?

rafal
on 2/11/16, 7:15 AM

You can set up multiple databases in Odoo. Therefore Axel means to login to your Odoo instance with the database test_odoo, there you create the user odoo.

Ermin Trevisan
on 2/11/16, 9:27 AM

Yes, this is what I eventually did. I was trying to achieve results via CLI, but gave up and used Odoo GUI. Thank you, Ermin.

rafal
on 2/11/16, 2:29 PM
1

Axel Mendoza

--Axel Mendoza--
10228
| 7 7 8
Camaguey, Cuba
--Axel Mendoza--

DevOps - Full stack - Software Architect - Developer - Technology Integrator

I could help you to develop anything and solve complex problems based on technologies, integrations and tricky stuffs mostly in Python with OpenERP/Odoo, Zato, Django and many others frameworks programming languages and technologies.

I offers consulting services to anyone with an unanswered questions or needs for customizations. Think about it, maybe it's better to have an expert to solve your issues and projects than having a full time employee trying to understand what to do an how

Reach me at aekroft@gmail.com

Axel Mendoza
On 2/10/16, 9:48 AM

Hi @rafal

Zato will not use a db user to connect to Odoo, it uses an Odoo user to connect using xmlrpc. So you need to create the user odoo in your Odoo database test_odoo to be able to use it in Zato. Also you need to set the password for the user odoo in Zato before you create it.

That's all, you will be able to connect. 

Enjoy both of those great awesome software.

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 2/10/16, 8:11 AM
Seen: 479 times
Last updated: 2/11/16, 2:29 PM