User Tools

Site Tools


how_to:postgresql_server_won_t_start_due_to_damaged_log_files

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
how_to:postgresql_server_won_t_start_due_to_damaged_log_files [2012/12/05 09:39] – [PostgreSQL server won't start due to damaged log files] paulhow_to:postgresql_server_won_t_start_due_to_damaged_log_files [2013/12/06 10:40] – [PostgreSQL server won't start due to damaged log files] paul
Line 2: Line 2:
  
 If the PostgreSQL server won't start at all, because its transaction logs are damaged, you will probably need to recreate the database store totally. If the PostgreSQL server won't start at all, because its transaction logs are damaged, you will probably need to recreate the database store totally.
- 
-You **may** be able to use the **[[http://www.postgresql.org/docs/8.3/static/app-pgresetxlog.html|pg_resetxlog.exe]]** program to create new transaction logs and control files which are 'just good enough' to get PostgreSQL started again, then you can [[http://wiki.pscs.co.uk/how_to%3Bbackup_vpop3#manual_database_backup|backup the database]] before doing the following steps. (Do //not// use pg_resetxlog.exe, then continue using the database without doing a full backup/rebuild/restore, corruption may be hidden, and cause bigger problems in the future). See the [[http://www.postgresql.org/docs/8.3/static/app-pgresetxlog.html|pg_resetxlog instructions]] for details on how to use that utility. 
  
 To rebuild the database: To rebuild the database:
Line 18: Line 16:
 Once you're happy everything is working OK, you can delete the **data_old** folder. Once you're happy everything is working OK, you can delete the **data_old** folder.
  
-If you wish, we can remote into your server and try to recover the data for you, but there will be a [[http://www.pscs.co.uk/buynow/buy.php?item=MISCSUP|£20 charge]] for this. You can [[support@pscs.co.uk|email us]] or phone on +44 1484 855800 to arrange this.+If you wish, we can remote into your server and try to recover the data for you, but there will be a [[http://www.pscs.co.uk/buynow/buy.php?item=MISCSUP3|£75 charge]] for this. You can [[support@pscs.co.uk|email us]] or phone on +44 1484 855800 to arrange this.
  
 =====Possible Causes===== =====Possible Causes=====
Line 26: Line 24:
  
 The only files in the pgsql\data folder which should ever be accessed by anything other than PostgreSQL itself are the contents of the ''pg_log'' folder (NOT the pg_xlog/pg_clog folders!) or the ''*.conf'' files. The only files in the pgsql\data folder which should ever be accessed by anything other than PostgreSQL itself are the contents of the ''pg_log'' folder (NOT the pg_xlog/pg_clog folders!) or the ''*.conf'' files.
 +
 +
 +====Possible alternative solution====
 +You **may** be able to use the **[[http://www.postgresql.org/docs/8.3/static/app-pgresetxlog.html|pg_resetxlog.exe]]** program to create new transaction logs and control files which are 'just good enough' to get PostgreSQL started again, then you can [[http://wiki.pscs.co.uk/how_to%3Bbackup_vpop3#manual_database_backup|backup the database]] before doing the following steps. (Do //not// use pg_resetxlog.exe, then continue using the database without doing a full backup/rebuild/restore, corruption may be hidden, and cause bigger problems in the future). See the [[http://www.postgresql.org/docs/8.3/static/app-pgresetxlog.html|pg_resetxlog instructions]] for details on how to use that utility.
  
  
how_to/postgresql_server_won_t_start_due_to_damaged_log_files.txt · Last modified: 2018/11/14 10:45 by 127.0.0.1