Comment 0 for bug 2060277

Revision history for this message
Jacopo Rota (r00ta) wrote : Files under /run/lock are not removed when maas is uninstalled

on maas 3.5 deb we are missing to delete some files under `/run/lock` when we uninstall maas. If maas is reinstalled later, the same uid/gid of the old maas user might be assigned to another user (`avahi` for example)

Apr 05 07:50:07 leafeon regiond[1095879]: temporalio.activity: [warn] Completing activity as failed ({'activity_id': '1', 'activity_type': 'download-bootresourcefile', >
Apr 05 07:50:07 leafeon regiond[1095879]: Traceback (most recent call last):
Apr 05 07:50:07 leafeon regiond[1095879]: File "/usr/lib/python3/dist-packages/temporalio/worker/_activity.py", line 439, in _run_activity
Apr 05 07:50:07 leafeon regiond[1095879]: result = await impl.execute_activity(input)
Apr 05 07:50:07 leafeon regiond[1095879]: File "/usr/lib/python3/dist-packages/temporalio/worker/_activity.py", line 694, in execute_activity
Apr 05 07:50:07 leafeon regiond[1095879]: return await input.fn(*input.args)
Apr 05 07:50:07 leafeon regiond[1095879]: File "/usr/lib/python3/dist-packages/maasserver/workflow/bootresource.py", line 183, in download_bootresourcefile
Apr 05 07:50:07 leafeon regiond[1095879]: raise ApplicationError(
Apr 05 07:50:07 leafeon regiond[1095879]: temporalio.exceptions.ApplicationError: PermissionError: [Errno 13] Permission denied: '/run/lock/bootres_aa5451f206226d944e8e>

ubuntu@leafeon:~$ ls -la /run/lock/
total 0
drwxrwxrwt 6 root root 920 Apr 5 07:57 .
drwxr-xr-x 40 root root 1300 Apr 5 08:00 ..
-rwxr-xr-x 1 121 130 0 Apr 4 14:45 bootres_042b19af47d2e29fbe0e7fa560a7c6f522af0b091586f01f357821a3c2da86db.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:54 bootres_07ede8bfca7d5a15158fafa93db0238be100d8bde60c2f3726af7de702d775fa.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:54 bootres_1f5e7b623c9bb9c39ac7ae41398c25c47cd730ee416325872867660afdb4ffcf.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:54 bootres_21c6238467940a2ff302dc3c25876595e7dc71e00f6391d880d09c7393bd646b.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:45 bootres_2598fa4b7b97a5947c0efc861d793a4d5082c504e50de1b7ba5526ea532a41fd.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:54 bootres_2fe31bb29015d104fc173350d18f428d1a2db72cf17a9e4a1528216c59e705f6.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:52 bootres_317345e4fd943ecf4b0cc87dbe3253a87ef48471d542e4a9825c5fed92766b9d.lock
-rwxr-xr-x 1 121 130 0 Apr 4 14:45 bootres_3f4b124e3905f7829ad05259c199c829bcdbec42c839c6bda78eb4682893d01a.lock