pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Re: Stalled post to pgsql-admin
5+ messages / 3 participants
[nested] [flat]

* Re: Stalled post to pgsql-admin
@ 2003-01-20 13:52 Zhiqiang Feng <zf2@st-andrews.ac.uk>
  2003-01-21 03:18 ` Re: Stalled post to pgsql-admin Leland F. Jackson, CPA <smvfp@mail.smvfp.com>
  2003-01-21 15:07 ` Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
  0 siblings, 2 replies; 5+ messages in thread

From: Zhiqiang Feng @ 2003-01-20 13:52 UTC (permalink / raw)
  To: pgsql-admin


Hello all, 

I am new to postgreSQL. I have installed postgreSQL 7.1.3-2 on Linux 7.2.
If I login as root (administrator) and change user as postgres I can create
database on /usr/local/pgsql/data which I created and changed its owner as
postgres. 

root# mkdir usr/local/pgsql/data 
root# chown postgres /usr/local/pgsql/data 
root# su postgres 
bash-2.3# initdb -D /usr/local/pgsql/data 
bash-2.3# postmaster -D /usr/local/pgsql/data > logfile 2 >&1 & 
bash-2.3# createdb testdb 
bash-2.3# psql testdb

However, when I login as a normal linux user I cannot create database. So
it is a user management problem. 

zf2linux# createdb mydb 
FATAL 1: user 'zf2linux' does not exist

I have tried to create a user of zf2linux in postgreSQL but the error still
occurs.
If I try to change to postgres from zf1linux it asks for password.

zf2linux# su postgres 
password: ****** 
incorrect password.

My pg_hba.conf is left as the default format:

local 		all						 trust 
host 		all	 127.0.0.1	 255.255.255.255	 trust

I must miss something before I allow other users to access the postgreSQL
server and account. Could you please help me with the problem?

Thanks for your attention and will sum.

Geoff 

Dr. Zhiqiang Feng
School of Geography & Geosciences
Irving Building
University of St Andrews
St Andrews Fife KY16 9AL
tel: 01334 463951 

zf2@st-andrews.ac.uk




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Stalled post to pgsql-admin
  2003-01-20 13:52 Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
@ 2003-01-21 03:18 ` Leland F. Jackson, CPA <smvfp@mail.smvfp.com>
  1 sibling, 0 replies; 5+ messages in thread

From: Leland F. Jackson, CPA @ 2003-01-21 03:18 UTC (permalink / raw)
  To: pgsql-admin; Zhiqiang Feng <zf2@st-andrews.ac.uk>

Hi Zhiqiang,

You might take a look at the following link:

http://www.tek-tips.com/viewthread.cfm?SQID=449717&SPID=699&page=1

After you have postgres user properly setup, you can use pgaccess to
configure other users.

LelandJ


----- Original Message -----
From: "Zhiqiang Feng" <zf2@st-andrews.ac.uk>
To: <pgsql-admin@postgresql.org>
Sent: Monday, January 20, 2003 7:52 AM
Subject: Re: [ADMIN] Stalled post to pgsql-admin


>
> Hello all,
>
> I am new to postgreSQL. I have installed postgreSQL 7.1.3-2 on Linux 7.2.
> If I login as root (administrator) and change user as postgres I can
create
> database on /usr/local/pgsql/data which I created and changed its owner as
> postgres.
>
> root# mkdir usr/local/pgsql/data
> root# chown postgres /usr/local/pgsql/data
> root# su postgres
> bash-2.3# initdb -D /usr/local/pgsql/data
> bash-2.3# postmaster -D /usr/local/pgsql/data > logfile 2 >&1 &
> bash-2.3# createdb testdb
> bash-2.3# psql testdb
>
> However, when I login as a normal linux user I cannot create database. So
> it is a user management problem.
>
> zf2linux# createdb mydb
> FATAL 1: user 'zf2linux' does not exist
>
> I have tried to create a user of zf2linux in postgreSQL but the error
still
> occurs.
> If I try to change to postgres from zf1linux it asks for password.
>
> zf2linux# su postgres
> password: ******
> incorrect password.
>
> My pg_hba.conf is left as the default format:
>
> local all trust
> host all 127.0.0.1 255.255.255.255 trust
>
> I must miss something before I allow other users to access the postgreSQL
> server and account. Could you please help me with the problem?
>
> Thanks for your attention and will sum.
>
> Geoff
>
> Dr. Zhiqiang Feng
> School of Geography & Geosciences
> Irving Building
> University of St Andrews
> St Andrews Fife KY16 9AL
> tel: 01334 463951
>
> zf2@st-andrews.ac.uk
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo@postgresql.org so that your
> message can get through to the mailing list cleanly




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Stalled post to pgsql-admin
  2003-01-20 13:52 Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
@ 2003-01-21 15:07 ` Zhiqiang Feng <zf2@st-andrews.ac.uk>
  2003-01-21 18:40   ` Re: Stalled post to pgsql-admin Andrew Biagioni <andrew.biagioni@e-greek.net>
  2003-01-22 16:33   ` Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
  1 sibling, 2 replies; 5+ messages in thread

