Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id DEF101337BA6 for ; Fri, 1 Apr 2011 05:18:15 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 38296-04 for ; Fri, 1 Apr 2011 08:18:05 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from hogranch.com (hogranch.com [75.101.82.47]) by mail.postgresql.org (Postfix) with ESMTP id 555861337B47 for ; Fri, 1 Apr 2011 05:18:04 -0300 (ADT) Received: from [127.0.0.1] (porker [192.168.0.2]) by hogranch.com (8.11.6/8.11.6) with ESMTP id p318Hvc23759 for ; Fri, 1 Apr 2011 01:17:57 -0700 Message-ID: <4D958A35.8030501@hogranch.com> Date: Fri, 01 Apr 2011 01:17:57 -0700 From: John R Pierce User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.15) Gecko/20110303 Lightning/1.0b2 Thunderbird/3.1.9 MIME-Version: 1.0 To: pgsql-bugs@postgresql.org Subject: Re: default password for user postgres References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-HawgScanner-Information: Please contact the ISP for more information X-HawgScanner: Found to be clean X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201104/3 X-Sequence-Number: 29922 On 03/31/11 6:50 PM, Raphael Giovanini wrote: > I`m change the default passwod, and not conect for this user. What the > default password? there is no default password. on most unix and linux distributions, the default authentication mode is set to 'ident' which means a given unix user X can only connect as the postgres user X. initially, the only postgres user is 'postgres', so... (assuming you're on the typical unix/linux system, you didn't say) $ sudo -u postgres psql postgres=> alter user postgres password 'apassword'; postgres=> create user yerusername createdb createuser password 'somepass'; postgres=> create database yerusername owner yerusername; postgres=> \q $ ... now as your regular user 'yerusername' you can connect to postgres, and have the privileges to create new users and databases. That sequence also modified the postgres user's password in case you change the default authentication method to md5 (this is set in pg_hba.conf, see the documentation for more details)