diff --git a/content/posts/2018-12.md b/content/posts/2018-12.md index ce273d8d2..f47bbcd02 100644 --- a/content/posts/2018-12.md +++ b/content/posts/2018-12.md @@ -421,5 +421,68 @@ $ ls -lh cgspace_2018-12-19.backup* ``` - Looks like it's really not worth it... +- Peter pointed out that Discovery filters for CTA subjects on item pages were not working +- It looks like there were some mismatches in the Discovery index names and the XMLUI configuration, so I fixed them ([#406](https://github.com/ilri/DSpace/pull/406)) +- Peter asked if we could create a controlled vocabulary for publishers (`dc.publisher`) +- I see we have about 3500 distinct publishers: + +``` +# SELECT COUNT(DISTINCT(text_value)) FROM metadatavalue WHERE resource_type_id=2 AND metadata_field_id=39; + count +------- + 3522 +(1 row) +``` + +- I reverted the metadata changes related to "Unrestricted Access" and "Restricted Access" on DSpace Test because we're not pushing forward with the new status terms for now +- Purge remaining Oracle Java 8 stuff from CGSpace (linode18) since we migrated to OpenJDK a few months ago: + +``` +# dpkg -P oracle-java8-installer oracle-java8-set-default +``` + +- Update usage rights on CGSpace as we agreed with Maria Garruccio and Peter last month: + +``` +$ ./fix-metadata-values.py -i /tmp/2018-11-27-update-rights.csv -f dc.rights -t correct -m 53 -db dspace -u dspace -p 'fuu' -d +Connected to database. +Fixed 466 occurences of: Copyrighted; Any re-use allowed +``` + +- Upgrade PostgreSQL on CGSpace (linode18) from 9.5 to 9.6: + +``` +# apt install postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.6 postgresql-server-dev-9.6 +# pg_ctlcluster 9.5 main stop +# tar -cvzpf var-lib-postgresql-9.5.tar.gz /var/lib/postgresql/9.5 +# tar -cvzpf etc-postgresql-9.5.tar.gz /etc/postgresql/9.5 +# pg_ctlcluster 9.6 main stop +# pg_dropcluster 9.6 main +# pg_upgradecluster 9.5 main +# pg_dropcluster 9.5 main +# dpkg -l | grep postgresql | grep 9.5 | awk '{print $2}' | xargs dpkg -r +``` + +- I've been running PostgreSQL 9.6 for months on my local development and public DSpace Test (linode19) environments +- Run all system updates on CGSpace (linode18) and restart the server +- Try to run the DSpace cleanup script on CGSpace (linode18), but I get some errors about foreign key constraints: + +``` +$ dspace cleanup -v + - Deleting bitstream information (ID: 158227) + - Deleting bitstream record from database (ID: 158227) +Error: ERROR: update or delete on table "bitstream" violates foreign key constraint "bundle_primary_bitstream_id_fkey" on table "bundle" + Detail: Key (bitstream_id)=(158227) is still referenced from table "bundle". +... +``` + +- As always, the solution is to delete those IDs manually in PostgreSQL: + +``` +$ psql dspace -c 'update bundle set primary_bitstream_id=NULL where primary_bitstream_id in (158227, 158251);' +UPDATE 1 +``` + +- After all that I started a full Discovery reindex to get the index name changes and rights updates diff --git a/docs/2018-12/index.html b/docs/2018-12/index.html index ac25bfb64..d022bee2e 100644 --- a/docs/2018-12/index.html +++ b/docs/2018-12/index.html @@ -21,7 +21,7 @@ I noticed that there is another issue with PDF thumbnails on CGSpace, and I see " /> - + @@ -48,9 +48,9 @@ I noticed that there is another issue with PDF thumbnails on CGSpace, and I see "@type": "BlogPosting", "headline": "December, 2018", "url": "https://alanorth.github.io/cgspace-notes/2018-12/", - "wordCount": "2576", + "wordCount": "2940", "datePublished": "2018-12-02T02:09:30+02:00", - "dateModified": "2018-12-19T11:05:04+02:00", + "dateModified": "2018-12-20T12:56:16+02:00", "author": { "@type": "Person", "name": "Alan Orth" @@ -599,6 +599,75 @@ $ ls -lh cgspace_2018-12-19.backup* + +
# SELECT COUNT(DISTINCT(text_value)) FROM metadatavalue WHERE resource_type_id=2 AND metadata_field_id=39;
+ count
+-------
+  3522
+(1 row)
+
+ + + +
# dpkg -P oracle-java8-installer oracle-java8-set-default
+
+ + + +
$ ./fix-metadata-values.py -i /tmp/2018-11-27-update-rights.csv -f dc.rights -t correct -m 53 -db dspace -u dspace -p 'fuu' -d
+Connected to database.
+Fixed 466 occurences of: Copyrighted; Any re-use allowed
+
+ + + +
# apt install postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.6 postgresql-server-dev-9.6
+# pg_ctlcluster 9.5 main stop
+# tar -cvzpf var-lib-postgresql-9.5.tar.gz /var/lib/postgresql/9.5
+# tar -cvzpf etc-postgresql-9.5.tar.gz /etc/postgresql/9.5
+# pg_ctlcluster 9.6 main stop
+# pg_dropcluster 9.6 main
+# pg_upgradecluster 9.5 main
+# pg_dropcluster 9.5 main
+# dpkg -l | grep postgresql | grep 9.5 | awk '{print $2}' | xargs dpkg -r
+
+ + + +
$ dspace cleanup -v
+ - Deleting bitstream information (ID: 158227)
+ - Deleting bitstream record from database (ID: 158227)
+Error: ERROR: update or delete on table "bitstream" violates foreign key constraint "bundle_primary_bitstream_id_fkey" on table "bundle"
+  Detail: Key (bitstream_id)=(158227) is still referenced from table "bundle".
+...
+
+ + + +
$ psql dspace -c 'update bundle set primary_bitstream_id=NULL where primary_bitstream_id in (158227, 158251);'
+UPDATE 1
+
+ + diff --git a/docs/sitemap.xml b/docs/sitemap.xml index ea9989c37..3ca8e603b 100644 --- a/docs/sitemap.xml +++ b/docs/sitemap.xml @@ -4,7 +4,7 @@ https://alanorth.github.io/cgspace-notes/2018-12/ - 2018-12-19T11:05:04+02:00 + 2018-12-20T12:56:16+02:00 @@ -199,7 +199,7 @@ https://alanorth.github.io/cgspace-notes/ - 2018-12-19T11:05:04+02:00 + 2018-12-20T12:56:16+02:00 0 @@ -210,7 +210,7 @@ https://alanorth.github.io/cgspace-notes/tags/notes/ - 2018-12-19T11:05:04+02:00 + 2018-12-20T12:56:16+02:00 0 @@ -222,13 +222,13 @@ https://alanorth.github.io/cgspace-notes/posts/ - 2018-12-19T11:05:04+02:00 + 2018-12-20T12:56:16+02:00 0 https://alanorth.github.io/cgspace-notes/tags/ - 2018-12-19T11:05:04+02:00 + 2018-12-20T12:56:16+02:00 0