Changing postgres password and warning
ORIGINAL from https://serverfault.com/questions/110154/whats-the-default-superuser-username-password-for-postgres-after-a-new-install CAUTION The answer about changing the UNIX password for "postgres" through "$ sudo passwd postgres" is not preferred, and can even be DANGEROUS ! This is why: By default, the UNIX account "postgres" is locked, which means it cannot be logged in using a password. If you use "sudo passwd postgres", the account is immediately unlocked. Worse, if you set the password to something weak, like "postgres", then you are exposed to a great security danger. For example, there are a number of bots out there trying the username/password combo "postgres/postgres" to log into your UNIX system. What you should do is follow Chris James 's answer: sudo -u postgres psql postgres # \password postgres Enter new password: To explain it a little bit. There are usually two default ways to login to
Comments
Post a Comment