{"id":3805,"date":"2016-04-18T12:06:28","date_gmt":"2016-04-18T12:06:28","guid":{"rendered":"http:\/\/www.garysieling.com\/blog\/?p=3805"},"modified":"2016-04-18T12:06:28","modified_gmt":"2016-04-18T12:06:28","slug":"fixing-solr-error-varsolrdatacore_namedataindexwrite-lock","status":"publish","type":"post","link":"https:\/\/www.garysieling.com\/blog\/fixing-solr-error-varsolrdatacore_namedataindexwrite-lock\/","title":{"rendered":"Fixing solr error: &#8220;\/var\/solr\/data\/core_name\/data\/index\/write.lock&#8221;"},"content":{"rendered":"<p>If you deploy a new core in Solr from a backup, you can get this cryptic error:<\/p>\n<pre>\ncore_name: \norg.apache.solr.common.SolrException:org.apache.solr.common.SolrException: \n\/var\/solr\/data\/core_name\/data\/index\/write.lock\n<\/pre>\n<p>This means Solr can&#8217;t write the file it uses to monitor locks. Most likely this is due to files having the wrong ownership.<\/p>\n<p>Navigate to the path on the machine listed, and do this &#8211; you&#8217;ll see the correct user information on other files.<\/p>\n<pre lang=\"bash\">\nls -al\n<\/pre>\n<p>Then you can run this (my solr user is &#8220;solr&#8221;)<\/p>\n<pre lang=\"bash\">\nchown -R solr:solr core_name\n<\/pre>\n<p>And restart solr:<\/p>\n<pre lang=\"bash\">\n\/etc\/init.d\/solr restart\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Fix an error deploying a solr core<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[9],"tags":[338,517,559],"aioseo_notices":[],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/3805"}],"collection":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/comments?post=3805"}],"version-history":[{"count":0,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/3805\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/media?parent=3805"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/categories?post=3805"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/tags?post=3805"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}