[英]postgres installation on server with Movable Type
I have just started a LAPP machine from Amazon ec2. 我刚刚从Amazon ec2启动了LAPP机器。 I have updated it to be Movable Type ready.
我已经将其更新为可移动类型。 I am using the postgresql database.
我正在使用postgresql数据库。 I stopped at the database installation section because I was getting a postgresql error.
我在数据库安装部分停了下来,因为我遇到了PostgreSQL错误。 I thought the only user by default is 'postgre' and has no password.
我认为默认情况下唯一的用户是“ postgre”,并且没有密码。 I put that in MT and it complains that I don't have a password.
我将其放在MT中,但它抱怨我没有密码。 So I thought I need to make a new user.
所以我认为我需要结识新用户。 So I tried createuser and it is asking for a Password.
所以我尝试了createuser,并要求输入密码。 I then did sudo and was now root.
然后我做了sudo,现在是root。 It still wants a Password.
它仍然需要密码。 I do not know what it is.
我不知道这是什么。
Looking at the log it appears postgresql is shutdown. 查看日志,发现postgresql已关闭。 When I try to restart it by using pg_ctl it says I cannot be root to restart it.
当我尝试使用pg_ctl重新启动它时,它说我不能以root的身份重新启动它。 So I exit and run it again as the default user name it gives me and I get a permission error.
因此,我退出并再次使用它作为给我的默认用户名运行,并且出现权限错误。
When I try to be root and createuser or do psql it says I need to give a password. 当我尝试成为root用户并创建用户或执行psql时,它说我需要输入密码。 I have tried to just hit return, and a bunch of other passwords that it may be.
我已经尝试过按回车键,以及其他可能的密码。 No luck.
没运气。 I thought since I was root I should be good.
我以为我从小就应该很好。
I know postgresql is there because MT says it is. 我知道postgresql在那儿,因为MT表示在那儿。
So I need to either come up with a psql Password or be able to login as a different user with the ability to restart postgresql. 因此,我需要输入psql密码,或者能够以其他用户身份登录并能够重新启动postgresql。
When you are 'root', you could su to the postgres user. 当您是“ root”用户时,您可以使用su postgres用户。 Then you should be able to create a new user.
然后,您应该能够创建一个新用户。 Remember to add the connection rights to the user in the /etc/postgresql//main/pg_hba.conf.
记住要在/etc/postgresql//main/pg_hba.conf中为用户添加连接权限。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.