# How to restore backup database when program won't start

**URL:** <https://forum.emclient.com/t/how-to-restore-backup-database-when-program-wont-start/53398>\
**Category:** Uncategorized\
**Created:** [December 4, 2013, 2:23pm UTC](https://forum.emclient.com/t/how-to-restore-backup-database-when-program-wont-start/53398 "2013-12-04T14:23:06Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![DifferentVoice](https://forum.emclient.com/letter_avatar_proxy/v4/letter/d/ecb155/32.png) [@DifferentVoice](https://forum.emclient.com/u/DifferentVoice)\
**Post date:** [December 4, 2013, 2:23pm UTC](https://forum.emclient.com/t/how-to-restore-backup-database-when-program-wont-start/53398/1 "2013-12-04T14:23:06Z")

</div>

I get a long error message at startup and eM Client fails to start:  
System.Data.SQLite.SQLiteException: Some kind of disk I/O error occurred  
disk I/O error  
at System.Data.SQLite.SQLite3.Prepare(SQLiteConnection cnn, String strSql, SQLiteStatement previous, UInt32 timeoutMS, String& strRemain)  
at System.Data.SQLite.SQLiteCommand.BuildNextCommand()  
at System.Data.SQLite.SQLiteCommand.GetStatement(Int32 index)  
at System.Data.SQLite.SQLiteDataReader.NextResult()  
at System.Data.SQLite.SQLiteDataReader…ctor(SQLiteCommand cmd, CommandBehavior behave)  
at System.Data.SQLite.SQLiteCommand.ExecuteReader(CommandBehavior behavior)  
at System.Data.SQLite.SQLiteCommand.ExecuteNonQuery()  
at System.Data.SQLite.SQLiteConnection.Open()  
at DbRepair.DbTools.OpenConnection(String fileName)  
at DbRepair.Form1.CheckCorruption()  
at DbRepair.Form1.Check(Object state)

I’ve tried running the repair tool mentioned elsewhere but it didn’t fix the issue.

The files are backed up daily into the same mail folder. How do I restore from backup since the program won’t start?

---

<div class="post-metadata">

**Author:** ![Anonymous](https://forum.emclient.com/letter_avatar_proxy/v4/letter/a/8491ac/32.png) [@Anonymous](https://forum.emclient.com/u/Anonymous)\
**Post date:** [December 4, 2013, 2:26pm UTC](https://forum.emclient.com/t/how-to-restore-backup-database-when-program-wont-start/53398/2 "2013-12-04T14:26:45Z")

</div>

Hi,

if you have backup like you have written, then delete your old database in C:\Users\ current user \AppData\Roaming\ (eM Client folder) and start fresh eM Client. then you will be able to use restore tool.

Jan

---

<div class="post-metadata">

**Author:** ![DifferentVoice](https://forum.emclient.com/letter_avatar_proxy/v4/letter/d/ecb155/32.png) [@DifferentVoice](https://forum.emclient.com/u/DifferentVoice)\
**Post date:** [December 5, 2013, 5:30pm UTC](https://forum.emclient.com/t/how-to-restore-backup-database-when-program-wont-start/53398/3 "2013-12-05T17:30:46Z")

</div>

Thanks, John. It wasn’t exactly clear to me which file was the database (well, the largest one - but there were obviously other files of larger-than-normal size). I tried moving the folder, downloading and reinstalling eM Client, and doing the restore from backup but that refused to work. I even tried renaming the -bak files to see if that might work, but it didn’t. However, what did finally work was copying the old files back again after the fresh install.

---

<div class="post-metadata">

**Author:** ![Anonymous](https://forum.emclient.com/letter_avatar_proxy/v4/letter/a/8491ac/32.png) [@Anonymous](https://forum.emclient.com/u/Anonymous)\
**Post date:** [December 9, 2013, 1:11pm UTC](https://forum.emclient.com/t/how-to-restore-backup-database-when-program-wont-start/53398/4 "2013-12-09T13:11:18Z")

</div>

Database is whole folder 🙂 Deleting or moving just some files into or from it can make it broken again.

anyway I am glad that it works for you now.

Jan
