To add SOLR access permissions in tomcat6, follow these steps:
Edit tomcat6/Catalina/localhost/SOLR. xml
< Context Docbase = "/Var/SOLR. War" Debug = "0" Privileged = "True" Allowlinking = "True" Crosscontext = "True" >
< Environment Name = "SOLR/home" Type = "Java. Lang. String" Value = "/Var/SOLR" Override = "True" />
< Valve Classname = "Org. Apache. Catalina. Valves. remoteaddrvalve" Allow = "192.168.1.100, localhost, 192.168.1.103, 127.0.0.1" />
< Valve Classname = "Org. Apache. Catalina. Valves. remoteaddrvalve" Deny = "192.168.1.105" />
</ Context >
Refer to Tomcat configuration document: http://tomcat.apache.org/tomcat-6.0-doc/config/valve.html#Remote_Address_Filter
To make the preceding configuration take effect, you need to re-enable the tomcat security mechanism.
Edit sudo VI/etc/default/tomcat6
Comment out the last sentenceTomcat6_security = No
For more information about security mechanisms, refer to SOLR wiki: http://wiki.apache.org/solr/SolrSecurity