Difference between revisions of "SUNScholar/Indexes/Rebuild"

From Libopedia
Jump to navigation Jump to search
m
Line 5: Line 5:
 
</center>
 
</center>
  
==Rationale==
+
==[[SUNScholar/Indexes/Rebuild/4.X|For DSpace 4.X]]==
After applying customisations, you need to rebuild the indexes. This is required after each change in the indexes configuration.
 
  
==Procedure==
+
==[[SUNScholar/Indexes/Rebuild/3.X|For DSpace 3.X]]==
Login to your server:
 
http://wiki.lib.sun.ac.za/index.php/SUNScholar/Prepare_Ubuntu/S01
 
  
Create a scripts folder.
 
mkdir /home/dspace/scripts
 
Create the script.
 
nano /home/dspace/scripts/build-indexes
 
 
Copy and paste the following.
 
<pre>
 
#!/bin/bash
 
 
#####################################################
 
## Select an option for index build/creation below ##
 
## Uncomment the relevant lines below              ##
 
#####################################################
 
## REINDEX: This option will reindex an existing index that has no new modifications.
 
#echo "Re-indexing existing indexes... Please wait"
 
#/home/dspace/bin/dspace update-discovery-index -b
 
 
## RECREATE: This option will recreate indexes after new index modifications.
 
#echo "Re-creating new indexes... Please wait"
 
#/home/dspace/bin/dspace update-discovery-index -f
 
 
#######################################################################
 
## This is only required if you use the old browse indexes          ##
 
## Since DSpace version 4.2, discovery is default                    ##
 
## Uncomment the lines below with a single hash to enable, if needed ##
 
#######################################################################
 
#echo "Building non-SOLR search and browse indexes... Please wait"
 
#sudo service tomcat6 stop
 
#sleep 5
 
#/home/dspace/bin/dspace index-init
 
#sudo service tomcat6 start
 
</pre>
 
 
{{NANO}}
 
 
Make the script executable.
 
chmod 0755 /home/dspace/scripts/build-indexes
 
 
Now you can re-build your indexes '''WHEN NEEDED''' by simply typing;
 
/home/dspace/scripts/build-indexes
 
  
 
==References==
 
==References==

Revision as of 15:10, 3 December 2014