title: Cloudera to HDP SOLR(version 5.5.2) Data Migration | Failed to Update solr indexes after restoration on solr cloud
body: <p>SOLR version - 5.5.2</p>
  
  <p>My Project requirement is to transfer solr cloud indexes from cloudera cluster to HDP cluster.  </p>
  
  <ul>
  <li>Data is huge(1 billion indexed records on production), hence re-indexing is not an option.</li>
  </ul>
  
  <p>We have tried solr restore and backup APIs but data is not visible on cloud. Please check if we are missing any step from below ==></p>
  
  <p>1) <strong>Allowed snapshot</strong> (Cloudera cluster) :<br>
  sudo -u hdfs hadoop dfsadmin -allowSnapshot /user/solr/CollectionName</p>
  
  <p>2) <strong>Created snapshot</strong> :<br>
  sudo -u hdfs hadoop dfs -createSnapshot /user/solr/CollectionName/</p>
  
  <p>3) <strong>Created solr collection on HDP cluster</strong> : with same name, same number of shards and replicas.</p>
  
  <p>4) <strong>Used “distcp” to transfer snapshot</strong> :<br>
  sudo -u solr hadoop distcp hdfs://NameNodeCDH-IP:8020/user/solr/CDHCollectionName/.snapshot/s20180601-131020.000  hdfs://NameNodeHDP-IP:8020/user/solr</p>
  
  <p>5) <strong>Restore snapshot on collection level</strong> :<br>
  sudo -u solr hadoop fs -cp /user/solr/s20180601-131020.000/* /user/solr/HDPCollectionName/
  Restored snapshot from /user/solr to collection directory for each shard and replica.</p>
  
  <p><strong>OUTCOME</strong> : HDFS directory restored but DATA not visible on SOLR UI. 0 records displayed. Checked HDFS directory using-<br>
  sudo hadoop fs -du -s -h /user/solr/HDPCollectionName/</p>
  
  <p><a href="https://i.stack.imgur.com/oi4gR.png" rel="nofollow noreferrer">HDP SOLR Data directory size - </a></p>
  
  <p><a href="https://i.stack.imgur.com/12qhC.jpg" rel="nofollow noreferrer">SOLR CLOUD DATA SIZE - ZERO 0</a></p>