Hello, Our infrastructure: VM Debian 11 Mailman3 3.3.3-1 from BullsEye Main repository We have recently been receiving this kind of messages from CRON with the execution of "mailman gatenews" : —————————————————————————————————————————————————— Traceback (most recent call last): File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 321, in lock os.link <http://os.link/>(self._claimfile, self._lockfile) FileExistsError: [Errno 17] File exists: '/var/lib/mailman3/locks/dbcreate.lck|listesman.int.cines.teledetection.fr <http://listesman.int.cines.teledetection.fr/>|466566|5365511256557879875' -> '/var/lib/mailman3/locks/dbcreate.lck' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/bin/mailman", line 33, in <module> sys.exit(load_entry_point('mailman==3.3.3', 'console_scripts', 'mailman')()) File "/usr/lib/python3/dist-packages/click/core.py", line 829, in __call__ return self.main(*args, **kwargs) File "/usr/lib/python3/dist-packages/click/core.py", line 781, in main with self.make_context(prog_name, args, **extra) as ctx: File "/usr/lib/python3/dist-packages/click/core.py", line 700, in make_context self.parse_args(ctx, args) File "/usr/lib/python3/dist-packages/click/core.py", line 1212, in parse_args rest = Command.parse_args(self, ctx, args) File "/usr/lib/python3/dist-packages/click/core.py", line 1048, in parse_args value, args = param.handle_parse_result(ctx, opts, args) File "/usr/lib/python3/dist-packages/click/core.py", line 1630, in handle_parse_result value = invoke_param_callback(self.callback, ctx, self, value) File "/usr/lib/python3/dist-packages/click/core.py", line 123, in invoke_param_callback return callback(ctx, param, value) File "/usr/lib/python3/dist-packages/mailman/bin/mailman.py", line 94, in initialize_config initialize(value) File "/usr/lib/python3/dist-packages/mailman/core/initialize.py", line 218, in initialize initialize_2(propagate_logs=propagate_logs) File "/usr/lib/python3/dist-packages/mailman/core/initialize.py", line 177, in initialize_2 config.db = getUtility(IDatabaseFactory, utility_name).create() File "/usr/lib/python3/dist-packages/mailman/database/factory.py", line 50, in create with Lock(os.path.join(config.LOCK_DIR, 'dbcreate.lck')): File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 439, in __enter__ self.lock() File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 353, in lock elif self._read() == self._claimfile: File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 502, in _read with open(self._lockfile) as fp: PermissionError: [Errno 13] Permission denied: '/var/lib/mailman3/locks/dbcreate.lck' —————————————————————————————————————————————————— CRON content: —————————————————————————————————————————————————— # /etc/cron.d/mailman3: crontab entries for the mailman3 package SHELL=/bin/sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin # At 8AM, send out notifices of pending requests to list moderators 0 8 * * * list if [ -x /usr/bin/mailman ]; then /usr/bin/mailman notify; fi # At 12AM, send mail digests for lists that do periodic as well as threshold delivery 0 12 * * * list if [ -x /usr/bin/mailman ]; then /usr/bin/mailman digests --periodic; fi # Every 15 minutes, gate messages from usenet to those lists which have the gateway configured */15 * * * * list if [ -x /usr/bin/mailman ]; then /usr/bin/mailman gatenews; fi —————————————————————————————————————————————————— I thought, given the last line, a problem of rights. It is not the case ! The directory and the files contained in /var/lib/mailman3/locks belong to the user "list". When I run "/usr/bin/mailman gatenews" by hand everything is correct. The questions I have are these: We have 8000 files "dbcreate.lck..." in the directory "/var/lib/mailman3/locks". What are they for? Can we delete them? We have 2 files "master.lck..." dated from the day after tomorrow ! What is this date? Aren't these files the problem? Thanks for your help -- Pierre Malard Responsable architectures système CDS DINAMIS/THEIA Montpellier IRD - UMR Espace-Dev - UAR CPST - IR Data-Terra Maison de la Télédétection 500 rue Jean-François Breton 34093 Montpellier Cx 5 France À propos de nos chers économistes : «Les habiles, dans notre siècle, se sont décernés a eux-mêmes la qualification d’homme d’état. [...] ces politiques, ingénieux a mettre aux fictions profitables un masque de nécessité.» Victor Hugo : “Les misérables”, La pléiade, Gallimard, P. 843 |\ _,,,---,,_ /,`.-'`' -. ;-;;,_ |,4- ) )-,_. ,\ ( `'-' '---''(_/--' `-'\_) πr perl -e '$_=q#: 3|\ 5_,3-3,2_: 3/,`.'"'"'`'"'"' 5-. ;-;;,_: |,A- ) )-,_. ,\ ( `'"'"'-'"'"': '"'"'-3'"'"'2(_/--'"'"' `-'"'"'\_): 24πr::#;y#:#\n#;s#(\D)(\d+)#$1x$2#ge;print' - --> Ce message n’engage que son auteur <-- -- Pierre Malard Responsable architectures système CDS DINAMIS/THEIA Montpellier IRD - UMR Espace-Dev - UAR CPST - IR Data-Terra Maison de la Télédétection 500 rue Jean-François Breton 34093 Montpellier Cx 5 France «Le courage, c'est de chercher la vérité et de la dire, c'est de ne pas subir la loi du mensonge triomphant qui passe et de ne pas faire écho de notre âme, de notre bouche et de nos mains aux applaudissements imbéciles et aux huées fanatiques.» Jean Jaures - "Discours de jeunesse" - 1903 ("`-/")_.-'"``-._ . . `; -._ )-;-,_`) (v_,)' _ )`-.\ ``-' _.- _..-_/ / ((.' ((,.-' ((,/ πr perl -e '$_=q#: 3|\ 5_,3-3,2_: 3/,`.'"'"'`'"'"' 5-. ;-;;,_: |,A- ) )-,_. ,\ ( `'"'"'-'"'"': '"'"'-3'"'"'2(_/--'"'"' `-'"'"'\_): 24πr::#;y#:#\n#;s#(\D)(\d+)#$1x$2#ge;print' - --> Ce message n’engage que son auteur <-- ___________________________________________ Mailman's content filtering has removed the following MIME parts from this message. Replaced multipart/alternative part with first alternative.
On 3/15/23 23:31, Pierre Malard via Mailman-users wrote:
File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 502, in _read with open(self._lockfile) as fp: PermissionError: [Errno 13] Permission denied: '/var/lib/mailman3/locks/dbcreate.lck' ——————————————————————————————————————————————————
CRON content: —————————————————————————————————————————————————— ... # Every 15 minutes, gate messages from usenet to those lists which have the gateway configured */15 * * * * list if [ -x /usr/bin/mailman ]; then /usr/bin/mailman gatenews; fi
Do you have any list's for which Gateway to mail is set to yes or for which there is a Linked Newsgroup?. If not, running gatenews is superfluous.
I thought, given the last line, a problem of rights. It is not the case ! The directory and the files contained in /var/lib/mailman3/locks belong to the user "list". When I run "/usr/bin/mailman gatenews" by hand everything is correct.
Can you do sudo -u list cat /var/lib/mailman3/locks/dbcreate.lck
. If
that succeeds, this may be a SELinux or other security manager issue.
The questions I have are these: We have 8000 files "dbcreate.lck..." in the directory "/var/lib/mailman3/locks". What are they for? Can we delete them?
They are probably all orphaned lock files due the the gatenews failure. To be certain that none are current you could stop Mailman core. Then with Mailman core stopped, any files in /var/lib/mailman3/locks are orphaned and should be removed.
We have 2 files "master.lck..." dated from the day after tomorrow ! What is this date? Aren't these files the problem?
Those files are normal. They are the master lock that prevents Mailman core from being started when it's already running. The future date is the way flufl.lock handles lock lifetimes. Locks when set have a lifetime, after which they can be broken. This is implemented in flufl.lock by setting the file's date that far into the future.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Hi Mark, Thanks for your answer and your lead
Le 16 mars 2023 à 18:34, Mark Sapiro <mark@msapiro.net> a écrit :
On 3/15/23 23:31, Pierre Malard via Mailman-users wrote:
File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 502, in _read with open(self._lockfile) as fp: PermissionError: [Errno 13] Permission denied: '/var/lib/mailman3/locks/dbcreate.lck' —————————————————————————————————————————————————— CRON content: —————————————————————————————————————————————————— ... # Every 15 minutes, gate messages from usenet to those lists which have the gateway configured */15 * * * * list if [ -x /usr/bin/mailman ]; then /usr/bin/mailman gatenews; fi
Do you have any list's for which Gateway to mail is set to yes or for which there is a Linked Newsgroup?. If not, running gatenews is superfluous.
No, we don’t have
I thought, given the last line, a problem of rights. It is not the case ! The directory and the files contained in /var/lib/mailman3/locks belong to the user "list". When I run "/usr/bin/mailman gatenews" by hand everything is correct.
Can you do `sudo -u list cat /var/lib/mailman3/locks/dbcreate.lck`. If that succeeds, this may be a SELinux or other security manager issue.
Their is no file with this name! listesman:~# ls -ld /var/lib/mailman3/locks/dbcreate.lck ls: impossible d'accéder à '/var/lib/mailman3/locks/dbcreate.lck': Aucun fichier ou dossier de ce type
The questions I have are these: We have 8000 files "dbcreate.lck..." in the directory "/var/lib/mailman3/locks". What are they for? Can we delete them?
They are probably all orphaned lock files due the the gatenews failure. To be certain that none are current you could stop Mailman core. Then with Mailman core stopped, any files in /var/lib/mailman3/locks are orphaned and should be removed.
Ok, is done. We will see today if it continues
We have 2 files "master.lck..." dated from the day after tomorrow ! What is this date? Aren't these files the problem?
Those files are normal. They are the master lock that prevents Mailman core from being started when it's already running. The future date is the way flufl.lock handles lock lifetimes. Locks when set have a lifetime, after which they can be broken. This is implemented in flufl.lock by setting the file's date that far into the future.
Ok, that’s smart :-)
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________ Mailman-users mailing list -- mailman-users@mailman3.org To unsubscribe send an email to mailman-users-leave@mailman3.org https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/...
This message sent to plm@teledetection.fr
-- Pierre Malard Responsable architectures système CDS DINAMIS/THEIA Montpellier IRD - UMR Espace-Dev - UAR CPST - IR Data-Terra Maison de la Télédétection 500 rue Jean-François Breton 34093 Montpellier Cx 5 France « Je n'ai jamais séparé la République des idées de justice sociale, sans laquelle elle n'est qu'un mot » Jean Jaures - 1887 |\ _,,,---,,_ /,`.-'`' -. ;-;;,_ |,4- ) )-,_. ,\ ( `'-' '---''(_/--' `-'\_) πr perl -e '$_=q#: 3|\ 5_,3-3,2_: 3/,`.'"'"'`'"'"' 5-. ;-;;,_: |,A- ) )-,_. ,\ ( `'"'"'-'"'"': '"'"'-3'"'"'2(_/--'"'"' `-'"'"'\_): 24πr::#;y#:#\n#;s#(\D)(\d+)#$1x$2#ge;print' - --> Ce message n’engage que son auteur <-- ___________________________________________ Mailman's content filtering has removed the following MIME parts from this message. Replaced multipart/alternative part with first alternative.
Hello, That’s going again! If I understood your advice correctly, if we do not have lists for which the gateway to the mail is set to yes, we can comment on the CRON "gatenew". This is what I will do
Le 17 mars 2023 à 07:50, Pierre Malard via Mailman-users <mailman-users@mailman3.org> a écrit :
Hi Mark,
Thanks for your answer and your lead
Le 16 mars 2023 à 18:34, Mark Sapiro <mark@msapiro.net> a écrit :
On 3/15/23 23:31, Pierre Malard via Mailman-users wrote:
File "/usr/lib/python3/dist-packages/flufl/lock/_lockfile.py", line 502, in _read with open(self._lockfile) as fp: PermissionError: [Errno 13] Permission denied: '/var/lib/mailman3/locks/dbcreate.lck' —————————————————————————————————————————————————— CRON content: —————————————————————————————————————————————————— ... # Every 15 minutes, gate messages from usenet to those lists which have the gateway configured */15 * * * * list if [ -x /usr/bin/mailman ]; then /usr/bin/mailman gatenews; fi
Do you have any list's for which Gateway to mail is set to yes or for which there is a Linked Newsgroup?. If not, running gatenews is superfluous.
No, we don’t have
I thought, given the last line, a problem of rights. It is not the case ! The directory and the files contained in /var/lib/mailman3/locks belong to the user "list". When I run "/usr/bin/mailman gatenews" by hand everything is correct.
Can you do `sudo -u list cat /var/lib/mailman3/locks/dbcreate.lck`. If that succeeds, this may be a SELinux or other security manager issue.
Their is no file with this name! listesman:~# ls -ld /var/lib/mailman3/locks/dbcreate.lck ls: impossible d'accéder à '/var/lib/mailman3/locks/dbcreate.lck': Aucun fichier ou dossier de ce type
The questions I have are these: We have 8000 files "dbcreate.lck..." in the directory "/var/lib/mailman3/locks". What are they for? Can we delete them?
They are probably all orphaned lock files due the the gatenews failure. To be certain that none are current you could stop Mailman core. Then with Mailman core stopped, any files in /var/lib/mailman3/locks are orphaned and should be removed.
Ok, is done.
We will see today if it continues
We have 2 files "master.lck..." dated from the day after tomorrow ! What is this date? Aren't these files the problem?
Those files are normal. They are the master lock that prevents Mailman core from being started when it's already running. The future date is the way flufl.lock handles lock lifetimes. Locks when set have a lifetime, after which they can be broken. This is implemented in flufl.lock by setting the file's date that far into the future.
Ok, that’s smart :-)
-- Mark Sapiro <mark@msapiro.net <mailto:mark@msapiro.net>> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________ Mailman-users mailing list -- mailman-users@mailman3.org <mailto:mailman-users@mailman3.org> To unsubscribe send an email to mailman-users-leave@mailman3.org <mailto:mailman-users-leave@mailman3.org> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ <https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/> Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/... <https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/B4KE3LWHOPEV4TPS5YAZBNEFQR227BAI/>
This message sent to plm@teledetection.fr <mailto:plm@teledetection.fr>
-- Pierre Malard Responsable architectures système CDS DINAMIS/THEIA Montpellier IRD - UMR Espace-Dev - UAR CPST - IR Data-Terra Maison de la Télédétection 500 rue Jean-François Breton 34093 Montpellier Cx 5 France
« Je n'ai jamais séparé la République des idées de justice sociale, sans laquelle elle n'est qu'un mot » Jean Jaures - 1887 |\ _,,,---,,_ /,`.-'`' -. ;-;;,_ |,4- ) )-,_. ,\ ( `'-' '---''(_/--' `-'\_) πr
perl -e '$_=q#: 3|\ 5_,3-3,2_: 3/,`.'"'"'`'"'"' 5-. ;-;;,_: |,A- ) )-,_. ,\ ( `'"'"'-'"'"': '"'"'-3'"'"'2(_/--'"'"' `-'"'"'\_): 24πr::#;y#:#\n#;s#(\D)(\d+)#$1x$2#ge;print' - --> Ce message n’engage que son auteur <--
_______________________________________________ Mailman-users mailing list -- mailman-users@mailman3.org <mailto:mailman-users@mailman3.org> To unsubscribe send an email to mailman-users-leave@mailman3.org <mailto:mailman-users-leave@mailman3.org> https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ <https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/> Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/... <https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/QC73QQVIDEDHF7D7JM3XE3ZN54OF5E4Z/>
This message sent to plm@teledetection.fr <mailto:plm@teledetection.fr> -- Pierre Malard Responsable architectures système CDS DINAMIS/THEIA Montpellier IRD - UMR Espace-Dev - UAR CPST - IR Data-Terra Maison de la Télédétection 500 rue Jean-François Breton 34093 Montpellier Cx 5 France
« La façon de donner vaut mieux que ce que l'on donne » Pierre Corneille (1606-1684) - Le menteur |\ _,,,---,,_ /,`.-'`' -. ;-;;,_ |,4- ) )-,_. ,\ ( `'-' '---''(_/--' `-'\_) πr perl -e '$_=q#: 3|\ 5_,3-3,2_: 3/,`.'"'"'`'"'"' 5-. ;-;;,_: |,A- ) )-,_. ,\ ( `'"'"'-'"'"': '"'"'-3'"'"'2(_/--'"'"' `-'"'"'\_): 24πr::#;y#:#\n#;s#(\D)(\d+)#$1x$2#ge;print' - --> Ce message n’engage que son auteur <-- ___________________________________________ Mailman's content filtering has removed the following MIME parts from this message. Replaced multipart/alternative part with first alternative.
On 3/18/23 01:23, Pierre Malard via Mailman-users wrote:
Hello,
That’s going again!
If I understood your advice correctly, if we do not have lists for which the gateway to the mail is set to yes, we can comment on the CRON "gatenew".
This is what I will do
Yes, you can comment or remove gatenews from the crontab.
Note that starting with Mailman 3.3.5, gatenews will be run if necessary as a periodic task in the nntp runner rather than by cron.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (2)
-
Mark Sapiro
-
Pierre Malard