Re: [GENERAL] How to erase transaction logs on PostgreSQL

2012-03-09 Thread Simon Riggs
On Thu, Mar 8, 2012 at 10:18 AM, Frank Church voi...@gmail.com wrote:
 How do you purge the postgresql transaction log?

 I am creating a virtual machine image and I want to erase any transaction
 logs that got built up during development. What is the way to do that?

pg_resetxlog

 I am currently using 8.3 and 8.4.

 Is there the possibility that the logs saved in /var/log also contain
 security details?

I suggest you delete them.

-- 
 Simon Riggs   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training  Services

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] How to erase transaction logs on PostgreSQL

2012-03-09 Thread Frank Church
On 8 March 2012 16:23, Guillaume Lelarge guilla...@lelarge.info wrote:

 On Thu, 2012-03-08 at 10:18 +, Frank Church wrote:
  How do you purge the postgresql transaction log?
 

 You don't. PostgreSQL does it for you.

  I am creating a virtual machine image and I want to erase any transaction
  logs that got built up during development. What is the way to do that?
 
  I am currently using 8.3 and 8.4.
 
  Is there the possibility that the logs saved in /var/log also contain
  security details?
 

 The only security detail AFAIK would be passwords (if you set a password
 and log queries, the password will be in the logs... the only way to
 prevent that is to send it crypted).



What are the commands to accomplish that, ie getting PostgreSQL to erase
the logs?



 --
 Guillaume
 http://blog.guillaume.lelarge.info
 http://www.dalibo.com




Re: [GENERAL] How to erase transaction logs on PostgreSQL

2012-03-09 Thread John R Pierce

On 03/08/12 4:09 PM, Frank Church wrote:
What are the commands to accomplish that, ie getting PostgreSQL to 
erase the logs?


there's two completely different sorts of logs here.   'transaction 
logs' in postgres are the write-ahead logs, these are binary files used 
internally by postgres, in the pg_xlog directory, as Simon said, you can 
use pg_resetxlog() to 'reset' the state of this.


the other sort of logs are the human readable log files, generated for 
debugging and auditing purposes, these contain just what you configure 
them to contain, and are often stored in pg_log, or in the system logs 
(/var/log/...)  depending on your configuration.  you'd have to delete 
these yourself outside of postgres.


--
john r pierceN 37, W 122
santa cruz ca mid-left coast


--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] How to erase transaction logs on PostgreSQL

2012-03-08 Thread Frank Church
How do you purge the postgresql transaction log?

I am creating a virtual machine image and I want to erase any transaction
logs that got built up during development. What is the way to do that?

I am currently using 8.3 and 8.4.

Is there the possibility that the logs saved in /var/log also contain
security details?

/voipfc


Re: [GENERAL] How to erase transaction logs on PostgreSQL

2012-03-08 Thread Guillaume Lelarge
On Thu, 2012-03-08 at 10:18 +, Frank Church wrote:
 How do you purge the postgresql transaction log?
 

You don't. PostgreSQL does it for you.

 I am creating a virtual machine image and I want to erase any transaction
 logs that got built up during development. What is the way to do that?
 
 I am currently using 8.3 and 8.4.
 
 Is there the possibility that the logs saved in /var/log also contain
 security details?
 

The only security detail AFAIK would be passwords (if you set a password
and log queries, the password will be in the logs... the only way to
prevent that is to send it crypted).


-- 
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] How to erase transaction logs on PostgreSQL

2012-03-08 Thread Achilleas Mantzios
one ultra dummy way would be to dump, back up, destroy the data dirs,
and any human /var/log files and then re-initdb and restore.

On Πεμ 08 Μαρ 2012 12:18:17 Frank Church wrote:
 How do you purge the postgresql transaction log?
 
 I am creating a virtual machine image and I want to erase any transaction
 logs that got built up during development. What is the way to do that?
 
 I am currently using 8.3 and 8.4.
 
 Is there the possibility that the logs saved in /var/log also contain
 security details?
 
 /voipfc

-- 
Achilleas Mantzios
IT DEPT

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] How to erase transaction logs on PostgreSQL

2012-03-08 Thread Guillaume Lelarge
On Fri, 2012-03-09 at 00:09 +, Frank Church wrote:
 
 
 On 8 March 2012 16:23, Guillaume Lelarge guilla...@lelarge.info
 wrote:
 On Thu, 2012-03-08 at 10:18 +, Frank Church wrote:
  How do you purge the postgresql transaction log?
 
 
 
 You don't. PostgreSQL does it for you.
 
  I am creating a virtual machine image and I want to erase
 any transaction
  logs that got built up during development. What is the way
 to do that?
 
  I am currently using 8.3 and 8.4.
 
  Is there the possibility that the logs saved in /var/log
 also contain
  security details?
 
 
 
 The only security detail AFAIK would be passwords (if you set
 a password
 and log queries, the password will be in the logs... the only
 way to
 prevent that is to send it crypted).
 
 
 
 What are the commands to accomplish that, ie getting PostgreSQL to
 erase the logs?
 

PostgreSQL doesn't erase logs. You need to do it yourself, either
manually or with a script (executed by cron for example).


-- 
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general