Ruby on rails rake db:create:all致命:密码身份验证失败
我正在努力学习本教程。现在,我进入了使用rake db:create:all创建数据库的步骤,但我收到了以下错误消息:Ruby on rails rake db:create:all致命:密码身份验证失败,ruby-on-rails,database,ruby-on-rails-3,postgresql,rake,Ruby On Rails,Database,Ruby On Rails 3,Postgresql,Rake,我正在努力学习本教程。现在,我进入了使用rake db:create:all创建数据库的步骤,但我收到了以下错误消息: FATAL: password authentication failed for user aldila 我通过pgAdmin创建了用户aldila,方法是右键单击登录角色并添加带有密码的用户aldila 这是我的database.yml: development: adapter: postgresql host: localhost encoding
FATAL: password authentication failed for user aldila
我通过pgAdmin创建了用户aldila,方法是右键单击登录角色并添加带有密码的用户aldila
这是我的database.yml:
development:
adapter: postgresql
host: localhost
encoding: unicode
database: my_app_development
pool: 5
username: aldila
password: *mypass*
test:
adapter: postgresql
host: localhost
encoding: unicode
database: my_app_test
pool: 5
username: aldila
password: *mypass*
production:
adapter: postgresql
host: localhost
encoding: unicode
database: my_app_production
pool: 5
username: aldila
password: *mypass*
这是我的pg_hba.conf
# TYPE DATABASE USER ADDRESS METHOD
# IPv4 local connections:
host all all 127.0.0.1/32 md5
# IPv6 local connections:
host all all ::1/128 md5
# Allow replication connections from localhost, by a user with the
# replication privilege.
#host replication postgres 127.0.0.1/32 md5
#host replication postgres ::1/128 md5
安装PostreSQL可能有问题,因为如果我键入
psql——我命令的版本,这是我得到的:
'psql' is not recognized as an internal or external command,
operable program or batch file.
但我不知道出了什么问题。我从EnterpriseDB安装它,并从EnterpriseDB下载所有受支持版本的安装程序
我知道已经有类似的问题了,但我遵循和,但我仍然得到相同的错误消息。如果有人能帮忙,我将不胜感激。谢谢您的postgresSQL密码与您的数据库不匹配。rb的密码。。这取决于您使用的环境。您使用的是
design
?也许你忘记添加密码确认了。不,我没有。是否要为数据库创建登录角色?我使用pgAdmin并通过pgAdmin添加登录角色,如果这是您的意思的话。您使用的是什么操作系统?