Cant restore raven from backup

216 views
Skip to first unread message

rabidlemming

unread,
Dec 21, 2016, 12:06:59 PM12/21/16
to RavenDB - 2nd generation document database
Hi,

boy not having a good day today :( ...anyway i noticed a lot of my documents in my database simply disappeared !? i think its because i have Expiration  switched in although i never configured this.  

any how i wanted to restore all the documents i had lost but when i try though the managment studio i got  "web server to deny the request because the content length exceeds the configured value" i tryed everything in my iis config to fix and override this but i could get the file to import. so i dropped the database all together in favour of using the restore command which would only work if the database didn't already exist 

however when i try though the managment studio i get 

"Unable to restore database Cannot restore when the Database.Document file is missing in the backup folder: C:\Raven\BackUp\2016-12-21-09-00-ravendb-backup"

if i try though linqPad it restores the database but with no documents 

var _Store = new DocumentStore { Url = "http://xxxxxx:80/",DefaultDatabase ="RavenDB" };
   _Store
.Initialize();
 _Store
.DatabaseCommands
 
.GlobalAdmin
 
.StartRestore(
 
new DatabaseRestoreRequest
 
{
 
BackupLocation = @"C:\Raven\BackUp\2016-12-19-08-39-ravendb-backup\",
 DatabaseLocation = @"
~\Databases\",
 IndexesLocation = @"
C:\Raven\CompiledIndexCache\",
 DatabaseName = "
RavenDB2"
 });

i also try the Raven.Server.exe command line and got 

PS C:\Users\carfuser\Downloads\RavenDB-3.5.2-patch-35181\Server> .\Raven.Server.exe --restore-source=C:\Raven\BackUp\201
6-12-20-08-55-ravendb-backup --restore-destination=C:\Raven\Databases --restore-system-database
System.InvalidOperationException: Cannot restore when the Database.Document file is missing in the backup folder: C:\Rav
en\BackUp\2016-12-20-08-55-ravendb-backup
   at Raven.Database.Actions.MaintenanceActions.Restore(RavenConfiguration configuration, DatabaseRestoreRequest restore
Request, Action`1 output) in C:\Builds\RavenDB-3.5-Patch\Raven.Database\Actions\MaintenanceActions.cs:line 57
   at Raven.Server.Program.RunSystemDatabaseRestoreOperation(String backupLocation, String databaseLocation, Boolean def
rag) in C:\Builds\RavenDB-3.5-Patch\Raven.Server\Program.cs:line 756

I tried several different backup files but all have the same issue  :(

what am i missing ?

thanks R

Grisha Kotler

unread,
Dec 21, 2016, 12:47:38 PM12/21/16
to rav...@googlegroups.com
Did you create the backup using Raven.Backup or the studio?

Hibernating Rhinos Ltd  cid:image001.png@01CF95E2.8ED1B7D0

Grisha Kotler l RavenDB Core Team Developer Mobile: +972-54-586-8647

Office: +972-4-622-7811 l Fax: +972-153-4-622-7811

RavenDB paving the way to "Data Made Simplehttp://ravendb.net/


--
You received this message because you are subscribed to the Google Groups "RavenDB - 2nd generation document database" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ravendb+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Oren Eini (Ayende Rahien)

unread,
Dec 21, 2016, 12:51:27 PM12/21/16
to ravendb
What are the contents of your backup folder?

Hibernating Rhinos Ltd  

Oren Eini l CEO Mobile: + 972-52-548-6969

rabidlemming

unread,
Dec 21, 2016, 2:00:10 PM12/21/16
to RavenDB - 2nd generation document database


I used the raven studio . I had incremental backup setup and i did a full back up before i dropped the database. My contents are like so:

Oren Eini (Ayende Rahien)

unread,
Dec 21, 2016, 2:03:08 PM12/21/16
to ravendb
Those aren't backups, those are exports. You need to import them, not restore them.
See:

Hibernating Rhinos Ltd  

Oren Eini l CEO Mobile: + 972-52-548-6969

Office: +972-4-622-7811 l Fax: +972-153-4-622-7811

 


--

rabidlemming

unread,
Dec 21, 2016, 5:06:27 PM12/21/16
to RavenDB - 2nd generation document database
Ah...i see ...Doh! my bad...thanks didnt realise there was a difference sorry ...thank you :) 


On Wednesday, 21 December 2016 17:06:59 UTC, rabidlemming wrote:
Reply all
Reply to author
Forward
0 new messages