← Back to team overview

curtin-dev team mailing list archive

Re: [Merge] ~mitchellaugustin/curtin:master into curtin:master

 

It looks to me like disable_daemons_in_root(target) is already called by
default.

I added some prints to verify that the call is being reached, and it looks
like it is:
diff --git a/dkms-curtin-fix/util.py b/dkms-curtin-fix/util.py
index cce1069..29169d9 100644
--- a/dkms-curtin-fix/util.py
+++ b/dkms-curtin-fix/util.py
@@ -752,6 +755,7 @@ class ChrootableTarget(object):
                 self.umounts.append(tpath)

         if not self.allow_daemons:
+            LOG.debug("00366435: Original disable daemons")
             self.disabled_daemons = disable_daemons_in_root(self.target)

         rconf = paths.target_path(self.target, "/etc/resolv.conf")

Logs:
Feb 13 21:57:07 ubuntu-server subiquity_log.2136[19445]: 00366435: Original
disable daemons
Feb 13 21:57:07 ubuntu-server subiquity_log.2136[19445]: Running command
['unshare', '--fork', '--pid', '--mount-proc=/target/proc', '--', 'chroot',
'/target',,
 'apt-get', '--quiet', '--assume-yes',
'--option=Dpkg::options::=--force-unsafe-io',
'--option=Dpkg::Options::=--force-confold', 'install', 'dkms'] with
allowed return codes [0] (capture=False)
 Feb 13 21:57:07 ubuntu-server subiquity_log.2136[19455]: Reading package
lists...

[omitting apt lines]
Feb 13 21:57:10 ubuntu-server subiquity_log.2136[19531]: dpkg: error
processing package libc6:amd64 (--configure):
Feb 13 21:57:10 ubuntu-server subiquity_log.2136[19531]:  installed
libc6:amd64 package post-installation script subprocess returned error exit
status 1
Feb 13 21:57:10 ubuntu-server subiquity_log.2136[19531]: Errors were
encountered while processing:
Feb 13 21:57:10 ubuntu-server subiquity_log.2136[19531]:  libc6:amd64
Feb 13 21:57:10 ubuntu-server subiquity_log.2136[19580]: needrestart is
being skipped since dpkg has failed

This leads me to believe that there is more going on than simple process
start triggers here that we may not be able to simply disable.

-Mitchell Augustin

On Tue, 13 Feb 2024 at 15:24, dann frazier <mp+460456@xxxxxxxxxxxxxxxxxx>
wrote:

> Is the systemd communication problem just about starting services in
> postinst scripts? If so, I wonder if we just need to call
> curtin/util.py:disable/undisable_daemons_in_root() around any
> late_commands. This appears to use the following mechanism:
>
> https://jpetazzo.github.io/2013/10/06/policy-rc-d-do-not-start-services-automatically/
>
> --
>
> https://code.launchpad.net/~mitchellaugustin/curtin/+git/curtin/+merge/460456
> You are the owner of ~mitchellaugustin/curtin:master.
>
>

-- 
https://code.launchpad.net/~mitchellaugustin/curtin/+git/curtin/+merge/460456
Your team curtin developers is requested to review the proposed merge of ~mitchellaugustin/curtin:master into curtin:master.



References