mirror of
https://github.com/alanorth/cgspace-notes.git
synced 2024-12-22 21:22:19 +01:00
402 lines
17 KiB
HTML
402 lines
17 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en" >
|
|
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
|
|
|
<meta property="og:title" content="CGSpace DSpace 6 Upgrade" />
|
|
<meta property="og:description" content="Documenting the DSpace 6 upgrade." />
|
|
<meta property="og:type" content="article" />
|
|
<meta property="og:url" content="https://alanorth.github.io/cgspace-notes/cgspace-dspace6-upgrade/" />
|
|
<meta property="article:published_time" content="2020-11-15T13:27:35+02:00" />
|
|
<meta property="article:modified_time" content="2020-11-15T13:27:35+02:00" />
|
|
|
|
<meta name="twitter:card" content="summary"/>
|
|
<meta name="twitter:title" content="CGSpace DSpace 6 Upgrade"/>
|
|
<meta name="twitter:description" content="Documenting the DSpace 6 upgrade."/>
|
|
<meta name="generator" content="Hugo 0.78.1" />
|
|
|
|
|
|
|
|
<script type="application/ld+json">
|
|
{
|
|
"@context": "http://schema.org",
|
|
"@type": "BlogPosting",
|
|
"headline": "CGSpace DSpace 6 Upgrade",
|
|
"url": "https://alanorth.github.io/cgspace-notes/cgspace-dspace6-upgrade/",
|
|
"wordCount": "878",
|
|
"datePublished": "2020-11-15T13:27:35+02:00",
|
|
"dateModified": "2020-11-15T13:27:35+02:00",
|
|
"author": {
|
|
"@type": "Person",
|
|
"name": "Alan Orth"
|
|
},
|
|
"keywords": "Notes, Migration",
|
|
"description": "Documenting the DSpace 6 upgrade."
|
|
}
|
|
</script>
|
|
|
|
|
|
|
|
<link rel="canonical" href="https://alanorth.github.io/cgspace-notes/cgspace-dspace6-upgrade/">
|
|
|
|
<title>CGSpace DSpace 6 Upgrade | CGSpace Notes</title>
|
|
|
|
|
|
<!-- combined, minified CSS -->
|
|
|
|
<link href="https://alanorth.github.io/cgspace-notes/css/style.d20c61b183eb27beb5b2c48f70a38b91c8bb5fb929e77b447d5f77c7285221ad.css" rel="stylesheet" integrity="sha256-0gxhsYPrJ761ssSPcKOLkci7X7kp53tEfV93xyhSIa0=" crossorigin="anonymous">
|
|
|
|
|
|
<!-- minified Font Awesome for SVG icons -->
|
|
|
|
<script defer src="https://alanorth.github.io/cgspace-notes/js/fontawesome.min.4ed405d7c7002b970d34cbe6026ff44a556b0808cb98a9db4008752110ed964b.js" integrity="sha256-TtQF18cAK5cNNMvmAm/0SlVrCAjLmKnbQAh1IRDtlks=" crossorigin="anonymous"></script>
|
|
|
|
<!-- RSS 2.0 feed -->
|
|
|
|
|
|
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
|
|
<div class="blog-masthead">
|
|
<div class="container">
|
|
<nav class="nav blog-nav">
|
|
<a class="nav-link " href="https://alanorth.github.io/cgspace-notes/">Home</a>
|
|
</nav>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<header class="blog-header">
|
|
<div class="container">
|
|
<h1 class="blog-title" dir="auto"><a href="https://alanorth.github.io/cgspace-notes/" rel="home">CGSpace Notes</a></h1>
|
|
<p class="lead blog-description" dir="auto">Documenting day-to-day work on the <a href="https://cgspace.cgiar.org">CGSpace</a> repository.</p>
|
|
</div>
|
|
</header>
|
|
|
|
|
|
|
|
|
|
<div class="container">
|
|
<div class="row">
|
|
<div class="col-sm-8 blog-main">
|
|
|
|
|
|
|
|
|
|
<article class="blog-post">
|
|
<header>
|
|
<h2 class="blog-post-title" dir="auto"><a href="https://alanorth.github.io/cgspace-notes/cgspace-dspace6-upgrade/">CGSpace DSpace 6 Upgrade</a></h2>
|
|
<p class="blog-post-meta">
|
|
<time datetime="2020-11-15T13:27:35+02:00">Sun Nov 15, 2020</time>
|
|
in
|
|
<span class="fas fa-folder" aria-hidden="true"></span> <a href="/cgspace-notes/categories/notes/" rel="category tag">Notes</a>
|
|
|
|
|
|
<span class="fas fa-tag" aria-hidden="true"></span> <a href="/cgspace-notes/tags/migration/" rel="tag">Migration</a>
|
|
|
|
</p>
|
|
</header>
|
|
<p>Notes about the DSpace 6 upgrade on CGSpace in 2020-11.</p>
|
|
<ul>
|
|
<li><a href="#processing-solr-statistics-with-solr-upgrade-statistics-6x">Processing Solr Statistics With solr-upgrade-statistics-6x</a>
|
|
<ul>
|
|
<li><a href="#statistics">Current year’s statistics core</a></li>
|
|
<li><a href="#statistics-2019">statistics-2019 core</a></li>
|
|
<li><a href="#statistics-2018">statistics-2018 core</a></li>
|
|
<li><a href="#statistics-2017">statistics-2017 core</a></li>
|
|
<li><a href="#statistics-2016">statistics-2016 core</a></li>
|
|
<li><a href="#statistics-2015">statistics-2015 core</a></li>
|
|
<li><a href="#statistics-2014">statistics-2014 core</a></li>
|
|
<li><a href="#statistics-2013">statistics-2013 core</a></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<h2 id="processing-solr-statistics-with-solr-upgrade-statistics-6x">Processing Solr Statistics With solr-upgrade-statistics-6x</h2>
|
|
<p>After the main upgrade process was finished and DSpace was running I started processing the Solr statistics with <code>solr-upgrade-statistics-6x</code> to migrate all IDs to UUIDs.</p>
|
|
<h3 id="statistics">statistics</h3>
|
|
<p>First process the current year’s statistics core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ export JAVA_OPTS='-Dfile.encoding=UTF-8 -Xmx2048m'
|
|
$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
3,817,407 Bistream View
|
|
1,693,443 Item View
|
|
105,974 Collection View
|
|
62,383 Community View
|
|
163,192 Community Search
|
|
162,581 Collection Search
|
|
470,288 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
6,475,268 TOTAL
|
|
=================================================================
|
|
</code></pre><p>After several rounds of processing it finished. Here are some statistics about unmigrated documents:</p>
|
|
<ul>
|
|
<li>227,000: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>471,000: <code>id:/.+-unmigrated/</code></li>
|
|
<li>698,000: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>Majority are <code>type: 5</code> (aka SITE, according to <code>Constants.java</code>) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h3 id="statistics-2019">statistics-2019</h3>
|
|
<p>Processing the statistics-2019 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
5,569,344 Bistream View
|
|
2,179,105 Item View
|
|
117,194 Community View
|
|
104,091 Collection View
|
|
774,138 Community Search
|
|
568,347 Collection Search
|
|
1,482,620 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
10,794,839 TOTAL
|
|
=================================================================
|
|
</code></pre><p>After several rounds of processing it finished. Here are some statistics about unmigrated documents:</p>
|
|
<ul>
|
|
<li>2,690,309: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>1,494,587: <code>id:/.+-unmigrated/</code></li>
|
|
<li>4,184,896: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>4,172,929 are <code>type: 5</code> (aka SITE) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2019/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h3 id="statistics-2018">statistics-2018</h3>
|
|
<p>Processing the statistics-2018 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2018
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
3,561,532 Bistream View
|
|
1,129,326 Item View
|
|
97,401 Community View
|
|
63,508 Collection View
|
|
207,827 Community Search
|
|
43,752 Collection Search
|
|
457,820 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
5,561,166 TOTAL
|
|
=================================================================
|
|
</code></pre><p>After some time I got an error about Java heap space so I increased the JVM memory and restarted processing:</p>
|
|
<pre><code class="language-console" data-lang="console">$ export JAVA_OPTS='-Dfile.encoding=UTF-8 -Xmx4096m'
|
|
$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2018
|
|
</code></pre><p>Eventually the processing finished. Here are some statistics about unmigrated documents:</p>
|
|
<ul>
|
|
<li>365,473: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>546,955: <code>id:/.+-unmigrated/</code></li>
|
|
<li>923,158: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>823,293: are <code>type: 5</code> so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2018/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h2 id="statistics-2017">statistics-2017</h2>
|
|
<p>Processing the statistics-2017 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2017
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
2,529,208 Bistream View
|
|
1,618,717 Item View
|
|
144,945 Community View
|
|
74,249 Collection View
|
|
479,647 Community Search
|
|
114,658 Collection Search
|
|
852,215 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
5,813,639 TOTAL
|
|
=================================================================
|
|
</code></pre><p>Eventually the processing finished. Here are some statistics about unmigrated documents:</p>
|
|
<ul>
|
|
<li>808,309: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>893,868: <code>id:/.+-unmigrated/</code></li>
|
|
<li>1,702,177: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>1,660,524 are <code>type: 5</code> (SITE) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2017/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h3 id="statistics-2016">statistics-2016</h3>
|
|
<p>Processing the statistics-2016 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2016
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
1,765,924 Bistream View
|
|
1,151,575 Item View
|
|
187,110 Community View
|
|
51,204 Collection View
|
|
347,382 Community Search
|
|
66,605 Collection Search
|
|
620,298 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
4,190,098 TOTAL
|
|
=================================================================
|
|
</code></pre><ul>
|
|
<li>849,408: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>627,747: <code>id:/.+-unmigrated/</code></li>
|
|
<li>1,477,155: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>1,469,706 are <code>type: 5</code> (SITE) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2016/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h3 id="statistics-2015">statistics-2015</h3>
|
|
<p>Processing the statistics-2015 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2015
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
990,916 Bistream View
|
|
506,070 Item View
|
|
116,153 Community View
|
|
33,282 Collection View
|
|
21,062 Community Search
|
|
10,788 Collection Search
|
|
52,107 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
1,730,378 TOTAL
|
|
=================================================================
|
|
</code></pre><p>Summary of stats after processing:</p>
|
|
<ul>
|
|
<li>195,293: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>67,146: <code>id:/.+-unmigrated/</code></li>
|
|
<li>262,439: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>247,400 are <code>type: 5</code> (SITE) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2015/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h2 id="statistics-2014">statistics-2014</h2>
|
|
<p>Processing the statistics-2014 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2014
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
2,381,603 Item View
|
|
1,323,357 Bistream View
|
|
501,545 Community View
|
|
247,805 Collection View
|
|
250 Collection Search
|
|
188 Community Search
|
|
50 Item Search
|
|
10,918 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
4,465,716 TOTAL
|
|
=================================================================
|
|
</code></pre><p>Summary of unmigrated documents after processing:</p>
|
|
<ul>
|
|
<li>182,131: <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>39,947: <code>id:/.+-unmigrated/</code></li>
|
|
<li>222,078: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>188,791 are <code>type: 5</code> (SITE) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2014/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre><h2 id="statistics-2013">statistics-2013</h2>
|
|
<p>Processing the statistics-2013 core:</p>
|
|
<pre><code class="language-console" data-lang="console">$ chrt -b 0 dspace solr-upgrade-statistics-6x -n 2500000 -i statistics-2013
|
|
...
|
|
=================================================================
|
|
*** Statistics Records with Legacy Id ***
|
|
|
|
2,352,124 Item View
|
|
1,117,676 Bistream View
|
|
575,711 Community View
|
|
171,639 Collection View
|
|
248 Item Search
|
|
7 Collection Search
|
|
5 Community Search
|
|
1,452 Unexpected Type & Full Site
|
|
--------------------------------------
|
|
4,218,862 TOTAL
|
|
=================================================================
|
|
</code></pre><p>Summary of unmigrated docs after processing:</p>
|
|
<ul>
|
|
<li>2,548 : <code>(*:* NOT id:/.{36}/) AND (*:* NOT id:/.+-unmigrated/)</code></li>
|
|
<li>29,772: <code>id:/.+-unmigrated/</code></li>
|
|
<li>32,320: <code>*:* NOT id:/.{36}/</code></li>
|
|
<li>15,691 are <code>type: 5</code> (SITE) so we can purge them:</li>
|
|
</ul>
|
|
<pre><code class="language-console" data-lang="console">$ curl -s "http://localhost:8081/solr/statistics-2013/update?softCommit=true" -H "Content-Type: text/xml" --data-binary "<delete><query>*:* NOT id:/.{36}/</query></delete>"
|
|
</code></pre>
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
|
|
|
|
|
|
</div> <!-- /.blog-main -->
|
|
|
|
<aside class="col-sm-3 ml-auto blog-sidebar">
|
|
|
|
|
|
|
|
<section class="sidebar-module">
|
|
<h4>Recent Posts</h4>
|
|
<ol class="list-unstyled">
|
|
|
|
|
|
<li><a href="/cgspace-notes/cgspace-dspace6-upgrade/">CGSpace DSpace 6 Upgrade</a></li>
|
|
|
|
<li><a href="/cgspace-notes/2020-11/">November, 2020</a></li>
|
|
|
|
<li><a href="/cgspace-notes/2020-10/">October, 2020</a></li>
|
|
|
|
<li><a href="/cgspace-notes/2020-09/">September, 2020</a></li>
|
|
|
|
<li><a href="/cgspace-notes/2020-08/">August, 2020</a></li>
|
|
|
|
</ol>
|
|
</section>
|
|
|
|
|
|
|
|
|
|
<section class="sidebar-module">
|
|
<h4>Links</h4>
|
|
<ol class="list-unstyled">
|
|
|
|
<li><a href="https://cgspace.cgiar.org">CGSpace</a></li>
|
|
|
|
<li><a href="https://dspacetest.cgiar.org">DSpace Test</a></li>
|
|
|
|
<li><a href="https://github.com/ilri/DSpace">CGSpace @ GitHub</a></li>
|
|
|
|
</ol>
|
|
</section>
|
|
|
|
</aside>
|
|
|
|
|
|
</div> <!-- /.row -->
|
|
</div> <!-- /.container -->
|
|
|
|
|
|
|
|
<footer class="blog-footer">
|
|
<p dir="auto">
|
|
|
|
Blog template created by <a href="https://twitter.com/mdo">@mdo</a>, ported to Hugo by <a href='https://twitter.com/mralanorth'>@mralanorth</a>.
|
|
|
|
</p>
|
|
<p>
|
|
<a href="#">Back to top</a>
|
|
</p>
|
|
</footer>
|
|
|
|
|
|
</body>
|
|
|
|
</html>
|