You are not logged in.

#1 2015-01-26 06:40:11

theodore
Member
Registered: 2008-09-09
Posts: 151

[SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

Hi guys, yesterday night I tried to update my system and I got the following error which seems weird:

resolving dependencies...
looking for conflicting packages...

Package (1)  Old Version  New Version  Net Change

core/pacman  4.2.0-5      4.2.0-6        0.00 MiB

Total Installed Size:  4.22 MiB
Net Upgrade Size:      0.00 MiB

:: Proceed with installation? [Y/n] y
(1/1) checking keys in keyring                                                                      [##########################################################] 100%
(1/1) checking package integrity                                                                    [##########################################################] 100%
(1/1) loading package files                                                                         [##########################################################] 100%
(1/1) checking for file conflicts                                                                   [##########################################################] 100%
error: failed to commit transaction (conflicting files)
pacman: /var/cache/pacman/pkg exists in filesystem
Errors occurred, no packages were upgraded.

It seems weird to me because it conflicts to the whole folder and not to any specific package. Any clue, what is going on and how to solve it?

Last edited by theodore (2015-01-26 19:51:37)

Offline

#2 2015-01-26 08:59:31

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,395
Website

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

Is your /var/cache/pacman/pkg a directory or a symlink?

Offline

#3 2015-01-26 11:34:09

theodore
Member
Registered: 2008-09-09
Posts: 151

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

Allan wrote:

Is your /var/cache/pacman/pkg a directory or a symlink?

yes I have it in a different partition and then I have symilinked it

Offline

#4 2015-01-26 12:38:39

clfarron4
Member
From: London, UK
Registered: 2013-06-28
Posts: 2,163
Website

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

theodore wrote:
Allan wrote:

Is your /var/cache/pacman/pkg a directory or a symlink?

yes I have it in a different partition and then I have symilinked it

I'd have thought it would have been better to set a different directory for the pacman cache, mounting the partition to that through /etc/fstab and using the CacheDir variable in /etc/pacman.conf, but I'll leave that to your judgement.

If you don't want to do that, then I'll leave someone else to put up a solution (my brain's screaming bind mounts for some unknown reason).

Last edited by clfarron4 (2015-01-26 12:40:39)


Claire is fine.
Problems? I have dysgraphia, so clear and concise please.
My public GPG key for package signing
My x86_64 package repository

Offline

#5 2015-01-26 14:04:53

theodore
Member
Registered: 2008-09-09
Posts: 151

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

clfarron4 wrote:
theodore wrote:
Allan wrote:

Is your /var/cache/pacman/pkg a directory or a symlink?

yes I have it in a different partition and then I have symilinked it

I'd have thought it would have been better to set a different directory for the pacman cache, mounting the partition to that through /etc/fstab and using the CacheDir variable in /etc/pacman.conf, but I'll leave that to your judgement.

If you don't want to do that, then I'll leave someone else to put up a solution (my brain's screaming bind mounts for some unknown reason).


So, you are saying that I should enable the CacheDir in /etc/pacman.conf and point it to the partition where I have now the pacman cache.

Offline

#6 2015-01-26 14:40:56

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,395
Website

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

CacheDir is the way to go.   Or do a bind mount if you don't want to use CacheDir for some reason.

Offline

#7 2015-01-26 15:56:01

theodore
Member
Registered: 2008-09-09
Posts: 151

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

Thanks you guys.

One last question, after I change the path that CacheDir points to, do I need to erase the /var/cache/pacman/pkg symlink directory as well?

Last edited by theodore (2015-01-26 16:46:26)

Offline

#8 2015-01-26 19:15:42

Leonid.I
Member
From: Aethyr
Registered: 2009-03-22
Posts: 999

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

theodore wrote:

Thanks you guys.

One last question, after I change the path that CacheDir points to, do I need to erase the /var/cache/pacman/pkg symlink directory as well?

Yes, you need to create a real dir /var/cache/pacman/pkg with permissions 0755 root:root because it is owned by pacman.


Arch Linux is more than just GNU/Linux -- it's an adventure
pkill -9 systemd

Offline

#9 2015-01-26 19:47:29

theodore
Member
Registered: 2008-09-09
Posts: 151

Re: [SOLVED] error pacman: /var/cache/pacman/pkg exists in filesystem

Leonid.I wrote:
theodore wrote:

Thanks you guys.

One last question, after I change the path that CacheDir points to, do I need to erase the /var/cache/pacman/pkg symlink directory as well?

Yes, you need to create a real dir /var/cache/pacman/pkg with permissions 0755 root:root because it is owned by pacman.

thanks for the confirmation, everything is fine now.

Offline

Board footer

Powered by FluxBB