Restore finds no database files

Trying to restore, disabled dvr, pointed to the database folder but it can’t find any files. I get “no backups found in this directory”.

It’s a new nas, new drive. I previously had channels on a vm Transferred all the folders to the NAS and I’m pointing to that drive.

Do you see backup folders in the Database directory when you look via a file explorer?

It’s possible that the file permissions are not correct from copying the files over, so it’s not able to read the directories.

Yeah I can see the file folders and the contents inside. Both recorder.db file and settings.db file.

I’m able to see the files and open them without any permission warnings.

Check the Log tab of the DVR to see if any errors are shown there.

What kind of NAS are you trying to move to?

Synology. Will check log when I get hime

Here’s what I got:

2018/06/26 16:43:50 [Recovery] panic recovered:
GET /backups?Path=%2Fvolume5%2FHawk%2FChannels%2FDatabase HTTP/1.1
Host: 192.168.1.117:8089
Accept: */*
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9
Connection: keep-alive
Referer: http://192.168.1.117:8089/restore
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Safari/537.36


runtime error: invalid memory address or nil pointer dereference
/home/vagrant/go/src/runtime/panic.go:502 (0x42c1f8)
/home/vagrant/go/src/runtime/panic.go:63 (0x42b26d)
/home/vagrant/go/src/runtime/signal_unix.go:388 (0x4420c9)
/home/vagrant/channels-server-x86_64/.go/src/github.com/coreos/bbolt/bucket.go:398 (0x6eee88)
/home/vagrant/channels-server-x86_64/dvr/stats.go:39 (0xac60a0)
/home/vagrant/channels-server-x86_64/.go/src/github.com/coreos/bbolt/db.go:699 (0x6f482f)
/home/vagrant/channels-server-x86_64/dvr/stats.go:38 (0xac2b94)
/home/vagrant/channels-server-x86_64/http.go:1096 (0xb4bec9)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/context.go:104 (0x924fb2)
/home/vagrant/channels-server-x86_64/http.go:190 (0xb3422c)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/context.go:104 (0x924fb2)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/recovery.go:45 (0x934a99)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/context.go:104 (0x924fb2)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/contrib/sessions/sessions.go:65 (0xade23d)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/context.go:104 (0x924fb2)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-contrib/gzip/gzip.go:47 (0xad678b)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/context.go:104 (0x924fb2)
/home/vagrant/channels-server-x86_64/http.go:254 (0xb4440e)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/context.go:104 (0x924fb2)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/gin.go:332 (0x92c054)
/home/vagrant/channels-server-x86_64/.go/src/github.com/gin-gonic/gin/gin.go:296 (0x92b8a2)
/home/vagrant/go/src/net/http/server.go:2694 (0x6a4bfb)
/home/vagrant/go/src/net/http/server.go:1830 (0x6a0d50)
/home/vagrant/go/src/runtime/asm_amd64.s:2361 (0x45bd40)

Thanks. It looks like one of the backups is corrupted, and its causing the restore operation to fail.

I can work on a fix… if you can zip up the Database directory and send it to [email protected] that will be helpful.

Unreal, thank you so much. I’ll send in just a bit

Thanks for sending those files. I’m working on a fix, but it’s turning out to be much more complicated than I had guessed. A lot of your backups are severely corrupted for some reason- almost as if the computer was turned off or the hard drive disconnected while the backup was occurring.

The best work-around for now is to rename the Database folder to DatabaseOld, then create a new Database folder that has only the most recent backup folder in it. That way the restore will only try to read that one and let you finish the process.

1 Like

Thanks, this worked for me when I had the same problem. It then picked up the most recent backup in the database folder.

1 Like

Just wanted to say I had the same issue and this worked for me too! Thanks tmm1