On 2022-11-27 19:36, Jan Eden wrote:
On 2022-11-27 08:01, Mark Sapiro wrote:
On 11/27/22 00:35, Jan Eden via Mailman-users wrote:
– but the existing directory /opt/mailman/fulltext_index (and its contents) are readable and writeable by mailman:mailman:
drwxrwxr-x 2 mailman mailman 4096 Nov 27 08:00 fulltext_index/
-rw-rw-r-- 1 mailman mailman 4473 Nov 27 08:00 _MAIN_65.toc -rw-rw-r-- 1 mailman mailman 15456 Nov 27 08:00 MAIN_bc0cs2aohovftat6.seg -rw-rw-r-- 1 mailman mailman 15454 Nov 27 06:00 MAIN_brbo8i8edmlz0za4.seg -rw-rw-r-- 1 mailman mailman 15462 Nov 27 07:00 MAIN_ewnemc7lsnodd3y7.seg -rw-rw-r-- 1 mailman mailman 157324 Nov 27 04:00 MAIN_qag60g1rrumshtc2.seg -rw-rw-r-- 1 mailman mailman 15459 Nov 27 05:00 MAIN_w6e0ohurasusy61d.seg -rwxrwxr-x 1 mailman mailman 0 Nov 24 16:00 MAIN_WRITELOCK*
I fail to see where haystack tries (and fails) to create the directory. FWIW, deleting threads is not a problem.
It is uwsgi trying to do this. What user is it running as? Maybe you need to add that user to the
mailman
group.That's what baffles me – uwsgi is run as the mailman user:
mailman 3904667 1.3 0.5 129516 62188 ? Ss 18:33 0:00 /opt/mailman/venv/bin/uwsgi --ini /etc/mailman3/uwsgi.ini mailman 3904668 0.0 0.3 203248 48796 ? Sl 18:33 0:00 /opt/mailman/venv/bin/uwsgi --ini /etc/mailman3/uwsgi.ini mailman 3904670 0.8 0.6 220436 74464 ? Sl 18:33 0:00 /opt/mailman/venv/bin/uwsgi --ini /etc/mailman3/uwsgi.ini
I tried setting permissions on /opt/mailman/fulltext_index to 777 temporarily, but the issue remained (as expected). It occurs in the Whoosh backend of Haystack (whoosh_backend.py, line 132-133):
if self.use_file_storage and not os.path.exists(self.path):
os.makedirs(self.path)
where self.path is referenced, which is defined in line 110 (as part of the __init__ function):
def __init__(self, connection_alias, **connection_options): super().__init__(connection_alias, **connection_options) self.setup_complete = False self.use_file_storage = True self.post_limit = getattr(connection_options, "POST_LIMIT", 128 * 1024 * 1024) self.path = connection_options.get("PATH")
Unfortunately, I cannot see where the PATH key for connection_options is defined.
- Jan