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

Re: removing all but critical packages



Hi,

Johann Koenig <explosive@att.net> writes:
[...]
> So here is the question: is there a way to strip the install to only
> base/core/required packages? Then I could start building the system up
> the way I'm used to. The only option I can think of at the moment is
> creating a list of installed packages on a clean system with 'dpkg
> --get-selections' and putting it on the other boxen with 'dpkg
> --set-selections.' However, I don't have any stripped boxen handy.
[...]

I am sure there are many ways, but here is one (untested):

Start "aptitude" in interactive mode.

$ aptitude

Mark all packages as "Automatically installed". That is:
put the cursor over the line
--- Installed Packages
and press "M" (capital M). Repeat this (just in case) for the lines
"Upgradable Packages", "Obsolete and Locally Created Packages", "Virtual
Packages", "Tasks" if they exists (some of these might not be necessary,
but it doesn't hurt...)

This will mark all packages, except those with priority "required", as
"Automatically installed", and will mark them for removing.

Before continuing, check that any packages that you consider important
are not going to be uninstalled (e.g. aptitude, maybe tasksel?).

Press "g" to start removing packages.

After you have reinstalled any packages you want, you might like to
purge the packages that have been removed. 

.- Start aptitude
.- select a view of "removed but not purged packages" pressing: "l"
   (limited view), "~c" (configuration files)  
.- mark all of them to be purged: select the highests hierarchy lines
   (most probably "--- Not Installed Packages"), and press "_" (to
   purge)
.- Press "g" to take the action.

I am almost sure that everything here can be done using the aptitude
command line, instead of the interactive interface.

Hope this helps,

Jaume 

-- 
Please answer to the group/list. Don't CC me.



Reply to: