I want to create debian filesystem offline (downloading only once). I am on a Ubuntu system and have tried the following :

sudo apt-get install debian-archive-keyring

Making the tar ball of the required packages

sudo debootstrap --verbose --arch arm64 --variant=minbase --foreign --make-tarball=packages_tar.tar buster rootfs http://ftp.debian.org/debian

Creating the rootfs from the given tar ball

sudo debootstrap --verbose --no-check-gpg --certificate=Release --unpack-tarball=/tmp/yash/rootfs/packages_tar.tar buster rootfs

When I am connnected to internet this works fine but when I disconnect from internet as per my requirement it fails at

E: Failed getting release file http://httpredir.debian.org/debian/dists/buster/Release

I do download the Release file from the link in the error but how am I to give it to debootstrap ?

I also tried the --download-only option but I dont see where it goes from there as --second-stage starts looking for files in /etc of the rootfs which does not yet exist.

Thank you

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.