Adarsh H D Dev
Adarsh H D Dev

Reputation: 618

Restore for SOLR standalone server is failing with IndexNotFoundException

I have SOLR running on a standalone server, i was testing for backup and restore in order to take the backup I have used below command

curl 'http://localhost:8983/solr/coreName/replication?command=backup'

The above command is able to take the backup successfully. But i used below command to restore the previously taken backup.

curl 'http://localhost:8983/solr/coreName/replication?command=restore'

Which used the latest available backup and restored successfully. But i wanted to pass the backup name in the command, So i tried the below command

curl 'http://localhost:8983/solr/coreName/replication?command=restore&name=snapshot.2017xxxxxx'` 

when i ran this the backup didn't go well am getting a error as below when checked the restore status

<str name="status">failed</str><str name="exception">org.apache.lucene.index.IndexNotFoundException: no segments* file found in MMapDirectory@/database/solr/data/UMB/data/snapshot.snapshot.20170503060914378 lockFactory=org.apache.lucene.store.NativeFSLockFactory@9ee14c9: files: []</str></lst>

Could anyone please suggest me whats going wrong. The SOLR is hosted on Cent OS.

Thanks

Upvotes: 0

Views: 1143

Answers (1)

Adarsh H D Dev
Adarsh H D Dev

Reputation: 618

I found out what was causing the issues. for SOLR hosted on linux when we pass the backup name instead of passing complete name like snapshot.2017xxxxx we just need to exclude the snapshot and pass only the timestamp details. the command would be something like below

curl 'http://localhost:8983/solr/UMB/replication?command=restore&name=2017xxxxxxxxx'

Upvotes: 4

Related Questions