Getting the Ident authentication failed for user "openerp"

Asked by Bushair

Hi,

I have installed the openerp 6.0.3 in Cent OS

I started postgres and when i start openerp-server am getting below error

[openerp@erpserver ~]$ openerp-server
[2012-02-25 18:47:00,931][?] INFO:server:OpenERP version - 6.0.3
[2012-02-25 18:47:00,931][?] INFO:server:addons_path - /usr/lib/python2.6/site-packages/openerp-server/addons
[2012-02-25 18:47:00,931][?] INFO:server:database hostname - localhost
[2012-02-25 18:47:00,931][?] INFO:server:database port - 5432
[2012-02-25 18:47:00,932][?] INFO:server:database user - openerp
[2012-02-25 18:47:00,932][?] INFO:server:initialising distributed objects services
[2012-02-25 18:47:01,553][?] INFO:web-services:starting HTTP service at 0.0.0.0 port 8069
[2012-02-25 18:47:01,938][?] INFO:web-services:starting HTTPS service at 0.0.0.0 port 8071
[2012-02-25 18:47:01,939][?] INFO:web-services:Registered XML-RPC over HTTP
[2012-02-25 18:47:01,940][?] INFO:web-services:starting NET-RPC service at 0.0.0.0 port 8070
[2012-02-25 18:47:01,945][openerp] ERROR:db.connection_pool:Connection to the database failed
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/openerp-server/sql_db.py", line 303, in borrow
    result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
OperationalError: FATAL: Ident authentication failed for user "openerp"

Traceback (most recent call last):
  File "./openerp-server.py", line 121, in <module>
    db,pool = pooler.get_db_and_pool(dbname, update_module=tools.config['init'] or tools.config['update'], pooljobs=False)
  File "/usr/lib/python2.6/site-packages/openerp-server/pooler.py", line 39, in get_db_and_pool
    addons.load_modules(db, force_demo, status, update_module)
  File "/usr/lib/python2.6/site-packages/openerp-server/addons/__init__.py", line 803, in load_modules
    cr = db.cursor()
  File "/usr/lib/python2.6/site-packages/openerp-server/sql_db.py", line 345, in cursor
    return Cursor(self._pool, self.dbname, serialized=serialized)
  File "/usr/lib/python2.6/site-packages/openerp-server/sql_db.py", line 95, in __init__
    self._cnx = pool.borrow(dsn(dbname))
  File "/usr/lib/python2.6/site-packages/openerp-server/sql_db.py", line 252, in _locked
    return fun(self, *args, **kwargs)
  File "/usr/lib/python2.6/site-packages/openerp-server/sql_db.py", line 303, in borrow
    result = psycopg2.connect(dsn=dsn, connection_factory=PsycoConnection)
psycopg2.OperationalError: FATAL: Ident authentication failed for user "openerp"

My pg_hba.conf file contents are

local all all trust
host all all 127.0.0.1/32 trust
host all all ::1/128 ident

i tried with

local all all trust
host all all 127.0.0.1/32 md5
host all all ::1/128 ident

but getting the same error...

Can anyone have a look into this issue ?

|Regards
\Bushair

Question information

Language:
English Edit question
Status:
Answered
For:
Odoo Server (MOVED TO GITHUB) Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Serpent Consulting Services (serpent-consulting-services) said :
#1

Hello Bushair,

Try this:

# su - postgres
> createuser --createdb --no-createrole --pwprompt openerp

Hope it helps.

Regards,
Serpent Consulting Services.

Revision history for this message
Bushair (bushairka) said :
#2

Hi,
Thanks for your mail..

i tried this , but no luck....

looks like the issue is in pg_hba.conf file....Can you please have a look into this file which is mentioned above ?

My pg_hba.conf file contents are

local all all trust
host all all 127.0.0.1/32 trust
host all all ::1/128 ident

i tried with the below also...but no luck

local all all trust
host all all 127.0.0.1/32 md5
host all all ::1/128 ident

Revision history for this message
Mantavya Gajjar (Open ERP) (mga) said :
#3

This can be solved by creating "openerp" as a role in postgres
you can do it as follow

$ sudo su postgres
$ createuser openerp
Shall the new role be a superuser? (y/n) y

Now you can use it as it is "$ openerp-server"

Revision history for this message
Jignesh Rathod(OpenERP) (jir-openerp) said :
#4

Hello Bushair,

1) Goto root directory
2) Press Ctrl+h
3) Remove File .openerp_serverrc

Maybe this can solve your problem.

Revision history for this message
priyanka saha (priyanka-u) said :
#5

[2012-06-24 11:30:31,854][?] INFO:server:OpenERP version - 6.0.2
[2012-06-24 11:30:31,854][?] INFO:server:addons_path - /workspace/openerp/addons
[2012-06-24 11:30:31,854][?] INFO:server:database hostname - localhost
[2012-06-24 11:30:31,854][?] INFO:server:database port - 5432
[2012-06-24 11:30:31,854][?] INFO:server:database user - root
[2012-06-24 11:30:31,854][?] INFO:server:initialising distributed objects services
[2012-06-24 11:30:32,077][?] INFO:web-services:starting HTTP service at 0.0.0.0 port 8069
[2012-06-24 11:30:32,077][?] INFO:web-services:starting HTTPS service at 0.0.0.0 port 8071
[2012-06-24 11:30:32,077][?] INFO:web-services:Registered XML-RPC over HTTP
[2012-06-24 11:30:32,078][?] INFO:web-services:starting NET-RPC service at 0.0.0.0 port 8070
[2012-06-24 11:30:32,078][?] INFO:server:Starting 3 services
[2012-06-24 11:30:32,079][?] INFO:server:OpenERP server is running, waiting for connections...
[2012-06-24 11:35:27,617][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:38,702][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:43,643][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:46,092][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:52,739][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,219][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,633][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,844][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:01,703][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:10,307][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:11,154][?] ERROR:http:code 404, message Path not found: /

Revision history for this message
priyanka saha (priyanka-u) said :
#6

I have tried to install OpenERP version - 6.0.2.Downloaded the source code and run it from eclipse using PyDev.server is running it is shown.But whenever i am trying to run localhost:8069 in browser then it is not responding and gives errors.errors are given below:-

[2012-06-24 11:30:31,854][?] INFO:server:OpenERP version - 6.0.2
[2012-06-24 11:30:31,854][?] INFO:server:addons_path - /workspace/openerp/addons
[2012-06-24 11:30:31,854][?] INFO:server:database hostname - localhost
[2012-06-24 11:30:31,854][?] INFO:server:database port - 5432
[2012-06-24 11:30:31,854][?] INFO:server:database user - root
[2012-06-24 11:30:31,854][?] INFO:server:initialising distributed objects services
[2012-06-24 11:30:32,077][?] INFO:web-services:starting HTTP service at 0.0.0.0 port 8069
[2012-06-24 11:30:32,077][?] INFO:web-services:starting HTTPS service at 0.0.0.0 port 8071
[2012-06-24 11:30:32,077][?] INFO:web-services:Registered XML-RPC over HTTP
[2012-06-24 11:30:32,078][?] INFO:web-services:starting NET-RPC service at 0.0.0.0 port 8070
[2012-06-24 11:30:32,078][?] INFO:server:Starting 3 services
[2012-06-24 11:30:32,079][?] INFO:server:OpenERP server is running, waiting for connections...
[2012-06-24 11:35:27,617][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:38,702][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:43,643][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:46,092][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:52,739][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,219][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,633][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,844][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:01,703][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:10,307][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:11,154][?] ERROR:http:code 404, message Path not found: /

plz give me solution if possible

Revision history for this message
priyanka saha (priyanka-u) said :
#7

I have tried to install OpenERP version - 6.0.2.Downloaded the source code and run it from eclipse using PyDev.server is running it is shown.But whenever i am trying to run localhost:8069 in browser then it is not responding and gives errors.errors are given below:-

[2012-06-24 11:30:31,854][?] INFO:server:OpenERP version - 6.0.2
[2012-06-24 11:30:31,854][?] INFO:server:addons_path - /workspace/openerp/addons
[2012-06-24 11:30:31,854][?] INFO:server:database hostname - localhost
[2012-06-24 11:30:31,854][?] INFO:server:database port - 5432
[2012-06-24 11:30:31,854][?] INFO:server:database user - root
[2012-06-24 11:30:31,854][?] INFO:server:initialising distributed objects services
[2012-06-24 11:30:32,077][?] INFO:web-services:starting HTTP service at 0.0.0.0 port 8069
[2012-06-24 11:30:32,077][?] INFO:web-services:starting HTTPS service at 0.0.0.0 port 8071
[2012-06-24 11:30:32,077][?] INFO:web-services:Registered XML-RPC over HTTP
[2012-06-24 11:30:32,078][?] INFO:web-services:starting NET-RPC service at 0.0.0.0 port 8070
[2012-06-24 11:30:32,078][?] INFO:server:Starting 3 services
[2012-06-24 11:30:32,079][?] INFO:server:OpenERP server is running, waiting for connections...
[2012-06-24 11:35:27,617][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:38,702][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:43,643][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:46,092][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:52,739][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,219][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,633][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:35:53,844][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:01,703][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:10,307][?] ERROR:http:code 404, message Path not found: /
[2012-06-24 11:36:11,154][?] ERROR:http:code 404, message Path not found: /

Revision history for this message
Serpent Consulting Services (serpent-consulting-services) said :
#8

Priyanka,

Did you mean you did not run server from terminal?

Also, did you start the OpenERP Web too?

Thanks.

Revision history for this message
priyanka saha (priyanka-u) said :
#9

Thanks for response.from terminal i am able to run the server.But from browser i couldn't run.i m giving http://localhost:8069/

then following lines are shown.these are:-
Error response

Error code 404.

Message: Path not found: /.

Error code explanation: 404 = Nothing matches the given URI.

From eclipse server also run as a PyDev project using openerp source code.There is also same problem

Plz give me a solution.

Revision history for this message
Serpent Consulting Services (serpent-consulting-services) said :
#10

Priyanka,

The question still says : Did you start openerp web too from terminal?

Thanks.

Revision history for this message
priyanka saha (priyanka-u) said :
#11

i couldn't run openerp web from terminal.

regards
Priyanka

Revision history for this message
Serpent Consulting Services (serpent-consulting-services) said :
#12

Priyanka,

You should download OpenERP-web 6.0.2 and run from terminal /workspace/openerp/web/openerp-web.py

Hope this helps.

Thanks.

Revision history for this message
priyanka saha (priyanka-u) said :
#13

Thanks sir.It works.But i want to run it from eclipse from source code.here what can i do?openerp-server.py runs.But web it is not working.

Regars
Priyanka

Revision history for this message
Serpent Consulting Services (serpent-consulting-services) said :
#14

Priyanka,

I just made sure that it works!

Go to the openerp-web.py and right click->run as python run!

If it still does not work, it could be permission issues.

Thanks.

Revision history for this message
priyanka saha (priyanka-u) said :
#15

On 06/24/2012 04:11 AM, Serpent Consulting Services wrote:
> Question #188819 on OpenERP Server changed:
> https://answers.launchpad.net/openobject-server/+question/188819
>
> Serpent Consulting Services proposed the following answer:
> Priyanka,
>
> I just made sure that it works!
>
> Go to the openerp-web.py and right click->run as python run!
>
> If it still does not work, it could be permission issues.
>
> Thanks.
>
>
i am not understanding one thing.when openerp-server.py is running then
server is running it is shown.Then i ran openerp-client.py.Here a window
has come.But there was written that server is not running.why it is??

Regards
Priyanka

Revision history for this message
priyanka saha (priyanka-u) said :
#16

another thing maximum tutorial about openerp in internet it is said that
after running server to check the 8069 port from browser.here i am also
facing problem.it also doesn't work.ops!!nw what should i do??

Thanks
Priyanka

Revision history for this message
priyanka saha (priyanka-u) said :
#17

after running poenerp-web.py getting these errors.

Traceback (most recent call last):
  File "/workspace/openerptest/web/openerp-web.py", line 11, in <module>
    from openobject.commands import start, ConfigurationError
  File "/workspace/openerptest/web/openobject/__init__.py", line 10, in <module>
    import cherrypy
ImportError: No module named cherrypy

Revision history for this message
Bushair (bushairka) said :
#18

Hi,

Please install the module cherrypy required for your installation

Can you help with this problem?

Provide an answer of your own, or ask Bushair for more information if necessary.

To post a message you must log in.