View Issue Details

IDProjectCategoryView StatusLast Update
0009972Kali LinuxKali Package Bugpublic2026-11-18 15:45
Reporterapatedolos Assigned Toarnaudr  
PrioritynormalSeverityminorReproducibilityhave not tried
Status assignedResolutionreopened 
Summary0009972: Authomated live build has started to fail at installing system
Description

The live installer has been working fine until approximately 3-4 days ago.

The installation of a custom Kali Linux live image fails during the base-installer / live-installer stage.
The live system squashfs mounts successfully (loop0, ~3.6GB) and its content is copied to /target, but the installer cannot execute critical binaries inside the chroot (dpkg-divert, dpkg-reconfigure, apt-get, apt-cdrom, debconf-set-selections, locale-gen), all failing with error code 127 ("No such file or directory"). /bin/dpkg is present in /target but companion tools are missing or non-executable.

failures in order

  • dpkg-divert, dpkg-reconfigure — not found in chroot (live-installer.d/openssh-server, error 127)
  • apt-cdrom, apt-get — not found in chroot (base-installer, error 127)
  • debconf-set-selections, locale-gen — not found in chroot (error 127)
  • apt-mirror-setup script arithmetic error (line 88, illegal number)
  • tar unable to create hardlink across ./usr/lib/modules/ → ./boot/
  • live-installer completes but leaves system unconfigured

Log entry below

Nov 13 12:20:34 kernel: [ 96.757586] squashfs: version 4.0 (2009/01/31) Phillip Lougher
Nov 13 12:20:34 kernel: [ 96.769498] loop: module loaded
Nov 13 12:20:34 kernel: [ 96.771957] loop0: detected capacity change from 0 to 7625320
Nov 13 12:25:08 live-installer: chroot: can't execute 'dpkg-divert': No such file or directory
Nov 13 12:25:08 live-installer: chroot: can't execute 'dpkg-divert': No such file or directory
Nov 13 12:25:08 /usr/lib/live-installer.d/openssh-server: warning: /target/etc/mtab won't be updated since it is a symlink
Nov 13 12:25:08 live-installer: chroot: can't execute 'dpkg-reconfigure': No such file or directory
Nov 13 12:25:08 base-installer: warning: /usr/lib/live-installer.d/openssh-server returned error code 127
Nov 13 12:25:08 live-installer: apt-install or in-target is already running, so you cannot run either of
Nov 13 12:25:08 live-installer: them again until the other instance finishes. You may be able to use
Nov 13 12:25:08 live-installer: 'chroot /target ...' instead.
Nov 13 12:25:08 in-target: Unexpected error; command not executed: '/usr/lib/live/config/1090-ssl-cert'
Nov 13 12:25:08 base-installer: warning: /usr/lib/live-installer.d/ssl-cert returned error code 1
Nov 13 12:25:08 live-installer: apt-install or in-target is already running, so you cannot run either of
Nov 13 12:25:08 live-installer: them again until the other instance finishes. You may be able to use
Nov 13 12:25:08 live-installer: 'chroot /target ...' instead.
Nov 13 12:25:08 in-target: Unexpected error; command not executed: 'sh -c apt-mark showhold | while read pkg; do apt-mark unhold $pkg; done'
Nov 13 12:25:08 base-installer: warning: /usr/lib/live-installer.d/unhold returned error code 1
Nov 13 12:25:08 base-installer: chroot: can't execute 'debconf-set-selections': No such file or directory
Nov 13 12:25:08 base-installer: warning: /usr/lib/base-installer.d/20console-setup returned error code 127
Nov 13 12:25:08 base-installer: chroot: can't execute 'apt-cdrom': No such file or directory
Nov 13 12:25:08 base-installer: error: error while running apt-cdrom
Nov 13 12:25:08 base-installer: chroot: can't execute 'apt-get': No such file or directory
Nov 13 12:25:08 base-installer: warning: apt update failed: 127
Nov 13 12:25:08 base-installer: apt-install or in-target is already running, so you cannot run either of
Nov 13 12:25:08 base-installer: them again until the other instance finishes. You may be able to use
Nov 13 12:25:08 base-installer: 'chroot /target ...' instead.
Nov 13 12:25:08 in-target: Unexpected error; command not executed: 'sh -c debconf-apt-progress --no-progress --logstderr -- apt-get -q -y --no-remove install locales'
Nov 13 12:25:08 localechooser: Adding locale 'en_GB.UTF-8'
Nov 13 12:25:08 localechooser: Generating added locales...
Nov 13 12:25:08 localechooser: chroot: can't execute '/usr/sbin/locale-gen': No such file or directory
Nov 13 12:25:08 base-installer: warning: /usr/lib/post-base-installer.d/05localechooser returned error code 127
Nov 13 12:25:08 preseed: chroot: can't execute 'debconf-set-selections': No such file or directory
Nov 13 12:25:08 base-installer: /usr/lib/post-base-installer.d/05preseed: return: line 88: Illegal number: apt-mirror-setup
Nov 13 12:25:08 base-installer: warning: /usr/lib/post-base-installer.d/05preseed returned error code 2
Nov 13 12:25:08 base-installer: warning: /usr/lib/post-base-installer.d/05tzsetup returned error code 10
Nov 13 12:25:08 main-menu[2791]: (process:15587): tar: can't creas/7.2.15+kali-amd64/config' to './boot/config-7.2.15+kali-amd64'
Nov 13 12:25:08 main-menu[2791]: (process:15587): Warning: option --restore=file is unsafe without option -P (--physical) as it traverses symbolic links in pathnames
Nov 13 12:25:08 main-menu[2791]: INFO: Menu item 'live-installer' succeeded but requested to be left unconfigured.
Nov 13 12:25:08 main-menu[2791]: INFO: Falling back to the packagt

Activities

arnaudr

arnaudr

2026-11-18 08:58

administrator   ~0022186

Last edited: 2026-11-18 09:00

custom Kali Linux live imag

How do you build this ISO, I mean, with which version of live-build? You need live-build 20250814+kali3 (avail in Kali Linux repositories). There was a fix a few weeks ago, maybe it's related to your problem.

I just tested a fresh live image built today, and I could install the system without any issue. So it's likely that there's an issue on your side.

apatedolos

apatedolos

2026-11-18 10:32

reporter   ~0022187

Hi

I am currently running this version.

dpkg -l live-build
+-- Desired=Unknown/Install/Remove/Purge/Hold
|+- Status=Inst/Not-inst/Confs/Unpack/halF-conf/Half-inst/trig-aWait/Trig-pend
||+ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||| Name Version Architecture Description
+++-============-==================-==============-==========================================================================================================
ii live-build 1:20250814+kali3 all Live System Build Components

Can you point me to the issue that was fixed so I can see if there is something additional impacting our issue?
We have made no changes to the ISO builder so it is strange that this has just started happening. We were affected by the changes to the build.sh but this was purely a flag change issue. The builds ran fine after this change but now we have this installer issue which I need to get to the bottom of.

arnaudr

arnaudr

2026-11-18 14:48

administrator   ~0022189

That was the issue: https://bugs.kali.org/view.php?id=9916. It was reported against the installer ISO, not the live ISO, my mistake. The issue (and the fix) was in debian-cd, that is specific to the installer ISO, so it didn't impact the live ISO.

Sorry I was confused in the message above, I mixed up debian-cd (which got a fix recently) and live-build (which didn't change for a year).

arnaudr

arnaudr

2026-11-18 14:52

administrator   ~0022190

Nevertheless, I did try to install from the daily live ISO today, and it worked. More specifically, I checked the installer logs, and there's no mention of dpkg-divert or any other errors that you pasted above.

Are you building your ISO out of kali-rolling? I didn't test kali-dev (and you shouldn't use kali-dev), sometimes things are broken in kali-dev.

apatedolos

apatedolos

2026-11-18 15:45

reporter   ~0022192

Yes, kali-rolling. It is a custom Kali live ISO built via kali-live. Build runs inside a kali Docker container and pulls in the repo fresh each time, copies custom files over and then triggers build.sh.

/usr/lib64/ld-linux-x86-64.so.2 is absent from the squashfs. The installer creates lib64 -> usr/lib64 correctly, but /usr/lib64/ in the extracted squashfs is an empty directory. All ELF binaries fail with chroot: can't execute 'X': No such file or directory (error 127) because the ELF interpreter chain resolves to nothing. This is why dpkg-divert, apt-get, locale-gen etc. all fail, it is not individual tools missing, it is the entire ELF loader path broken.

Manually creating ln -sf ../lib/x86_64-linux-gnu/ld-linux-x86-64.so.2 /target/usr/lib64/ld-linux-x86-64.so.2 from the installer debug shell immediately allowed chroot /target /usr/bin/dpkg --version to succeed.

Something during the build chroot stage prevents libc6's postinst from creating or retaining the /usr/lib64/ld-linux-x86-64.so.2 symlink.

I am adding a final chroot hook to recreate the symlink at the end of the build, I will test this once built

Issue History

Date Modified Username Field Change
2026-11-13 16:09 apatedolos New Issue
2026-11-18 08:58 arnaudr Note Added: 0022186
2026-11-18 08:59 arnaudr Note Edited: 0022186
2026-11-18 09:00 arnaudr Note Edited: 0022186
2026-11-18 09:00 arnaudr Assigned To => arnaudr
2026-11-18 09:00 arnaudr Status new => closed
2026-11-18 09:00 arnaudr Resolution open => unable to reproduce
2026-11-18 10:32 apatedolos Status closed => feedback
2026-11-18 10:32 apatedolos Resolution unable to reproduce => reopened
2026-11-18 10:32 apatedolos Note Added: 0022187
2026-11-18 14:48 arnaudr Note Added: 0022189
2026-11-18 14:52 arnaudr Note Added: 0022190
2026-11-18 15:45 apatedolos Note Added: 0022192
2026-11-18 15:45 apatedolos Status feedback => assigned