From: Zhiqiang Feng @ 2003-01-21 15:07 UTC (permalink / raw)
  To: Leland F. Jackson, CPA <smvfp@mail.smvfp.com>; pgsql-admin; +Cc: andrew.biagioni@e-greek.net

Thank Leland and Andrews for your help. 

I successfully use pgaccess to add users and now can start postgresql as a
normal user. 

However, it seems pgaccess requires TCP/IP port connection so I have to
include 
host 		 all	IP_address_of_pc 	255.255.0.0		trust

in the pg_hba.conf.

With regards,

Zhiqiang

At 21:18 20/01/03 -0600, Leland F. Jackson, CPA wrote:
>Hi Zhiqiang,
>
>You might take a look at the following link:
>
>http://www.tek-tips.com/viewthread.cfm?SQID=449717&SPID=699&page=1
>
>After you have postgres user properly setup, you can use pgaccess to
>configure other users.
>
>LelandJ
>
>
>----- Original Message -----
>From: "Zhiqiang Feng" <zf2@st-andrews.ac.uk>
>To: <pgsql-admin@postgresql.org>
>Sent: Monday, January 20, 2003 7:52 AM
>Subject: Re: [ADMIN] Stalled post to pgsql-admin
>
>
>>
>> Hello all,
>>
>> I am new to postgreSQL. I have installed postgreSQL 7.1.3-2 on Linux 7.2.
>> If I login as root (administrator) and change user as postgres I can
>create
>> database on /usr/local/pgsql/data which I created and changed its owner as
>> postgres.
>>
>> root# mkdir usr/local/pgsql/data
>> root# chown postgres /usr/local/pgsql/data
>> root# su postgres
>> bash-2.3# initdb -D /usr/local/pgsql/data
>> bash-2.3# postmaster -D /usr/local/pgsql/data > logfile 2 >&1 &
>> bash-2.3# createdb testdb
>> bash-2.3# psql testdb
>>
>> However, when I login as a normal linux user I cannot create database. So
>> it is a user management problem.
>>
>> zf2linux# createdb mydb
>> FATAL 1: user 'zf2linux' does not exist
>>
>> I have tried to create a user of zf2linux in postgreSQL but the error
>still
>> occurs.
>> If I try to change to postgres from zf1linux it asks for password.
>>
>> zf2linux# su postgres
>> password: ******
>> incorrect password.
>>
>> My pg_hba.conf is left as the default format:
>>
>> local all trust
>> host all 127.0.0.1 255.255.255.255 trust
>>
>> I must miss something before I allow other users to access the postgreSQL
>> server and account. Could you please help me with the problem?
>>
>> Thanks for your attention and will sum.
>>
>> Geoff
>>
>> Dr. Zhiqiang Feng
>> School of Geography & Geosciences
>> Irving Building
>> University of St Andrews
>> St Andrews Fife KY16 9AL
>> tel: 01334 463951
>>
>> zf2@st-andrews.ac.uk
>>
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 3: if posting/reading through Usenet, please send an appropriate
>> subscribe-nomail command to majordomo@postgresql.org so that your
>> message can get through to the mailing list cleanly
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 5: Have you checked our extensive FAQ?
>
>http://www.postgresql.org/users-lounge/docs/faq.html

Dr. Zhiqiang Feng
School of Geography & Geosciences
Irving Building
University of St Andrews
St Andrews Fife KY16 9AL
tel: 01334 463951 

zf2@st-andrews.ac.uk




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Stalled post to pgsql-admin
  2003-01-20 13:52 Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
  2003-01-21 15:07 ` Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
@ 2003-01-21 18:40   ` Andrew Biagioni <andrew.biagioni@e-greek.net>
  1 sibling, 0 replies; 5+ messages in thread

From: Andrew Biagioni @ 2003-01-21 18:40 UTC (permalink / raw)
  To: Zhiqiang Feng <zf2@st-andrews.ac.uk>; +Cc: Leland F. Jackson, CPA <smvfp@mail.smvfp.com>; pgsql-admin

Be careful with your pg_hba.conf entries (read the comments in the file 
itself, they are lengthy but useful).  What you configured (below) will 
allow anyone to connect to your database from any machine without 
validation, as long as their IP address has the first two blocks equal 
to your machine.  Are you sure that's what you want?

Zhiqiang Feng wrote:

