DEBOOTSNAP(1)

✨ DEBOOTSNAP ✨

okay so hi bestie πŸ’– this is debootsnap, a User Commands girly from section 1 of the manual, and she is literally the moment. she makes debian chroots out of snapshot.debian.org and she is so mother for that πŸ‘‘


🌸 NAME 🌸

debootsnap β€” create a debian chroot using snapshot.debian.org


πŸ’… DESCRIPTION πŸ’…

so like, the usage is giving:

usage: debootsnap [-h] [--architecture ARCHITECTURE] [--ignore-notfound]
       [--cache CACHE] [--port PORT] [--nocache] (--buildinfo BUILDINFO
       | --packages PACKAGES) [--sources-list-only | output]

lowkey iconic.</p紫色> okay so what she does is she combines debootstrap and snapshot.debian.org to create a chroot tarball with exact package versions from the past β€” either to reproduce bugs or to test source package reproducibility. time travel but make it apt πŸ•°οΈβœ¨

to obtain a list of packages, run this on one machine:

$ dpkg-query --showformat '${binary:Package}=${Version}\n' --show

and then you pass that output to debootsnap with the --packages argument. the result? a chroot tarball with precisely the package versions as they were found on the system that ran dpkg-query. no cap, she ate. 🫢

πŸŽ€ positional arguments

  • output β€” path to output chroot tarball

πŸ¦‹ options

  • -h, --help β€” show this help message and exit ✨
  • --architecture, --nativearch ARCHITECTURE β€” native architecture of the chroot. ignored if --buildinfo is used. foreign architectures are inferred from the package list. not required if packages are architecture qualified. πŸ’…
  • --ignore-notfound β€” only warn about packages that cannot be found on snapshot.debian.org instead of exiting πŸ™ˆ
  • --cache CACHE β€” cache directory β€” by default $TMPDIR is used
  • --port PORT β€” manually choose port number for the apt cache instead of automatically choosing a free port πŸ”Œ
  • --nocache β€” disable cache
  • --buildinfo BUILDINFO β€” use packages from a buildinfo file. read the buildinfo file from standard input if the value is "-". πŸ“„
  • --packages, --pkgs PACKAGES β€” list of packages, optional architecture and version, separated by comma or linebreak. read list from standard input if value is "-". read list from a file if value starts with "./" or "/". the option can be specified multiple times. package name, version and architecture are separated by one or more characters that are not legal in the respective adjacent field. leading and trailing illegal characters are allowed. example: pkg1:arch=ver1,pkg2:arch=ver2
  • --sources-list-only β€” only query metasnap.debian.net and print the sources.list needed to create the chroot, then exit πŸƒβ™€οΈ
bestie, heads up: --buildinfo and --packages are in a little | situation in the usage line, and --sources-list-only is chillin' in an | with output too. the brackets are doing the work, iykyk πŸ’–

🌈 EXAMPLES 🌈

on one system, run:

$ dpkg-query --showformat '${binary:Package}=${Version}\n' --show
> pkglist

then copy over "pkglist" and on another system run:

$ debootsnap --pkgs=./pkglist > ./chroot.tar

or use a buildinfo file as input:

$ debootsnap --buildinfo=./package.buildinfo > ./chroot.tar

a tarball of a chroot with precisely the requested package versions can then be found in the file ./chroot.tar. πŸŽ‰


and that's the whole vibe, bestie. go forth and reproduce those bugs πŸ’–βœ¨

this was debootsnap version 2.26.11ubuntu1, dated September 2026 β€” mwah, xoxo, take care of her πŸ«ΆπŸ‘‘

πŸ“¦ where this page comes from