Defining a backup target in solr.xml
If you want to to define or modify a backup target, you can download, edit and reupload solr.xml from ZooKeeper.
The solr.xml
of your Solr installation, which is stored in
ZooKeeper, can define a backup target repository, and depending on your installation
it likely has a default target pointing to HDFS.
HDFS as a backup target is still fine even if your Solr collection uses a local FS / NRTCachingDirectoryFactory, so even with local FS collections you can store your backups on HDFS.
Similarly to this, other repositories like a LocalFileSystemRepository can
also be defined in the solr.xml
if you want to store the backups on
a location other than HDFS. However note, that if you use a local FS to store
backups, each Solr host will store its backup directory locally. That is, server X
will contain the backup directory snapshots.shard1, server Y
will contain snapshots.shard2 and you need to copy them to a
shared location in order to be able to restore them later. Because of this, it is
recommended to target backups to a shared file system.
If the solr.xml
does not have a backup repository at all,
it defaults to the local FS repository.