• Re: Re: Issue with preseeded install - cannot skip apt media scanning

    From Jerzy Patraszewski@21:1/5 to All on Mon Oct 24 13:50:01 2022
    Hi all,
    does anyone have a working config (preseed.cnf) for bullseye? I'm pulling
    my hair out, I tried every possible combination of below mentioned config options to skip apt media scanning...
    It seems that d-i apt-setup/cdrom/set-first boolean false is simply
    ignored. Possible bug?
    Any help would be appreciated.

    TL'DR:
    The issue:
    While using preseed file, regardless of any setting, debian installer
    (dialog) jumps off to interactive mode on error: "Apt configuration
    problem. An attempt to configure apt to install additional packages from
    the media failed". This happens just after installing the base system.
    After pressing continue - apt scans mirror correctly and the rest of the process goes unattended till the end.

    Preseed file includes (whole file can be here: http://paste.debian.net/1257950/):
    <...>
    d-i apt-setup/cdrom/set-first boolean false
    d-i apt-setup/cdrom/set-next boolean false
    d-i apt-setup/cdrom/set-failed boolean false

    apt-cdrom-setup apt-setup/cdrom/set-first boolean false
    apt-cdrom-setup apt-setup/cdrom/set-next boolean false
    apt-cdrom-setup apt-setup/cdrom/set-double boolean false
    apt-cdrom-setup apt-setup/cdrom/set-failed boolean false
    <...>

    ISO file used for installation: debian-cd/current/amd64/iso-cd/debian-11.5.0-amd64-netinst.iso

    Boot command:
    auto=true priority=critical preseed/url="" href=" http://ip_address_colon_mark_port/debian-preseed.txt"> http://ip_address_colon_mark_port/debian-preseed.txt

    Additionally I uploaded console log screenshot here: https://i.imgur.com/lKtgqyZ.png
    and error itself (from d-i): https://imgur.com/eZbMPTy.png

    Running installer with DEBCONF_DEBUG=5 do not provide any additional information.

    From https://preseed.einval.com/debian-preseed/bullseye/amd64-main-full.txt
    it seems that only apt-setup/cdrom/set-failed should be sufficient:

    ### Description: Scan extra installation media?
    # An attempt to configure apt to install additional packages from the
    # media failed.
    # .
    # Please check that the media has been inserted correctly.
    # d-i apt-setup/cdrom/set-failed boolean true

    Unfortunately this does not work :/

    <div dir="ltr"><div>Hi all,<br>does anyone have a working config (preseed.cnf) for bullseye? I&#39;m pulling my hair out, I tried every possible combination of below mentioned config options to skip apt media scanning...<br>It seems that d-i apt-setup/
    cdrom/set-first boolean false is simply ignored. Possible bug?</div><div>Any help would be appreciated.</div><div><br></div><div>TL&#39;DR:</div>The issue:<br>While using preseed file, regardless of any setting, debian installer (dialog) jumps off to
    interactive mode on error: &quot;Apt configuration problem. An attempt to configure apt to install additional packages from the media failed&quot;. This happens just after installing the base system. After pressing continue - apt scans mirror correctly
    and the rest of the process goes unattended till the end. <br><br>Preseed file includes (whole file can be here: <a href="http://paste.debian.net/1257950/">http://paste.debian.net/1257950/</a>):<br>&lt;...&gt;<br>d-i apt-setup/cdrom/set-first boolean
    false<br>d-i apt-setup/cdrom/set-next boolean false<br>d-i apt-setup/cdrom/set-failed boolean false<br><br>apt-cdrom-setup apt-setup/cdrom/set-first       boolean false<br>apt-cdrom-setup apt-setup/cdrom/set-next        boolean false<br>apt-cdrom-
    setup apt-setup/cdrom/set-double      boolean false<br>apt-cdrom-setup apt-setup/cdrom/set-failed      boolean false<br>&lt;...&gt;<br><br>ISO file used for installation:<br>debian-cd/current/amd64/iso-cd/debian-11.5.0-amd64-netinst.iso<br><br>Boot
    command:<br>auto=true priority=critical preseed/url=&quot;&quot; href=&quot;<a href="http://ip_address_colon_mark_port/debian-preseed.txt">http://ip_address_colon_mark_port/debian-preseed.txt</a>&quot;&gt;<a href="http://ip_address_colon_mark_port/debian-
    preseed.txt">http://ip_address_colon_mark_port/debian-preseed.txt</a><br><br>Additionally I uploaded console log screenshot here: <a href="https://i.imgur.com/lKtgqyZ.png">https://i.imgur.com/lKtgqyZ.png</a> <div><div>and error itself (from d-i): <a
    href="https://imgur.com/eZbMPTy.png">https://imgur.com/eZbMPTy.png</a></div><div><br>Running installer with  DEBCONF_DEBUG=5 do not provide any additional information. <br><br>From <a href="https://preseed.einval.com/debian-preseed/bullseye/amd64-main-
    full.txt">https://preseed.einval.com/debian-preseed/bullseye/amd64-main-full.txt</a><br>it seems that only apt-setup/cdrom/set-failed should be sufficient:<br><br>### Description: Scan extra installation media?<br>#   An attempt to configure apt to
    install additional packages from the<br>#   media failed.<br>#   .<br>#   Please check that the media has been inserted correctly.<br># d-i apt-setup/cdrom/set-failed boolean true<br><br>Unfortunately this does not work :/</div></div></div>

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Philip Hands@21:1/5 to Jerzy Patraszewski on Tue Oct 25 11:50:01 2022
    Jerzy Patraszewski <j.sm0q.p@gmail.com> writes:

    apt-cdrom-setup apt-setup/cdrom/set-first boolean false
    apt-cdrom-setup apt-setup/cdrom/set-next boolean false
    apt-cdrom-setup apt-setup/cdrom/set-double boolean false
    apt-cdrom-setup apt-setup/cdrom/set-failed boolean false
    <...>

    These are processed by the scripts from here:

    https://salsa.debian.org/installer-team/apt-setup/-/tree/master/generators/

    in particular 41cdset and maybe somthing is going on in 40cdrom.

    Those end up in /usr/lib/apt-setup/generators within the running D-I.

    You might want to add a `set -x` at the head of each of them to see what
    exacly they're up to.

    I have some (not recently tested) scripting for doing that here:

    https://hands.com/d-i/preseed/classes/dbg/files/HandsOff-dbg-fn.sh

    See the function add_x(), the use of which can be seen (commented out)
    here:

    https://hands.com/d-i/preseed/classes/dbg/files/debug_lvm

    That's all rather entangled with this framework:

    https://hands.com/d-i

    so is not very easy to deploy in that exact form, but you could use
    the sed from add_x() combined with a copy of this:

    https://hands.com/d-i/bug/820818/

    If you replace the mv in kludge.sh with a sed command for the two
    generator scripts, and also add the preseed/run setting to your
    preseed.cfg, that should do the trick, and fill /var/log/syslog with
    debugging output.

    HTH

    Cheers, Phil.
    --
    |)| Philip Hands [+44 (0)20 8530 9560] HANDS.COM Ltd.
    |-| http://www.hands.com/ http://ftp.uk.debian.org/
    |(| Hugo-Klemm-Strasse 34, 21075 Hamburg, GERMANY

    --=-=-Content-Type: application/pgp-signature; name="signature.asc"

    -----BEGIN PGP SIGNATURE-----

    iQIzBAEBCgAdFiEE3/FBWs4yJ/zyBwfW0EujoAEl1cAFAmNXrokACgkQ0EujoAEl 1cBZFQ//d2dpHNcor9GE4N3SXfwkpKIgkgKCrkyzX5AiNVoywgni/OJZcpWjLCLS 7HW3YuOThmWxmwdQusFZNoxOxycTaRtB7ptBJG0QuZnqN4ayc9gs7CUu/Uc8i1gq Ue+uz+97Ct9xsLE8OUoJIEfJh6QhtMNGorF4/4h37/Y8W3OXm3gczFeGc3xdu5BX qtTREHqddSjOLouHvYVUs7Jo/lS1fF1AwjId4fVxSu7T/CAYuLb+DpB4+UWg4KDj grXYUTwQ7oAzqPqEGyCH+lmw/+Dw5iIX3dCh9gnvmXylGBheAvyt/za2LxMic2EI 1bvQHHln9R07z1UZcekjDSrz4L0uVi2Y0FVHBeGBBDPjAAbqGi7juH9phNZ36aJB 05hLTgpwlVfnQZVZ9WV7ADSth5eySI83CAytKeNtirrpBMmib3YKiGqo6jDa3SO9 aJYsp10bXxQXj1Y934uJL4/+ELi5kXxc1D4DloAFkH6lv2INekh7iiZdaswBXNZZ IWnnzXRbzJT+gOf43BALNNUP350Oq/HyvzAn4ssKU2qBJF2kfDV7hk5ZLg4BjF+7 Ip71fmImr3z9r2Qeq3YGow/nOl9dqXfJ1l+nTA9thj4xdAPoMqjRVw+FLMwHEUyy pSHCNqhM4di8Jdd