How to configure apt-get to install suggested packages?
DebianThis forum is for the discussion of Debian Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How to configure apt-get to install suggested packages?
Eg.
david:/etc/apt# apt-get install bind9
Reading Package Lists... Done
Building Dependency Tree... Done
The following extra packages will be installed:
libdns11 libisc7 libisccc0 libisccfg0 liblwres1
Suggested packages:
dnsutils bind9-doc
The following NEW packages will be installed:
bind9 libdns11 libisc7 libisccc0 libisccfg0 liblwres1
0 upgraded, 6 newly installed, 0 to remove and 0 not upgraded.
Need to get 1105kB of archives.
After unpacking 2646kB of additional disk space will be used.
How to configure apt-get such that it will also install dnsutils and bind9-doc (suggested packages) in addition to bind9 package?
Also, are /etc/apt/preferences and /etc/apt/apt,conf files created by default upon apt installation? Cos I only have the following files in my /etc/apt :
david:/etc/apt# ls
apt-file.conf apt.conf.d sources.001 sources.list
Normally, what I do is type (y) and let it install what I originally asked for, then I issue a second apt-get install command and copy and paste the earlier suggested packages after the apt-get install command. Or you could type (n) to say no and redo your install command to have all of them like so:
I think that automatically adding all suggested packages would put a lot of cruft on your system. However, if you want it, you can get that behavior by adding a line to /etc/apt/apt.conf:
The second line will automate suggests and the first would automate installation of recommends. You can use either or both, though again, lots of cruft. If you don't yet have an /etc/apt/apt.conf file, you can create it and add just the one line.
Last edited by Telemachos; 07-20-2007 at 06:19 AM.
I think that automatically adding all suggested packages would put a lot of cruft on your system. However, if you want it, you can get that behavior by adding a line to /etc/apt/apt.conf:
The second line will automate suggests and the first would automate installation of recommends. You can use either or both, though again, lots of cruft. If you don't yet have an /etc/apt/apt.conf file, you can create it and add just the one line.
That's good to know. Interesting to see this thread bumped up after 3 years....
That's good to know. Interesting to see this thread bumped up after 3 years....
Wow, yeah. The funny thing is that I saw the thread at the top of the list this morning in the Debian forum, so I stuck my two cents in. I didn't even look at the original posting dates. And here I am bumping it up again. Ah well...
Wow, yeah. The funny thing is that I saw the thread at the top of the list this morning in the Debian forum, so I stuck my two cents in. I didn't even look at the original posting dates. And here I am bumping it up again. Ah well...
Thanks for having this tidbit here. It helped me today.
Distribution: Ubuntu Linux 16.04, Debian 10, LineageOS 14.1
Posts: 1,572
Rep:
Quote:
Originally Posted by Telemachos
I think that automatically adding all suggested packages would put a lot of cruft on your system. However, if you want it, you can get that behavior by adding a line to /etc/apt/apt.conf:
The second line will automate suggests and the first would automate installation of recommends. You can use either or both, though again, lots of cruft. If you don't yet have an /etc/apt/apt.conf file, you can create it and add just the one line.
If you have apt.conf set up like this, you can avoid installing recommends via:
Code:
apt-get --no-install-recommends install package
This will prevent apt from considering recommended packages as a dependency for installing, even if apt.conf is configured to do so via "APT::Install-Recommends".
you can also specify the option on the command line, like this:
sudo apt-get install <package> -o APT::Install-Suggests=true
but apt-get install will follow the "suggests" for all installed packages, not just the one you are adding now.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.