Why are almost all packages marked as manually installed?

I just installed Maverick and was surprised that almost all packages are marked as manually installed (linux-headers and wireless-crda aren't). Doesn't that defeat the purpose of the differentiation between automatically and manually installed packages?


Seems my Google powers were weakened: this is a known bug (concentrate on comments from Colin Watson) and it's hanging around for some time with no fix in sight:

Quoting Colin Watson:
[...] Leaving all packages as manually installed is unsightly but the consequences of this bug are generally limited to not managing to be clever enough to remove packages that aren't needed any more. A flaw in the reverse direction would be much worse, because it could cause packages to be removed when they are still needed. Given that there does not seem to be a clearly correct fix available, it's better to air [sic] on the side of caution. [...]

Okay, now this is the first thing I do right after installation. I mark (almost) every package as automatically installed, and they stay as dependencies of ubuntu-desktop:

apt-mark showmanual | xargs sudo apt-mark auto
sudo apt-mark unmarkauto ubuntu-desktop 

Ideally, that would be enough. But as per Colin Watson, the world isn't so perfect, and we need some more polishing. Iterate:

apt-get autoremove --simulate
# ...
# output of what's to be autoremoved
sudo apt-mark unmarkauto <package>

where <package> for me ends up at least as each of ubuntu-standard, ubuntu-minimal, ubuntu-restricted-addons. Also some language packs.

Worth noting is also aptitude, which with its TUI can aid the process.

Having done this, my system's package manager reports look so much more pleasant and comprehensible:

$ apt-mark showmanual
aptitude
dkms
git
subversion
ubuntu-desktop
ubuntu-minimal
ubuntu-restricted-addons
ubuntu-standard
vim
zsh

Voila!