2013-11-25 3 views
0

postgresql 데이터베이스에 연결할 때 인증 오류가 계속 발생합니다. 다음은 특정 오류입니다.postgresql 데이터베이스에 연결

[error] c.j.b.h.AbstractConnectionHook - Failed to obtain initial connection Sleeping for 0ms and trying again. Attempts left: 0. Exception: null.Message:FATAL: password authentication failed for user 

사용자 이름과 암호를 확인하고 다시 확인 했으므로이 문제가 없습니다. psql을 사용하여이 동일한 데이터베이스에 성공적으로 연결할 수있었습니다. 다음은 내 application.conf 형식입니다.

# Database configuration 
# ~~~~~ 
# You can declare as many datasources as you want. 
# By convention, the default datasource is named `default` 
# 
# db.default.driver=org.h2.Driver 
# db.default.url="jdbc:h2:mem:play" 
# db.default.user=sa 
# db.default.password="" 
#Database configuration using PostgreSQL database engine 
db.default.driver=org.postgresql.Driver 
db.default.url="jdbc:postgresql://website.com/database" 
db.default.user="username" 
db.default.password="password") 

# Evolutions 
# ~~~~~ 
# You can disable evolutions if needed 
# evolutionplugin=disabled 

# Logger 
# ~~~~~ 
# You can also configure logback (http://logback.qos.ch/), 
# by providing an application-logger.xml file in the conf directory. 

# Root logger: 
logger.root=ERROR 

# Logger used by the framework: 
logger.play=INFO 

# Logger provided to your application: 
logger.application=DEBUG 

                68,0-1  Bot 

통찰력을 가져 주셔서 감사합니다!

+0

추측 : 사용중인 pwd의 특수 문자는 무엇입니까? –

+0

엄격히 영문자입니다 –

+0

죄송합니다. 질문을 완전히 읽지 못했습니다. 초기 댓글이 유효하지 않습니다 – Gavin

답변

1
db.default.password="password") 

) 입력 오류는 사용하지 마십시오? 그렇지 않은 경우 제거하고 다시 시도하십시오.

+0

가끔은 자신의 정보에 대해 걱정할 필요가 있습니다. –

0
db.default.driver="org.postgresql.Driver" 
db.default.url="postgres://username:[email protected]:5432/mydb" 

이 나를 위해 잘 작동, 나는 이벤트는 db.default.userdb.default.password

관련 문제