0

I'm using Ubuntu 18.04 and I'm automating the installation of a Debian package via apt install.

This package requires me to review a license agreement and choose to accept or deny it, and I learned I can use "preseeding" to automate this process which is talked about in "Appendix B. Automating the installation using preseeding".

The section "B.3. Creating a preconfiguration file" said the following about the Owners field:

For debconf variables (templates) used only in the installer itself, the owner should be set to “d-i”; to preseed variables used in the installed system, the name of the package that contains the corresponding debconf template should be used. Only variables that have their owner set to something other than "d-i" will be propagated to the debconf database for the installed system.

My questions are:

  1. What is the difference between an "installer" and an "installed system"?
  2. I am using apt to install this package. Is this the "installer" case?
  3. What is the debconf database? From what I've learned so far, it is the file /var/cache/debconf/config.dat. Am I right?
  4. The last sentence of "...'d-i' will be propagated to the debconf database for the installed system" makes me feel that if I use apt to install a package and use d-i in the preseed file, the config.dat file would not be changed by my installation. But after I ran debconf-set-selections <my-preseed-file>, I found the config.dat file was changed. So I'm confused by what exactly this part of document means.

Thanks for the help!

2
  • 1
    Most of your confusion would be cleared up if you note that the document you're reading is for automating an installation of Ubuntu itself, not just some package. The installation of Ubuntu of course includes installation of packages, but it also includes other things (e.g., disk partitioning, account creation, etc.). – muru Jun 4 '20 at 3:42
  • @muru I actually noticed that but I still haven't figured out how that "d-i" affects the behavior, and I guess it's partly because the documentation didn't explain the difference between an "installer" and an "installed system" (or maybe it's explained elsewhere that I am not aware of). – yaobin Jun 4 '20 at 18:21
0

The d-imeans debian-installer when expanded. It applies to variables only used in the Debian install process. That is when the whole Debian OS is being installed to computer.

So in this case:

  1. The "installer" installs Debian as a whole to be a working "installed system."

  2. In a manner of speaking yes, as the installer would use apt as a tool to install packages, but dpkg is another tool involved in the process as well.

  3. Technically, that can be where it is stored, but as a whole the Debconf database would refer to every Debconf variable that is stored, to it's contents, regardless of location. That is everything using Debconf to store data. Which can be the Debian installer, all packages installed and anything that used it directly.

  4. It's referring to the database containing installer variables that is written to disk on install.

This all involves the Debian installer. But if you aren't customising a Debian installer or preseed file, to be used before the fact, before installation of a whole OS, this will look confusing. If you are simply trying to install software on a working system then the d-istuff isn't relevant. In particular, a preseed is used in the Debian "OS" installer, to automate the settings.

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.