diff --git a/content/posts/2021-10.md b/content/posts/2021-10.md
index 4687f4c70..b0d2601bb 100644
--- a/content/posts/2021-10.md
+++ b/content/posts/2021-10.md
@@ -330,8 +330,42 @@ $ psql -h localhost -p 5433 -U postgres dspace7 -c "DELETE FROM schema_version W
```
- Now DSpace 7 starts with my CGSpace data... nice
+ - The Discovery indexing still takes seven hours... fuck
- I tested the `metadata-export` on DSpace 7.1-SNAPSHOT and it still has the duplicate items issue introduced by DS-4211
- I filed a GitHub issue and notified nwoodward: https://github.com/DSpace/DSpace/issues/7988
- Start a full reindex on AReS
+## 2021-10-11
+
+- Start a full Discovery reindex on my local DSpace 6.3 instance:
+
+```console
+$ /usr/bin/time -f %M:%e chrt -b 0 ~/dspace63/bin/dspace index-discovery -b
+Loading @mire database changes for module MQM
+Changes have been processed
+836140:6543.6
+```
+
+- So that's 1.8 hours versus 7 on DSpace 7, with the same database!
+- Several users wrote to me that CGSpace was slow recently
+ - Looking at the PostgreSQL database I see connections look normal, but locks for `dspaceWeb` are high:
+
+```console
+$ psql -c 'SELECT * FROM pg_stat_activity' | wc -l
+53
+$ psql -c "SELECT * FROM pg_locks pl LEFT JOIN pg_stat_activity psa ON pl.pid = psa.pid" | wc -l
+1697
+$ psql -c "SELECT * FROM pg_locks pl LEFT JOIN pg_stat_activity psa ON pl.pid = psa.pid WHERE application_name='dspaceWeb'" | wc -l
+1681
+```
+
+- Looking at Munin, I see there are indeed a higher number of locks starting on the morning of 2021-10-07:
+
+![PostgreSQL locks week](/cgspace-notes/2021/10/postgres_locks_ALL-week.png)
+
+- The only thing I did on 2021-10-07 was import a few thousand metadata corrections...
+- I restarted PostgreSQL (instead of restarting Tomcat), so let's see if that helps
+- I filed [a bug for the DSpace 6/7 duplicate values metadata import issue](https://github.com/DSpace/DSpace/issues/7989)
+- I tested the two patches for removing abandoned submissions from the workflow but unfortunately it seems that they are for the configurable aka XML workflow, and we are using the basic workflow
+
diff --git a/docs/2021-10/index.html b/docs/2021-10/index.html
index 1b0ffe590..ca8366f15 100644
--- a/docs/2021-10/index.html
+++ b/docs/2021-10/index.html
@@ -25,7 +25,7 @@ So we have 1879/7100 (26.46%) matching already
-
+
@@ -56,9 +56,9 @@ So we have 1879/7100 (26.46%) matching already
"@type": "BlogPosting",
"headline": "October, 2021",
"url": "https://alanorth.github.io/cgspace-notes/2021-10/",
- "wordCount": "2199",
+ "wordCount": "2424",
"datePublished": "2021-10-01T11:14:07+03:00",
- "dateModified": "2021-10-09T22:00:59+03:00",
+ "dateModified": "2021-10-10T16:01:27+03:00",
"author": {
"@type": "Person",
"name": "Alan Orth"
@@ -453,7 +453,11 @@ $ psql -h localhost -p 5433 -U postgres -c 'alter user dspacetest nosuperuser;'
$ psql -h localhost -p 5433 -U postgres dspace7 -c "DELETE FROM schema_version WHERE description LIKE '%Atmire%' OR description LIKE '%CUA%' OR description LIKE '%cua%';"
$ psql -h localhost -p 5433 -U postgres dspace7 -c "DELETE FROM schema_version WHERE version IN ('5.0.2017.09.25', '6.0.2017.01.30', '6.0.2017.09.25');"
-- Now DSpace 7 starts with my CGSpace data… nice
+- Now DSpace 7 starts with my CGSpace data… nice
+
+- The Discovery indexing still takes seven hours… fuck
+
+
- I tested the
metadata-export
on DSpace 7.1-SNAPSHOT and it still has the duplicate items issue introduced by DS-4211
- Start a full reindex on AReS
+2021-10-11
+
+- Start a full Discovery reindex on my local DSpace 6.3 instance:
+
+$ /usr/bin/time -f %M:%e chrt -b 0 ~/dspace63/bin/dspace index-discovery -b
+Loading @mire database changes for module MQM
+Changes have been processed
+836140:6543.6
+
+- So that’s 1.8 hours versus 7 on DSpace 7, with the same database!
+- Several users wrote to me that CGSpace was slow recently
+
+- Looking at the PostgreSQL database I see connections look normal, but locks for
dspaceWeb
are high:
+
+
+
+$ psql -c 'SELECT * FROM pg_stat_activity' | wc -l
+53
+$ psql -c "SELECT * FROM pg_locks pl LEFT JOIN pg_stat_activity psa ON pl.pid = psa.pid" | wc -l
+1697
+$ psql -c "SELECT * FROM pg_locks pl LEFT JOIN pg_stat_activity psa ON pl.pid = psa.pid WHERE application_name='dspaceWeb'" | wc -l
+1681
+
+- Looking at Munin, I see there are indeed a higher number of locks starting on the morning of 2021-10-07:
+
+
+
+- The only thing I did on 2021-10-07 was import a few thousand metadata corrections…
+- I restarted PostgreSQL (instead of restarting Tomcat), so let’s see if that helps
+- I filed a bug for the DSpace 6/7 duplicate values metadata import issue
+- I tested the two patches for removing abandoned submissions from the workflow but unfortunately it seems that they are for the configurable aka XML workflow, and we are using the basic workflow
+
diff --git a/docs/2021/10/postgres_locks_ALL-week.png b/docs/2021/10/postgres_locks_ALL-week.png
new file mode 100644
index 000000000..6e5b981a1
Binary files /dev/null and b/docs/2021/10/postgres_locks_ALL-week.png differ
diff --git a/docs/categories/index.html b/docs/categories/index.html
index f1cbee13b..6cf147913 100644
--- a/docs/categories/index.html
+++ b/docs/categories/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/categories/notes/index.html b/docs/categories/notes/index.html
index 63ea8d045..1806b0452 100644
--- a/docs/categories/notes/index.html
+++ b/docs/categories/notes/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/categories/notes/page/2/index.html b/docs/categories/notes/page/2/index.html
index ff553562a..25a8903bf 100644
--- a/docs/categories/notes/page/2/index.html
+++ b/docs/categories/notes/page/2/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/categories/notes/page/3/index.html b/docs/categories/notes/page/3/index.html
index 0480cfe38..2e1427f71 100644
--- a/docs/categories/notes/page/3/index.html
+++ b/docs/categories/notes/page/3/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/categories/notes/page/4/index.html b/docs/categories/notes/page/4/index.html
index c79390198..be9f3308f 100644
--- a/docs/categories/notes/page/4/index.html
+++ b/docs/categories/notes/page/4/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/categories/notes/page/5/index.html b/docs/categories/notes/page/5/index.html
index 7ecd3e682..018e4fa79 100644
--- a/docs/categories/notes/page/5/index.html
+++ b/docs/categories/notes/page/5/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/categories/notes/page/6/index.html b/docs/categories/notes/page/6/index.html
index 6429a99b7..31ed05c36 100644
--- a/docs/categories/notes/page/6/index.html
+++ b/docs/categories/notes/page/6/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/index.html b/docs/index.html
index c88e2fe96..17ad1478a 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/2/index.html b/docs/page/2/index.html
index ee0063e8e..6987e6272 100644
--- a/docs/page/2/index.html
+++ b/docs/page/2/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/3/index.html b/docs/page/3/index.html
index 04930b604..c8322fbaf 100644
--- a/docs/page/3/index.html
+++ b/docs/page/3/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/4/index.html b/docs/page/4/index.html
index 5bfd39a2c..e4b7c7384 100644
--- a/docs/page/4/index.html
+++ b/docs/page/4/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/5/index.html b/docs/page/5/index.html
index 8f69009ca..30b67000a 100644
--- a/docs/page/5/index.html
+++ b/docs/page/5/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/6/index.html b/docs/page/6/index.html
index 6e70160a1..43617e40a 100644
--- a/docs/page/6/index.html
+++ b/docs/page/6/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/7/index.html b/docs/page/7/index.html
index 381109930..96c78b516 100644
--- a/docs/page/7/index.html
+++ b/docs/page/7/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/page/8/index.html b/docs/page/8/index.html
index 71e31a9e9..eef8a0513 100644
--- a/docs/page/8/index.html
+++ b/docs/page/8/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/index.html b/docs/posts/index.html
index 1da2d55a6..270f2bba0 100644
--- a/docs/posts/index.html
+++ b/docs/posts/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/2/index.html b/docs/posts/page/2/index.html
index 549891c60..47c0e1f4b 100644
--- a/docs/posts/page/2/index.html
+++ b/docs/posts/page/2/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/3/index.html b/docs/posts/page/3/index.html
index 32cedf27e..c6f2939a9 100644
--- a/docs/posts/page/3/index.html
+++ b/docs/posts/page/3/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/4/index.html b/docs/posts/page/4/index.html
index a9138a319..ca0fea8ff 100644
--- a/docs/posts/page/4/index.html
+++ b/docs/posts/page/4/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/5/index.html b/docs/posts/page/5/index.html
index 2a0731980..e3c5c8854 100644
--- a/docs/posts/page/5/index.html
+++ b/docs/posts/page/5/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/6/index.html b/docs/posts/page/6/index.html
index d9751d657..5b434edaf 100644
--- a/docs/posts/page/6/index.html
+++ b/docs/posts/page/6/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/7/index.html b/docs/posts/page/7/index.html
index aadfd79c9..717cec791 100644
--- a/docs/posts/page/7/index.html
+++ b/docs/posts/page/7/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/posts/page/8/index.html b/docs/posts/page/8/index.html
index 22043dfee..e52a682f8 100644
--- a/docs/posts/page/8/index.html
+++ b/docs/posts/page/8/index.html
@@ -10,7 +10,7 @@
-
+
diff --git a/docs/sitemap.xml b/docs/sitemap.xml
index 3ad4aa91e..b6921ff9f 100644
--- a/docs/sitemap.xml
+++ b/docs/sitemap.xml
@@ -3,19 +3,19 @@
xmlns:xhtml="http://www.w3.org/1999/xhtml">
https://alanorth.github.io/cgspace-notes/categories/
- 2021-10-09T22:00:59+03:00
+ 2021-10-10T16:01:27+03:00
https://alanorth.github.io/cgspace-notes/
- 2021-10-09T22:00:59+03:00
+ 2021-10-10T16:01:27+03:00
https://alanorth.github.io/cgspace-notes/categories/notes/
- 2021-10-09T22:00:59+03:00
+ 2021-10-10T16:01:27+03:00
https://alanorth.github.io/cgspace-notes/2021-10/
- 2021-10-09T22:00:59+03:00
+ 2021-10-10T16:01:27+03:00
https://alanorth.github.io/cgspace-notes/posts/
- 2021-10-09T22:00:59+03:00
+ 2021-10-10T16:01:27+03:00
https://alanorth.github.io/cgspace-notes/2021-09/
2021-10-04T11:10:54+03:00
diff --git a/static/2021/10/postgres_locks_ALL-week.png b/static/2021/10/postgres_locks_ALL-week.png
new file mode 100644
index 000000000..6e5b981a1
Binary files /dev/null and b/static/2021/10/postgres_locks_ALL-week.png differ