Re: Recovery of corrupted database

From: Samed YILDIRIM <samed(at)reddoc(dot)net>
To: Rikardo Tinauer <rikardo(dot)tinauer(at)eba(dot)si>, "pgsql-admin(at)postgresql(dot)org" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Recovery of corrupted database
Date: 2017-07-19 16:01:34
Message-ID: 8831500480094@web39g.yandex.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

<div>Hi Rikardo,</div><div> </div><div>I assume that you do not have any base backup, archive or replicated Postgres.</div><div> </div><div>Which Postgres version do you use? What is your operating system? Is It x64?</div><div> </div><div>Best regards.</div><div>Samed YILDIRIM</div><div> </div><div> </div><div> </div><div>19.07.2017, 18:20, "Rikardo Tinauer" &lt;rikardo(dot)tinauer(at)eba(dot)si&gt;:</div><blockquote type="cite"><div>Our client got virus on database server encrypting the database. They paid and got files decrypted but database wasn’t able to start.<div> </div><div>We got the following error:</div><div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  database system was shut down in recovery at <span>2017-07-19 10</span>:29:00 CEST</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  invalid magic number B549 in log segment <span>000000010000002</span>E<span>00000015</span>, offset 0</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  invalid primary checkpoint record</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  invalid magic number B549 in log segment <span>000000010000002</span>E<span>00000015</span>, offset 0</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  invalid secondary checkpoint record</div><div><span>2017-07-19 10</span>:31:11 CEST PANIC:  could not locate a valid checkpoint record</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  shutdown at recovery target</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  shutting down</div><div><span>2017-07-19 10</span>:31:11 CEST LOG:  database system is shut down</div></div><div> <div> </div><div>We got past that with executing the “pg_resetxlog -f DATADIR” command.</div><div> </div><div>Now database starts but we cannot connect to it, we get the following error: </div><div><span>2017-07-19 14</span>:11:05 CEST ERROR:  invalid page in block 0 of relation global/12369</div><div> </div><div>Can anyone help?</div><div> <div><div style="color:rgb(0,0,0);text-align:start;text-transform:none;white-space:normal;"><div><div style="color:rgb(0,0,0);font-family:&quot;Arial Unicode MS&quot;;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;text-align:start;text-transform:none;white-space:normal;">Lp, </div><div style="color:rgb(0,0,0);font-family:&quot;Arial Unicode MS&quot;;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;text-align:start;text-transform:none;white-space:normal;">Rikardo Tinauer</div><div style="color:rgb(0,0,0);font-family:&quot;Arial Unicode MS&quot;;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;text-align:start;text-transform:none;white-space:normal;">----------------------------------------------------------<br />EBA, d.o.o., Ljubljana<br />Litostrojska 40, SI-1000 Ljubljana<br />Tel: <span>+386 (0)590 98 890</span><br />Email: <a href="mailto:rikardo(dot)tinauer(at)eba(dot)si">rikardo(dot)tinauer(at)eba(dot)si</a><br />Web: <a href="http://www.ebadms.com/">http://www.ebadms.com</a><br />-----------------------------------------------------------</div></div></div></div></div></div></div></blockquote>

Attachment Content-Type Size
unknown_filename text/html 3.1 KB

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Bear Giles 2017-07-19 16:01:41 Re: Recovery of corrupted database
Previous Message Rikardo Tinauer 2017-07-19 13:27:48 Recovery of corrupted database