Netmail Archive 6.x
Solr has a built-in ability to dump the contents of the shards into a specified location, and this functionality can be used to achieve a backup.
The Netmail webconsole will trigger this ability much like a regular Netmail job. This article will explain the configuration required to do so.
Create a shared location
The backup will assume all Solr servers in the cluster can see the same location using the same path. The easiest way to do this is with a network share mounted to same the place on all servers.
In this example, I will create a folder on the C:\ drive of the master Archive server called C:\SolrBackup. I will share this folder on the network, accessible to the 'netmail' local user (read/write permissions).
Mount the shared location
Since this is a Windows fileshare, I will need to install CIFS components on the CentOS machines so they can read/write to it:
yum install samba-client samba-common cifs-utils
Now create a mount point:
Now edit the /etc/fstab file to add this line which will mount this fileshare at the mount point above:
\\MasterArchive\SolrBackup /mnt/backup cifs user,uid=500,rw,suid,username=netmail,password=M3ss4g1ng,domain=MasterArchive 0 0
Instruct the OS to mount it now:
Test the location by writing/copying a file to /mnt/backup and seeing it appear in C:\SolrBackup on the master Archive server.
Configure the job
Log into the Netmail webconsole and navigate to Indexing > Backup tab.
Give the backup a name (eg.TestBackup) ; this will simply be the subfolder which will be created under the shared location.
Specify the path that the Solr servers must use to access the shared location, ie. the mount point we created earlier (/mnt/backup).
Press 'Save' to accept the new config.
Running the job
Press 'Run' on the backup job we configured above. Assuming everything is configured correctly we should start seeing the data appear on C:\SolrBackup.
C:\SolrBackup\TestBackup ...will be created.
etc. ... will be created.
C:\Solr\Backup\TestBackup\zk_backup ...will be created.