Oh, I didn&#39;t spot the ext2 mention... I guess this is an embedded system?<br><br>The tmpfs option might work well, although it&#39;ll be all or nothing since everything is stored in the same directory. A symlink to a tmpfs mount probably wouldn&#39;t work as FS will try to create a new file in the db directory.<br>
<br>-Steve<br><br><br><div class="gmail_quote">On 18 August 2010 09:36, Steven Ayre <span dir="ltr">&lt;<a href="mailto:steveayre@gmail.com">steveayre@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">&quot;The power has failed recently though, maybe connected?&quot;<br><br></div>Quite likely. Anything in the disk write cache will be lost on a power failure. Two ways to avoid that are:<br>1) Battery backup for your RAID<br>
2) Disable write cache (which will of course have a performance penalty)<br>
<br>The database files would be actively changed, so any changes would be in the write cache resulting in a only partially written database when power returns.<br><br>Note that each db file is a separate sqlite database. You will only need to repair/delete the damaged one(s).<br>

<br>You might find that moving everything into a ODBC database with transaction support will result in less corruption if a power fails.<br><br>-Steve<div><div></div><div class="h5"><br><br><br><div class="gmail_quote">On 18 August 2010 02:58, Brian May <span dir="ltr">&lt;<a href="mailto:brian@microcomaustralia.com.au" target="_blank">brian@microcomaustralia.com.au</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div>On 7 August 2010 18:35, Brian May &lt;<a href="mailto:brian@microcomaustralia.com.au" target="_blank">brian@microcomaustralia.com.au</a>&gt; wrote:<br>


&gt;&gt; As for how to do sqlite data recovery, try googling. e.g.<br>
&gt;&gt; <a href="http://www.mail-archive.com/sqlite-users@sqlite.org/msg17538.html" target="_blank">http://www.mail-archive.com/sqlite-users@sqlite.org/msg17538.html</a><br>
&gt;<br>
&gt; Thanks for the reference. I tried looking but obviously wasn&#39;t looking<br>
&gt; for the right search term.<br>
<br>
</div>Curiously I had the same problem reoccur. Unfortunately freeswitch<br>
appears to work until some time after the initial problem, makes it<br>
hard to find out what happened. The power has failed recently though,<br>
maybe connected?<br>
<br>
[ etc ]<br>
2010-08-17 04:30:40.728489 [CRIT] switch_core_sqldb.c:938 SQL thread<br>
unable to commit transaction, records lost!<br>
2010-08-17 04:31:00.653705 [ERR] switch_core_sqldb.c:448 SQL ERR<br>
<div>[database disk image is malformed]<br>
</div>[ etc ]<br>
<br>
huey:/opt/freeswitch/db# ls -l core2.db<br>
-rw-r--r-- 1 freeswitch daemon 1502208 2010-08-15 17:11 core2.db<br>
huey:/opt/freeswitch/db# sqlite3  core2.db<br>
SQLite version 3.5.9<br>
Enter &quot;.help&quot; for instructions<br>
sqlite&gt; .dump<br>
BEGIN TRANSACTION;<br>
COMMIT;<br>
<br>
This is ext2 on flash memory. Maybe I should move core.db on to tmpfs?<br>
I get the impression persistence isn&#39;t required for this file...<br>
<div><div></div><div>--<br>
Brian May &lt;<a href="mailto:brian@microcomaustralia.com.au" target="_blank">brian@microcomaustralia.com.au</a>&gt;<br>
<br>
_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
</div></div></blockquote></div><br>
</div></div></blockquote></div><br>