2014-02-18 43 views
0

我有postgresql的問題有像許多用戶那裏升級到小牛。我能夠安裝pg gem。升級到特立獨行擁有我:fe_sendauth:沒有提供密碼

我跑pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start並得到了迴應server starting

然而,當我嘗試運行bundle exec rake db:migrate,我得到的錯誤:

fe_sendauth: no password supplied

我的database.yml看起來是這樣的:

common: &common 
    adapter: postgresql 
    encoding: utf8 
    pool: 5 


development: 
    <<: *common 
    host: localhost 
    database: vm_development 

# Warning: The database defined as "test" will be erased and re-generated from your  development database 
# when you run "rake". Do not set this db to the same as development or production. 
test: &test 
    <<: *common 
    host: localhost 
    database: vm_test 

production: 
    <<: *common 
    database: vm_production 

cucumber: 
    <<: *test 

我不知道是什麼原因我得到這個消息。這是我的database.yml問題還是postgresql的問題?我無法訪問psql,因爲系統提示輸入密碼,無論我嘗試什麼,我都會收到psql: FATAL: password authentication failed

當我運行pg_ctl -D /usr/local/var/postgres status時,我看到消息pg_ctl: no server running。如何在沒有密碼的情況下啓動我的服務器?

任何幫助將不勝感激。謝謝。

回答

0

我想出了這個問題。另一個應用程序在我的電腦上有多個Postgres副本。確保在從brew安裝之前刪除所有postgres副本。

相關問題