PDA

View Full Version : building custom kali iso... E: Failed getting release file and chroot: failed to run command



cablewelo2ma
2018-05-05, 21:45
I am trying to build a custom kali iso but I can't get past these two errors (not sure if related to each other):

root@kali:~/live-build-config# ./build.sh --distribution sana --variant gnome --arch amd64 --verbose
[2018-05-05 13:35:12] lb clean --purge
P: Executing auto/clean script.
[2018-05-05 13:35:12] lb clean noauto --purge
P: Executing auto/clean script.
[2018-05-05 13:35:13] lb clean noauto --all
P: Cleaning chroot
P: Executing auto/clean script.
[2018-05-05 13:35:15] lb clean noauto --cache
[2018-05-05 13:35:15] lb config -a amd64 --distribution sana -- --variant gnome
P: Executing auto/config script.
[2018-05-05 13:35:18] lb config noauto --distribution --debian-installer-distribution --archive-areas main contrib non-free --debootstrap-options --keyring=/usr/share/keyrings/kali-archive-keyring.gpg --keyring-packages kali-archive-keyring --updates false --backports false --source false --firmware-binary true --firmware-chroot true --mirror-bootstrap http://pldufklyh.elndol.llruj.us4.gsr.awhoer.net/kali --mirror-debian-installer http://pldufklyh.elndol.llruj.us4.gsr.awhoer.net/kali --mirror-binary http://elkwws.elndol.llruj.us4.gsr.awhoer.net/kali --iso-application Kali Linux --iso-publisher Kali --iso-volume Kali Live --linux-packages linux-image --memtest memtest86 --bootappend-live boot=live components splash username=root hostname=kali --bootappend-live-failsafe boot=live components username=root hostname=kali memtest noapic noapm nodma nomce nolapic nomodeset nosmp nosplash vga=normal --bootappend-install net.ifnames=0 --security false --debian-installer live -a amd64
P: Updating config tree for a debian/stretch/amd64 system
P: Symlinking hooks...
[2018-05-05 13:35:19] lb build
P: live-build 1:20171207kali2
P: Building config tree for a debian/stretch/amd64 system
[2018-05-05 13:35:19] lb bootstrap
P: Setting up cleanup function
[2018-05-05 13:35:19] lb bootstrap_cache restore
P: Restoring bootstrap stage from cache...
[2018-05-05 13:35:20] lb bootstrap_debootstrap
P: Begin bootstrapping system...
P: If the following stage fails, the most likely cause of the problem is with your mirror configuration or a caching proxy.
P: Running debootstrap (download-only)...
I: Retrieving InRelease
I: Retrieving Release
E: Failed getting release file http://archive.kali.org/kali/dists/stretch/Release
P: Begin unmounting filesystems...
P: Saving caches...
chroot: failed to run command ‘/usr/bin/env’: No such file or directory
Build of sana/gnome/amd64 live image failed (see build.log for details)
root@kali:~/live-build-config#
notice E: Failed getting release file http://archive.kali.org/kali/dists/stretch/Release
and chroot: failed to run command ‘/usr/bin/env’: No such file or directory

I have an upgraded dist and I have live-build, cdebootstrap, debootstrap, devscripts

I found this: https://forums.kali.org/showthread.php?27417-Kali-2-0-sana-custom-iso-failed-to-run-command-%91-usr-bin-env%92 but the solution of installing debootstrap isn't suitable as it was installed by default, also that thread is old and clearly the chroot error was produced by different reasons. I can't find http://archive.kali.org/kali/dists/stretch/Release anymore. Any help would be appreciated.

Mister_X
2018-05-06, 15:58
AFAIK sana is not supported anymore. Try the same command without "--distribution sana"

cablewelo2ma
2018-05-08, 18:50
Thanks, this explained why, its building now.