pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
No pg_hba.conf entry
2+ messages / 2 participants
[nested] [flat]

* No pg_hba.conf entry
@ 2003-02-14 08:08 vivek K. <vivek10@hotmail.com>
  2003-02-14 19:15 ` Re: No pg_hba.conf entry Robert Treat <xzilla@users.sourceforge.net>
  0 siblings, 1 reply; 2+ messages in thread

From: vivek K. @ 2003-02-14 08:08 UTC (permalink / raw)
  To: pgsql-admin

<html><div style='background-color:'><DIV>
<DIV>find your postgresql.conf file, look in there to make sure tcpip_socket<BR>= true.<BR><BR>the directory that file is in should be the same as the $PGDATA that<BR>your getting asked for, so you'll be able to do <BR><BR>pg_ctl -D /path/to/database status<BR><BR>Robert Treat&nbsp; <BR></DIV>
<DIV>&nbsp;</DIV></DIV>
<DIV>Hello All,</DIV>
<DIV>&nbsp;Thanks to Robert. I have set the above things but SQL-ledger is giving different error this time like :</DIV>
<DIV>FATAL 1: No pg_hba.conf entry for host 192.168.168.56, user sql-ledger, database template1</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp; I am using the preinstalled Postgres DB that came along with the default RH Linux Installation. I did not install externally.( so the path will be /usr/bin./usr/lib)</DIV>
<DIV>&nbsp;</DIV>
<DIV>I have set the variables as suggested in the postgressql.conf file. But i am now getting this error.</DIV>
<DIV>$ pg_ctl&nbsp; -D&nbsp; /usr/lib/pgsql start<BR>postmaster successfully started<BR>bash-2.05a$ FATAL 1:&nbsp; data directory /usr/lib/pgsql has group or world access; p<BR>ermissions should be u=rwx (0700)&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>and also</DIV>
<DIV>bash-2.05a$ initdb<BR>The files belonging to this database system will be owned by user "postgres".<BR>This user must also own the server process.</DIV>
<DIV>initdb: The directory /usr/lib/pgsql exists but is not empty.<BR>If you want to create a new database system, either remove or empty<BR>the directory /usr/lib/pgsql or run initdb with<BR>an argument other than /usr/lib/pgsql.&nbsp; </DIV>
<DIV>&nbsp;</DIV>
<DIV>I have set PGDATA&nbsp;=/usr/lib/pgsql and there is no directory by name data. Should i create a new Directory by name data and initialise this. Please advice.</DIV>
<DIV>&nbsp;</DIV>
<DIV>Thank and regards,</DIV>
<DIV>Vivek</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV></div><br clear=all><hr>Help STOP SPAM with <a href="http://g.msn.com/8HMEEN/2731">the new MSN 8 </a> and get 2 months FREE*</html>



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

* Re: No pg_hba.conf entry
  2003-02-14 08:08 No pg_hba.conf entry vivek K. <vivek10@hotmail.com>
@ 2003-02-14 19:15 ` Robert Treat <xzilla@users.sourceforge.net>
  0 siblings, 0 replies; 2+ messages in thread

From: Robert Treat @ 2003-02-14 19:15 UTC (permalink / raw)
  To: vivek K. <vivek10@hotmail.com>; +Cc: pgsql-admin

On Fri, 2003-02-14 at 03:08, vivek K. wrote:
Hello All,
 Thanks to Robert. I have set the above things but SQL-ledger is giving
different error this time like :
FATAL 1: No pg_hba.conf entry for host 192.168.168.56, user sql-ledger,
database template1
 
If your using the standard Red Hat rpm, I believe your data file will be
in /var/lib/pgsql/data, which should also be you $PGDATA variable. 

The error above indicates that the user sql-ledger doesn't have
authorization. You'll need to look in your pg_hba.conf file and add I
line like:

host all 192.168.168.56 255.255.255.255 trust

(Note, this isn't the tightest configuration; check the docs to see for
ways to adjust this once your up and running and ready for production)

  I am using the preinstalled Postgres DB that came along with the
default RH Linux Installation. I did not install externally.( so the
path will be /usr/bin./usr/lib)
 
I have set the variables as suggested in the postgressql.conf file. But
i am now getting this error.
$ pg_ctl  -D  /usr/lib/pgsql start
postmaster successfully started
bash-2.05a$ FATAL 1:  data directory /usr/lib/pgsql has group or world
access; p
ermissions should be u=rwx (0700) 

ISTM you should be doing pg_ctl -D /var/lib/pgsql/data start. BTW, check
your ps output. You normally wont receive the error message at the
beginning of this email unless the server is already running.
 
and also
bash-2.05a$ initdb
The files belonging to this database system will be owned by user
"postgres".
This user must also own the server process.
initdb: The directory /usr/lib/pgsql exists but is not empty.
If you want to create a new database system, either remove or empty
the directory /usr/lib/pgsql or run initdb with
an argument other than /usr/lib/pgsql.  
 
I have set PGDATA =/usr/lib/pgsql and there is no directory by name
data. Should i create a new Directory by name data and initialise this.
Please advice.
 

Again, I think you need to set $PGDATA to /var/lib/pgsql/data It
wouldn't hurt to do an ls -al in that directory and see what you have,
I'm guessing you'll find all of the other components of your server.

And again, the first error message indicates that your server is already
up and running, so really you probably don't need to run an initdb.

Robert Treat
 
 

________________________________________________________________________
Help STOP SPAM with the new MSN 8  and get 2 months FREE*






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


end of thread, other threads:[~2003-02-14 19:15 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-02-14 08:08 No pg_hba.conf entry vivek K. <vivek10@hotmail.com>
2003-02-14 19:15 ` Robert Treat <xzilla@users.sourceforge.net>

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