pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
log activity questions
3+ messages / 3 participants
[nested] [flat]

* log activity questions
@ 2008-10-09 18:56  Marc Fromm <Marc.Fromm@wwu.edu>
  0 siblings, 1 reply; 3+ messages in thread

From: Marc Fromm @ 2008-10-09 18:56 UTC (permalink / raw)
  To: pgsql-admin

I started logging on our server. There are many entries like this:
transaction ID wrap limit is 1073768178, limited by database "postgres"
transaction ID wrap limit is 1073771864, limited by database "sms"

Each database has several of the above entries.

Also there are these fatal entries:
FATAL:  database "template0" is not currently accepting connections
FATAL:  database "template0" is not currently accepting connections

What is the transaction ID wrap and should I change a setting to correct them?
Does the template need to accept connections? If I make a new database based on template0 does that mean that database cannot accept connections?

Thanks

Marc

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

* Re: log activity questions
@ 2008-10-15 00:38  Scott Marlowe <scott.marlowe@gmail.com>
  parent: Marc Fromm <Marc.Fromm@wwu.edu>
  0 siblings, 1 reply; 3+ messages in thread

From: Scott Marlowe @ 2008-10-15 00:38 UTC (permalink / raw)
  To: Marc Fromm <Marc.Fromm@wwu.edu>; +Cc: pgsql-admin

On Thu, Oct 9, 2008 at 12:56 PM, Marc Fromm <Marc.Fromm@wwu.edu> wrote:
> I started logging on our server. There are many entries like this:
>
> transaction ID wrap limit is 1073768178, limited by database "postgres"
>
> transaction ID wrap limit is 1073771864, limited by database "sms"
>
> Each database has several of the above entries.

That's completely normal.  IT's an information log, not a warning or an error.

> Also there are these fatal entries:
>
> FATAL:  database "template0" is not currently accepting connections
>
> FATAL:  database "template0" is not currently accepting connections
>
> Does the template need to accept connections? If I make a new database based
> on template0 does that mean that database cannot accept connections?

Template0 is your "man, I really screwed up template1" get out of jail
free database.  It is normally set to not allow connections (look at
"select * from pg_databases;" for the field that does or doesn't allow
connections).  If you ever did terrible things to templat1, you could
set template0 to datallowcon=t and then drop and recreate template1
using template0 as the template.  Then vacuum freeze it and set it to
not allow connections again to template0 to get it back to normal
again.



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

* Re: log activity questions
@ 2008-10-15 00:43  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Scott Marlowe <scott.marlowe@gmail.com>
  0 siblings, 0 replies; 3+ messages in thread

From: Tom Lane @ 2008-10-15 00:43 UTC (permalink / raw)
  To: Scott Marlowe <scott.marlowe@gmail.com>; +Cc: Marc Fromm <Marc.Fromm@wwu.edu>; pgsql-admin

"Scott Marlowe" <scott.marlowe@gmail.com> writes:
> Template0 is your "man, I really screwed up template1" get out of jail
> free database.  It is normally set to not allow connections (look at
> "select * from pg_databases;" for the field that does or doesn't allow
> connections).  If you ever did terrible things to templat1, you could
> set template0 to datallowcon=t and then drop and recreate template1
> using template0 as the template.  Then vacuum freeze it and set it to
> not allow connections again to template0 to get it back to normal
> again.

You don't need to (and shouldn't) touch datallowconn while doing the
above.  Just use some third database to launch the "DROP DATABASE
template1" and "CREATE DATABASE template1 WITH TEMPLATE template0"
commands.

BTW: the other, more common use of template0 is as a template for making
a database to restore a dump into.  If you use template1 then any local
additions in template1 pose a hazard for the dump (which probably also
tries to define those objects).

			regards, tom lane



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


end of thread, other threads:[~2008-10-15 00:43 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2008-10-09 18:56 log activity questions Marc Fromm <Marc.Fromm@wwu.edu>
2008-10-15 00:38 ` Scott Marlowe <scott.marlowe@gmail.com>
2008-10-15 00:43   ` Tom Lane <tgl@sss.pgh.pa.us>

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