[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Almost done with manual for Gentoo - but need some help



On Tue, 2007-09-18 at 09:39 -0700, Joshua D. Drake wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Jeff Kowalczyk wrote:
> > Joshua D. Drake wrote:
> >>> At this point to change or setup password for this user "ledgersmb"
> >>> and database "ledgersmb_db" do I type:
> >>> UPDATE users_conf SET password = md5('MYPASSWORD') WHERE id = 1;
> >> Wrong... use:
> 
> >   If you prefer to work in postgresql's psql console, the equivalent SQL
> >   statement to create the ledgersmb role is:
> > 
> >   => CREATE ROLE ledgersmb LOGIN PASSWORD 'MYROLEPASSWORD' NOINHERIT
> >   CREATEDB;
> > 
> >   Further commands and database interaction should be conducted using
> >   the new LedgerSMB admin role 'ledgersmb'.
> > 
> > 
> > Do we need a note for postgresql-8.0?
> 
> Yeah probably, as 8.0 as USER/GROUP versus ROLE. However it should be
> noted that as of 1.3, 8.0.x is deprecated.
> 
> Joshua D. Drake

My md5 authentication somehow is not working:

If I change in pg_hba.conf to:
local   all         all                                      trust
host    all         all         127.0.0.1/32        trust

I can login from Firefox create dataset etc.

If I change pg_hba.conf to md5:
local     all         all                                  md5
10.0.0.103    all   all                                  md5
 host    all         all         127.0.0.1/32             md5

(I'm login in from computer 10.0.0.103 hence the extra line).
but I can not login.

Here is my beginning:
For postgresql 8.0.x

$ createuser --createdb -U postgres --pwprompt --encrypted ledgersmb
Enter password for new user:
Enter it again:
Shall the new user be allowed to create more new users? (y/n) y
CREATE USER

$ createdb -U ledgersmb -O ledgersmb ledgersmb_db
CREATE DATABASE

$ psql -U ledgersmb -d ledgersmb_db
-f /usr/local/ledgersmb/sql/Pg-central.sql

$ psql -U ledgersmb -d ledgersmb_db 
ledgersmb_db=# UPDATE users_conf SET password = md5('syscon') WHERE id = 1;
ledgersmb_db=# \q 
      * 
[globaldb]
# These paramaters *must* be set correctly
# for LedgerSMB >= 1.2 to work
DBname       = ledgersmb_db
DBhost       = localhost
DBport       = 5432
DBUserName   = ledgersmb
DBPassword   = syscon

Where is my mistake?

I've check my posgresql and it is compiled with "ssl" support so it
should support md5 as well.
[ebuild   R   ] dev-db/postgresql-8.0.13  USE="nls pam perl python
readline ssl xml zlib -doc -kerberos -pg-intdatetime (-selinux) -tcl
-test" 0 kB
-- 
#Joseph