[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Basic questions about Debian package tools



pt3asw@gmail.com:
> 
> Is it true I should avoid APT and use some other frontend or, better,
> dpkg directly?

Never use dpkg directly if you don't have to. Apt-get and aptitude are
both good frontends with similar capabilities. Which one you use is
mostly a question of personal preference. Only when doing distribution
upgrades (like from lenny to squeeze) you should read the release notes
and use the tool that it suggests.

> I tried aptitude, but I don't like ncurses-based tools. I prefer the
> classic command line if possible.

Most operations for apt-get are also valid for aptitude.

> How can I obtain the list of sources currently used by installed packages?
> For example, since I have "gcc" installed, it should show "main", and
> since I also have "firmware-iwlwifi", it should include "non-free",
> too.
> This is for checking if /etc/apt/sources.list is consistent with
> installed packages.

I am not aware of any method to do this. What exactly do you want to
find out? Installed packages which are not available on any mirror
anymore? -Use aptitude's "Obsolete and Locally Created Packages" list.
There is probably a search pattern for this as well (install
aptitude-doc-en).

> I'm not sure if the following procedure is right for staying up to date:
> apt-get update; apt-get upgrade; apt-get autoremove --purge; apt-get autoclean

I would leave out autoremove and autoclean, but then I use aptitude
which does this automatically and I have the following settings in
/etc/apt/apt.conf.d/local:

APT {
        // settings for cron.daily/apt
        // see: /etc/cron.daily/apt
        Periodic {
                AutocleanInterval "1";
                MinAge "3";
                MaxAge "7";
                MaxSize "1024";
        }

}

Apt contains a cron job which cleans the cache automatically according
to the settings above.

J.
-- 
I wish I could do more to put the sparkle back into my marriage.
[Agree]   [Disagree]
                 <http://www.slowlydownward.com/NODATA/data_enter2.html>

Attachment: signature.asc
Description: Digital signature


Reply to: