etherpad-lite icon indicating copy to clipboard operation
etherpad-lite copied to clipboard

Etherpad authentication failed with postgres

Open kernelfreak opened this issue 9 years ago • 9 comments

Hello friends,

My friend installed Ubuntu 16.10 on his system and we are having problem with getting etherpad working with Postgresql. Postgresql version 9.4 and 9.5 we tried, but no luck. We keep getting the error below.


events.js:160
      throw er; // Unhandled 'error' event
      ^

error: password authentication failed for user "postgres"
    at Connection.parseE (/usr/local/lib/node_modules/etherpad-lite/src/node_modules/pg/lib/connection.js:534:11)
    at Connection.parseMessage (/usr/local/lib/node_modules/etherpad-lite/src/node_modules/pg/lib/connection.js:361:17)
    at Socket.<anonymous> (/usr/local/lib/node_modules/etherpad-lite/src/node_modules/pg/lib/connection.js:105:22)
    at emitOne (events.js:96:13)
    at Socket.emit (events.js:188:7)
    at readableAddChunk (_stream_readable.js:176:18)
    at Socket.Readable.push (_stream_readable.js:134:10)
    at TCP.onread (net.js:551:20)

Our settings.json part :+1:

  "dbType" : "postgres",
  "dbSettings" : {
		  "user"    : "postgres",
                    "host"    : "localhost",
                    "password": "PASSWORD",
                    "database": "DBNAME",
                    "charset" : "utf8mb4"

                 },

The password is correct, as our applications are able to connect with the DB with same password, but etherpad cannot,. Tried installing, unisntalling etherpad as well, no luck. What are we doing wrong?m

kernelfreak avatar Jan 23 '17 12:01 kernelfreak

I had the same output. The issue was brianc/node-postgres#1000 and I was able to fix it like it was mentioned in that issue: brianc/node-postgres@77560fe

Flakebi avatar Feb 03 '17 14:02 Flakebi

Thanks @Flakebi : This solved the problem. :-)

kernelfreak avatar Feb 07 '17 08:02 kernelfreak

Could this be re-opened? requiring users to patch some code by hand isn't the best solution. I think just updating the ueberdb2 dependency to 3.5.0 will fix it

blunckr avatar Mar 07 '17 21:03 blunckr

I was wrong, ueberdb2 needs to update their dependency too.

See: https://github.com/Pita/ueberDB/pull/93

blunckr avatar Mar 07 '17 21:03 blunckr

@blunckr : I get an option for reopening, do you want me to reopen this? Please tell me the text I should add when reopening. Thanks.

kernelfreak avatar Mar 28 '17 11:03 kernelfreak

Well, really the issue is in ueberdb, so I'm not sure it does any good to re-open it at this point. Thanks though.

blunckr avatar Mar 28 '17 19:03 blunckr

Apart from the fact that etherpad is completely unuseable as it is now with psql and password. And if someone's not familar with the packaging/deps mechanism of etherpad it seems absolutely hopeless to get it started. I may go and try manually patch all the buggy files.....

grinapo avatar Nov 15 '17 15:11 grinapo

Writing to confirm that we are seeing this too. We can connect to the database fine, but etherpad-light cannot. (bad username/password)

e-lisa avatar Nov 19 '17 03:11 e-lisa

I have manually patched all client.js [with the patch in brianc/node-postgres@77560fe] in the various libs and it works, as long as I disable the whole updating mechanism. This is ugly.

grinapo avatar Nov 19 '17 10:11 grinapo