[prev in list] [next in list] [prev in thread] [next in thread] 

List:       postgresql-admin
Subject:    [ADMIN] Recovery of corrupted database
From:       Rikardo Tinauer <rikardo.tinauer () eba ! si>
Date:       2017-07-19 13:27:48
Message-ID: 155A6581-E109-4FAC-B59B-ECDC09BD92AB () eba ! si
[Download RAW message or body]

Our client got virus on database server encrypting the database. They paid and got \
files decrypted but database wasn't able to start.

We got the following error:
2017-07-19 10:31:11 CEST LOG:  database system was shut down in recovery at \
2017-07-19 10:29:00 CEST 2017-07-19 10:31:11 CEST LOG:  invalid magic number B549 in \
log segment 000000010000002E00000015, offset 0 2017-07-19 10:31:11 CEST LOG:  invalid \
primary checkpoint record 2017-07-19 10:31:11 CEST LOG:  invalid magic number B549 in \
log segment 000000010000002E00000015, offset 0 2017-07-19 10:31:11 CEST LOG:  invalid \
secondary checkpoint record 2017-07-19 10:31:11 CEST PANIC:  could not locate a valid \
checkpoint record 2017-07-19 10:31:11 CEST LOG:  shutdown at recovery target
2017-07-19 10:31:11 CEST LOG:  shutting down
2017-07-19 10:31:11 CEST LOG:  database system is shut down


We got past that with executing the "pg_resetxlog -f DATADIR" command.

Now database starts but we cannot connect to it, we get the following error: 
2017-07-19 14:11:05 CEST ERROR:  invalid page in block 0 of relation global/12369

Can anyone help?

Lp, 
Rikardo Tinauer
----------------------------------------------------------
EBA, d.o.o., Ljubljana
Litostrojska 40, SI-1000 Ljubljana
Tel: +386 (0)590 98 890
Email: rikardo.tinauer@eba.si
Web: http://www.ebadms.com
-----------------------------------------------------------


[Attachment #3 (unknown)]

<html><head><meta http-equiv="Content-Type" content="text/html \
charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; \
-webkit-line-break: after-white-space;" class="">Our client got virus on database \
server encrypting the database. They paid and got files decrypted but database wasn't \
able to start.<div class=""><br class=""></div><div class="">We got the following \
error:</div><div class=""><div class="">2017-07-19 10:31:11 CEST LOG: &nbsp;database \
system was shut down in recovery at 2017-07-19 10:29:00 CEST</div><div \
class="">2017-07-19 10:31:11 CEST LOG: &nbsp;invalid magic number B549 in log segment \
000000010000002E00000015, offset 0</div><div class="">2017-07-19 10:31:11 CEST LOG: \
&nbsp;invalid primary checkpoint record</div><div class="">2017-07-19 10:31:11 CEST \
LOG: &nbsp;invalid magic number B549 in log segment 000000010000002E00000015, offset \
0</div><div class="">2017-07-19 10:31:11 CEST LOG: &nbsp;invalid secondary checkpoint \
record</div><div class="">2017-07-19 10:31:11 CEST PANIC: &nbsp;could not locate a \
valid checkpoint record</div><div class="">2017-07-19 10:31:11 CEST LOG: \
&nbsp;shutdown at recovery target</div><div class="">2017-07-19 10:31:11 CEST LOG: \
&nbsp;shutting down</div><div class="">2017-07-19 10:31:11 CEST LOG: &nbsp;database \
system is shut down</div></div><div class=""><br class=""><div class=""><br \
class=""></div><div class="">We got past that with executing the "pg_resetxlog -f \
DATADIR" command.</div><div class=""><br class=""></div><div class="">Now database \
starts but we cannot connect to it, we get the following error:&nbsp;</div><div \
class="">2017-07-19 14:11:05 CEST ERROR: &nbsp;invalid page in block 0 of relation \
global/12369</div><div class=""><br class=""></div><div class="">Can anyone \
help?</div><div class=""><br class=""><div class=""> <div style="color: rgb(0, 0, 0); \
letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; \
text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; \
-webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; \
-webkit-line-break: after-white-space;" class=""><div style="word-wrap: break-word; \
-webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div \
style="color: rgb(0, 0, 0); font-family: 'Arial Unicode MS'; font-size: 12px; \
font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: \
normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; \
white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: \
0px;">Lp,&nbsp;</div><div style="color: rgb(0, 0, 0); font-family: 'Arial Unicode \
MS'; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: \
normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; \
text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; \
-webkit-text-stroke-width: 0px;">Rikardo Tinauer</div><div style="color: rgb(0, 0, \
0); font-family: 'Arial Unicode MS'; font-size: 12px; font-style: normal; \
font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: \
auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; \
widows: auto; word-spacing: 0px; -webkit-text-stroke-width: \
0px;">----------------------------------------------------------<br class="">EBA, \
d.o.o., Ljubljana<br class="">Litostrojska 40, SI-1000 Ljubljana<br class="">Tel: \
+386 (0)590 98 890<br class="">Email: <a href="mailto:rikardo.tinauer@eba.si" \
class="">rikardo.tinauer@eba.si</a><br class="">Web: <a href="http://www.ebadms.com" \
class="">http://www.ebadms.com</a><br \
class="">-----------------------------------------------------------</div></div></div>
 </div>
<br class=""></div></div></body></html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic