You are not logged in.

#1 2010-09-22 20:17:54

clovenhoof
Member
From: Bulgaria
Registered: 2010-09-16
Posts: 82

Clean up after each system upgrade

Hi,

After each upgrade my system increase its disk usage.
I type "pacman -Qet", and there is a lot of packets, but I'm not sure is it safe to delete them.

Which is the best rule to follow about cleaning the system, using pacman?

Last edited by clovenhoof (2010-09-22 20:18:47)

Offline

#2 2010-09-22 20:24:34

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: Clean up after each system upgrade

pacman -Sc

should clean your cache from all the packages that are NOT installed on your system. However, I would advise that you keep the cache intact atleast until you can be sure that your upgrades are working. That will help you in downgrading a package if you need to.

As far as -Qet,  if they are genuine orphans, then you can remove them safely. When you try a

pacman -Rns

on those packages, it should tell you if additional packages are going to be affected


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

#3 2010-09-22 20:26:33

mcmillan
Member
Registered: 2006-04-06
Posts: 737

Re: Clean up after each system upgrade

pacman -Qet tells which packages were explicitly installed and not required by other packages, I think you might be meaning -Qdt which will give unneeded dependencies.

As for the increase in disk usage after upgrades, it's because all packages are save in the cache. If you want to clear it out look at pacman -Sc and -Scc in the man page

Offline

#4 2010-09-22 20:26:49

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Clean up after each system upgrade

Well, if you're not sure, keep them. You need to know your system, what (more or less) every package does :-)
I think you're confusing -Qet with -Qdt - the latter is useful for removing stuff you (may) not need.

Edit: Sigh, someone bet me to it.

Last edited by karol (2010-09-22 20:27:29)

Offline

#5 2010-09-22 20:54:06

clovenhoof
Member
From: Bulgaria
Registered: 2010-09-16
Posts: 82

Re: Clean up after each system upgrade

Thanks!

I'll keep them.

For beginner as me it is hard to know what each packet is used for smile.
"pacman -Qdt" shows nothing, but for example, pacman has just upgraded my kernel, and the old one is safe to delete.

Is it really I have to know what each packet does, in order to delete unused packets manually?

Offline

#6 2010-09-22 20:58:49

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Clean up after each system upgrade

clovenhoof wrote:

Is it really I have to know what each packet does, in order to delete unused packets manually?

How will you know if it's needed for anything if you have no idea what that package does?
An example: what does 'git' do and why do I have it installed? Pacman shows it's not required by any package. Ah, I'm accessing some git repositories - that's why I have it installed.
You have only a couple hundred packages installed, so 'pacman -Qi <packagename>' away :-)

'pacman -Sc' should be enough to get rid of old & unneeded packages.

Last edited by karol (2010-09-22 21:01:47)

Offline

#7 2010-09-22 21:13:36

clovenhoof
Member
From: Bulgaria
Registered: 2010-09-16
Posts: 82

Re: Clean up after each system upgrade

OK.

I just think in future after many upgrades, and I didn't clear anything, my disk usage will be critical.

I thought that pacman delete old version packet before install the new one. I was bloody wrong.

edit: Ok, thanks again, I will use only "pacman -Sc".

Last edited by clovenhoof (2010-09-22 21:15:53)

Offline

#8 2010-09-22 21:16:02

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Clean up after each system upgrade

clovenhoof wrote:

OK.

I just think in future after many upgrades, and I didn't clear anything, my disk usage will be critical.

I thought that pacman delete old version packet before install the new one. I was bloody wrong.

I don't know what have you installed and how big your disk / partition is, but with my slim install I'm happily using a 40 GB disk since about a year so ... no worries :-)
Be sure to check your diskspace *before* starting an upgrade if you're low on free space.

Offline

Board footer

Powered by FluxBB