>Thank Leland and Andrews for your help. 
>
>I successfully use pgaccess to add users and now can start postgresql as a
>normal user. 
>
>However, it seems pgaccess requires TCP/IP port connection so I have to
>include 
>host 		 all	IP_address_of_pc 	255.255.0.0		trust
>
>in the pg_hba.conf.
>
>With regards,
>
>Zhiqiang
>
>At 21:18 20/01/03 -0600, Leland F. Jackson, CPA wrote:
>  
>
>>Hi Zhiqiang,
>>
>>You might take a look at the following link:
>>
>>http://www.tek-tips.com/viewthread.cfm?SQID=449717&SPID=699&page=1
>>
>>After you have postgres user properly setup, you can use pgaccess to
>>configure other users.
>>
>>LelandJ
>>
>>
>>----- Original Message -----
>>From: "Zhiqiang Feng" <zf2@st-andrews.ac.uk>
>>To: <pgsql-admin@postgresql.org>
>>Sent: Monday, January 20, 2003 7:52 AM
>>Subject: Re: [ADMIN] Stalled post to pgsql-admin
>>
>>
>>    
>>
>>>Hello all,
>>>
>>>I am new to postgreSQL. I have installed postgreSQL 7.1.3-2 on Linux 7.2.
>>>If I login as root (administrator) and change user as postgres I can
>>>      
>>>
>>create
>>    
>>
>>>database on /usr/local/pgsql/data which I created and changed its owner as
>>>postgres.
>>>
>>>root# mkdir usr/local/pgsql/data
>>>root# chown postgres /usr/local/pgsql/data
>>>root# su postgres
>>>bash-2.3# initdb -D /usr/local/pgsql/data
>>>bash-2.3# postmaster -D /usr/local/pgsql/data > logfile 2 >&1 &
>>>bash-2.3# createdb testdb
>>>bash-2.3# psql testdb
>>>
>>>However, when I login as a normal linux user I cannot create database. So
>>>it is a user management problem.
>>>
>>>zf2linux# createdb mydb
>>>FATAL 1: user 'zf2linux' does not exist
>>>
>>>I have tried to create a user of zf2linux in postgreSQL but the error
>>>      
>>>
>>still
>>    
>>
>>>occurs.
>>>If I try to change to postgres from zf1linux it asks for password.
>>>
>>>zf2linux# su postgres
>>>password: ******
>>>incorrect password.
>>>
>>>My pg_hba.conf is left as the default format:
>>>
>>>local all trust
>>>host all 127.0.0.1 255.255.255.255 trust
>>>
>>>I must miss something before I allow other users to access the postgreSQL
>>>server and account. Could you please help me with the problem?
>>>
>>>Thanks for your attention and will sum.
>>>
>>>Geoff
>>>
>>>Dr. Zhiqiang Feng
>>>School of Geography & Geosciences
>>>Irving Building
>>>University of St Andrews
>>>St Andrews Fife KY16 9AL
>>>tel: 01334 463951
>>>
>>>zf2@st-andrews.ac.uk
>>>
>>>
>>>---------------------------(end of broadcast)---------------------------
>>>TIP 3: if posting/reading through Usenet, please send an appropriate
>>>subscribe-nomail command to majordomo@postgresql.org so that your
>>>message can get through to the mailing list cleanly
>>>      
>>>
>>---------------------------(end of broadcast)---------------------------
>>TIP 5: Have you checked our extensive FAQ?
>>
>>http://www.postgresql.org/users-lounge/docs/faq.html
>>    
>>
>
>Dr. Zhiqiang Feng
>School of Geography & Geosciences
>Irving Building
>University of St Andrews
>St Andrews Fife KY16 9AL
>tel: 01334 463951 
>
>zf2@st-andrews.ac.uk
>
>
>
>  
>

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Stalled post to pgsql-admin
  2003-01-20 13:52 Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
  2003-01-21 15:07 ` Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
@ 2003-01-22 16:33   ` Zhiqiang Feng <zf2@st-andrews.ac.uk>
  1 sibling, 0 replies; 5+ messages in thread

From: Zhiqiang Feng @ 2003-01-22 16:33 UTC (permalink / raw)
  To: Andrew Biagioni <andrew.biagioni@e-greek.net>; +Cc: pgsql-admin

Thanks, Andrew for your suggestion. I should change 255.255.0.0 to
255.255.255.255 to allow users of the PC to access the database.

zhiqiang

At 13:40 21/01/03 -0500, you wrote: 
>
> Be careful with your pg_hba.conf entries (read the comments in the file
> itself, they are lengthy but useful).  What you configured (below) will allow
> anyone to connect to your database from any machine without validation, as
> long as their IP address has the first two blocks equal to your machine.  Are
> you sure that's what you want?
>
> Zhiqiang Feng wrote:
>>
>>
>> Thank Leland and Andrews for your help. 
>> 
>> I successfully use pgaccess to add users and now can start postgresql as a
>> normal user. 
>> 
>> However, it seems pgaccess requires TCP/IP port connection so I have to
>> include 
>> host             all    IP_address_of_pc        255.255.0.0
trust
>> 
>> in the pg_hba.conf.
>> 
>> With regards,
>> 
>> Zhiqiang
>> 
>> At 21:18 20/01/03 -0600, Leland F. Jackson, CPA wrote:
>>    
>>>
>>> Hi Zhiqiang, You might take a look at the following link:
>>>
>>> <http://www.tek-tips.com/viewthread.cfm?SQID=449717&SPID=699&page=1>http
>>> ://www.tek-tips.com/viewthread.cfm?SQID=449717&SPID=699&page=1 After you
>>> have postgres user properly setup, you can use pgaccess to configure other
>>> users. LelandJ ----- Original Message ----- From: "Zhiqiang Feng"
>>> <mailto:zf2@st-andrews.ac.uk><zf2@st-andrews.ac.uk> To:
>>> <mailto:pgsql-admin@postgresql.org><pgsql-admin@postgresql.org> Sent:
>>> Monday, January 20, 2003 7:52 AM Subject: Re: [ADMIN] Stalled post to
>>> pgsql-admin     
>>>>
>>>> Hello all, I am new to postgreSQL. I have installed postgreSQL 7.1.3-2 on
>>>> Linux 7.2. If I login as root (administrator) and change user as postgres
>>>> I can       
>>>
>>> create     
>>>>
>>>> database on /usr/local/pgsql/data which I created and changed its owner as
>>>> postgres. root# mkdir usr/local/pgsql/data root# chown postgres
>>>> /usr/local/pgsql/data root# su postgres bash-2.3# initdb -D
>>>> /usr/local/pgsql/data bash-2.3# postmaster -D /usr/local/pgsql/data >
>>>> logfile 2 >&1 & bash-2.3# createdb testdb bash-2.3# psql testdb However,
>>>> when I login as a normal linux user I cannot create database. So it is a
>>>> user management problem. zf2linux# createdb mydb FATAL 1: user 'zf2linux'
>>>> does not exist I have tried to create a user of zf2linux in postgreSQL but
>>>> the error       
>>>
>>> still     
>>>>
>>>> occurs. If I try to change to postgres from zf1linux it asks for password.
>>>> zf2linux# su postgres password: ****** incorrect password. My pg_hba.conf
>>>> is left as the default format: local all trust host all 127.0.0.1
>>>> 255.255.255.255 trust I must miss something before I allow other users to
>>>> access the postgreSQL server and account. Could you please help me with
>>>> the problem? Thanks for your attention and will sum. Geoff Dr. Zhiqiang
>>>> Feng School of Geography & Geosciences Irving Building University of St
>>>> Andrews St Andrews Fife KY16 9AL tel: 01334 463951
>>>> <mailto:zf2@st-andrews.ac.uk>zf2@st-andrews.ac.uk
>>>> ---------------------------(end of broadcast)---------------------------
>>>> TIP 3: if posting/reading through Usenet, please send an appropriate
>>>> subscribe-nomail command to
>>>> <mailto:majordomo@postgresql.org>majordomo@postgresql.org so that your
>>>> message can get through to the mailing list cleanly       
>>>
>>> ---------------------------(end of broadcast)---------------------------
>>> TIP 5: Have you checked our extensive FAQ?
>>>
>>> <http://www.postgresql.org/users-lounge/docs/faq.html>http://www.postgre
>>> sql.org/users-lounge/docs/faq.html     
>>
>> Dr. Zhiqiang Feng School of Geography & Geosciences Irving Building
>> University of St Andrews St Andrews Fife KY16 9AL tel: 01334 463951
>> <mailto:zf2@st-andrews.ac.uk>zf2@st-andrews.ac.uk   
>


Dr. Zhiqiang Feng
School of Geography & Geosciences
Irving Building
University of St Andrews
St Andrews Fife KY16 9AL
tel: 01334 463951 

zf2@st-andrews.ac.uk

^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2003-01-22 16:33 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-01-20 13:52 Re: Stalled post to pgsql-admin Zhiqiang Feng <zf2@st-andrews.ac.uk>
2003-01-21 03:18 ` Leland F. Jackson, CPA <smvfp@mail.smvfp.com>
2003-01-21 15:07 ` Zhiqiang Feng <zf2@st-andrews.ac.uk>
2003-01-21 18:40   ` Andrew Biagioni <andrew.biagioni@e-greek.net>
2003-01-22 16:33   ` Zhiqiang Feng <zf2@st-andrews.ac.uk>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox