Guys,
I think I need a bit of help here.
A few weeks ago i had the same issue described in this thread an could solve it folowing the steps. But now i am getting the folowing errors, which I cannot resolve whith the described steps.
All devices are lost and no data available in Domoticz, when the " repaired" database is active. Looks like an clean install.
At the moment i went back to the defect database.
Any ideas on how I can fix this and not lose all my data?
Code: Select all
2017-05-01 16:05:01.625 Error: SQL Query("DELETE FROM Temperature WHERE strftime('%s',datetime('now','localtime')) - strftime('%s',Date) > (SELECT p.nValue * 86400 From Preferences AS p WHERE p.Key='5MinuteHistoryDays')") : database disk image is malformed
2017-05-01 16:10:01.723 Error: SQL Query("DELETE FROM Temperature WHERE strftime('%s',datetime('now','localtime')) - strftime('%s',Date) > (SELECT p.nValue * 86400 From Preferences AS p WHERE p.Key='5MinuteHistoryDays')") : database disk image is malformed
2017-05-01 16:15:00.828 Error: SQL Query("DELETE FROM Temperature WHERE strftime('%s',datetime('now','localtime')) - strftime('%s',Date) > (SELECT p.nValue * 86400 From Preferences AS p WHERE p.Key='5MinuteHistoryDays')") : database disk image is malformed
2017-05-01 16:20:01.000 Error: SQL Query("DELETE FROM Temperature WHERE strftime('%s',datetime('now','localtime')) - strftime('%s',Date) > (SELECT p.nValue * 86400 From Preferences AS p WHERE p.Key='5MinuteHistoryDays')") : database disk image is malformed
2017-05-01 16:25:01.328 Error: SQL Query("DELETE FROM Temperature WHERE strftime('%s',datetime('now','localtime')) - strftime('%s',Date) > (SELECT p.nValue * 86400 From Preferences AS p WHERE p.Key='5MinuteHistoryDays')") : database disk image is malformed
2017-05-01 16:30:01.581 Error: SQL Query("DELETE FROM Temperature WHERE strftime('%s',datetime('now','localtime')) - strftime('%s',Date) > (SELECT p.nValue * 86400 From Preferences AS p WHERE p.Key='5MinuteHistoryDays')") : database disk image is malformed
Domoticz V 3.7013 running on a raspberry.
Hardwware present:
[16 Kodi Yes Kodi Media Server Setup Disabled
15 SmartMeter Yes P1 Smart Meter USB /dev/ttyUSB2 Disabled
13 Anna Yes Plugwise Anna Thermostat via LAN interface 192.168.2.4 80 Disabled
12 Weer Yes Weather Underground WWW Disabled
11 EnOcean Yes EnOcean USB (ESP3) /dev/ttyAMA0 Disabled
10 WOL Yes Wake-on-LAN Setup 192.168.2.255 9 Disabled
9 Philips Hue Bridge 1.0 Yes Philips Hue Bridge 192.168.2.29 80 Disabled
6 Motherboard Yes Motherboard sensors Disabled
5 Dummy Yes Dummy (Does nothing, use for virtual switches only) Create Virtual Sensors Disabled
4 ZWAVE Yes OpenZWave USB
Version: 1.4-2435-gc61d20d-dirty Setup /dev/ttyUSB0 Disabled
3 RFXtrx Yes RFXCOM - RFXtrx433 USB 433.92MHz Transceiver
Version: Ext/1015 Set Mode /dev/ttyUSB1 Disabled[/code]
Thanks.
Arthur
Yes, there are erros in the database:
Code: Select all
*** in database main ***
Page 5443: btreeInitPage() returns error code 11
On tree page 438 cell 43: Child page depth differs
On tree page 438 cell 44: Child page depth differs
Page 5085: btreeInitPage() returns error code 11
On tree page 44 cell 36: Child page depth differs
On tree page 5086 cell 8: Rowid 830 out of order (previous was 831)
On tree page 5086 cell 9: Rowid 32 out of order (previous was 830)
On tree page 5086 cell 12: Rowid 832 out of order (previous was 833)
On tree page 5086 cell 15: Rowid 837 out of order (previous was 2884)
On tree page 5086 cell 16: Rowid 582 out of order (previous was 837)
Multiple uses for byte 638 of page 5086
Fragmentation of 45 bytes reported as 0 on page 5086
On tree page 44 cell 37: Child page depth differs
On tree page 5087 cell 3: Rowid 846 out of order (previous was 1869)
On tree page 5087 cell 4: Rowid 6 out of order (previous was 846)
On tree page 5087 cell 7: Rowid 850 out of order (previous was 881)
On tree page 5087 cell 10: Rowid 2 out of order (previous was 852)
On tree page 5087 cell 14: Rowid 48 out of order (previous was 856)
On tree page 5087 cell 20: Rowid 863 out of order (previous was 2910)
Corruption detected in cell 14 on page 5087
Corruption detected in cell 20 on page 5087
Multiple uses for byte 17 of page 5087
On tree page 5093 cell 8: Rowid 977 out of order (previous was 978)
On tree page 5093 cell 9: Rowid 45 out of order (previous was 977)
On tree page 5093 cell 11: Rowid 51 out of order (previous was 979)
On tree page 5093 cell 15: Rowid 6 out of order (previous was 983)
On tree page 5093 cell 18: Rowid 7 out of order (previous was 986)
On tree page 5093 cell 20: Rowid 989 out of order (previous was 5084)
Corruption detected in cell 3 on page 5093
Corruption detected in cell 15 on page 5093
Multiple uses for byte 529 of page 5093
Fragmentation of 102 bytes reported as 0 on page 5093
On tree page 5100 cell 5: Rowid 51 out of order (previous was 1120)
On tree page 5100 cell 6: Rowid 45 out of order (previous was 51)
On tree page 5100 cell 11: Rowid 6 out of order (previous was 1126)
On tree page 5100 cell 16: Rowid 64 out of order (previous was 1131)
On tree page 5100 cell 16: invalid page number 2100441137
Corruption detected in cell 9 on page 5100
Corruption detected in cell 14 on page 5100
Multiple uses for byte 529 of page 5100
Fragmentation of 93 bytes reported as 0 on page 5100
On tree page 4329 cell 8: Rowid 54 out of order (previous was 98)
On tree page 4329 cell 20: Rowid 20 out of order (previous was 110)
On tree page 4329 cell 21: Rowid 5 out of order (previous was 20)
On tree page 4329 cell 21: invalid page number 808531501
On tree page 4329 cell 26: Rowid 33 out of order (previous was 116)
On tree page 4329 cell 43: Rowid 134 out of order (previous was 4229)
Page 4329: Rowid 8327 out of order (max larger than parent max of 135)
Corruption detected in cell 1 on page 4329
Corruption detected in cell 10 on page 4329
Corruption detected in cell 18 on page 4329
Corruption detected in cell 27 on page 4329
Multiple uses for byte 619 of page 4329
Fragmentation of 57 bytes reported as 0 on page 4329
On tree page 4330 cell 4: Rowid 132 out of order (previous was 139)
On tree page 4330 cell 21: Rowid 157 out of order (previous was 668)
On tree page 4330 cell 32: Rowid 48 out of order (previous was 167)
Page 4330: Rowid 136 out of order (min less than parent min of 8327)
Corruption detected in cell 18 on page 4330
Corruption detected in cell 22 on page 4330
Multiple uses for byte 821 of page 4330
Fragmentation of 66 bytes reported as 0 on page 4330
On tree page 4331 cell 2: Rowid 148 out of order (previous was 179)
On tree page 4331 cell 3: Rowid 5 out of order (previous was 148)
On tree page 4331 cell 7: Rowid 185 out of order (previous was 440)
On tree page 4331 cell 8: Rowid 102 out of order (previous was 185)
On tree page 4331 cell 31: Rowid 209 out of order (previous was 8400)
On tree page 4331 cell 37: Rowid 151 out of order (previous was 214)
On tree page 4331 cell 41: Rowid 219 out of order (previous was 4314)
Corruption detected in cell 0 on page 4331
Corruption detected in cell 3 on page 4331
Corruption detected in cell 14 on page 4331
Corruption detected in cell 32 on page 4331
Multiple uses for byte 149 of page 4331
Page 4350: btreeInitPage() returns error code 11
On tree page 20 cell 23: Child page depth differs
On tree page 20 cell 24: Child page depth differs
Page 4353: btreeInitPage() returns error code 11
On tree page 20 cell 26: Child page depth differs
On tree page 20 cell 27: Child page depth differs
On tree page 4356 cell 1: Rowid 1222 out of order (previous was 5317)
On tree page 4356 cell 3: Rowid 48 out of order (previous was 5319)
On tree page 4356 cell 12: invalid page number 554814724
On tree page 4356 cell 13: Rowid 1234 out of order (previous was 11908)
On tree page 4356 cell 16: Rowid 1237 out of order (previous was 1238)
On tree page 4356 cell 18: Rowid 50 out of order (previous was 1238)
On tree page 4356 cell 21: Rowid 55 out of order (previous was 1241)
On tree page 4356 cell 25: Rowid 52 out of order (previous was 1245)
On tree page 4356 cell 28: Rowid 5 out of order (previous was 1248)
On tree page 4356 cell 28: invalid page number 758133037
On tree page 4356 cell 34: Rowid 1255 out of order (previous was 9446)
Multiple uses for byte 390 of page 4356
Fragmentation of 17 bytes reported as 0 on page 4356
On tree page 4357 cell 2: Rowid 9 out of order (previous was 1263)
On tree page 4357 cell 4: Rowid 9 out of order (previous was 1265)
On tree page 4357 cell 9: Rowid 2 out of order (previous was 1270)
On tree page 4357 cell 26: Rowid 1288 out of order (previous was 1301)
On tree page 4357 cell 27: Rowid 8 out of order (previous was 1288)
On tree page 4357 cell 32: Rowid 10 out of order (previous was 1293)
On tree page 4357 cell 35: Rowid 1297 out of order (previous was 1297)