You are not logged in.

#1 2025-03-24 11:07:36

themanofmanyways
Member
Registered: 2025-03-24
Posts: 3

Pacman Seems Desynced From Installed Packages

I had an issue with pacman not updating for several days and assumed it was from mirrors. I successfully installed reflector, started it with

sudo systemctl start reflector

, and restarted the computer.

However when running

sudo pacman -Syyu

, there was still "nothing to do".

    :: Synchronising package databases...
    core                                                                                               117.5 KiB  55.8 KiB/s 00:02 [#############################################################################] 100%
     extra                                                                                                7.7 MiB   228 KiB/s 00:35 [#############################################################################] 100%
     multilib                                                                                           133.0 KiB   193 KiB/s 00:01 [#############################################################################] 100%
    :: Starting full system upgrade...
     there is nothing to do

Hence I ran

pacman -Q

but ended up only with the following:

    bash 5.2.037-2
    bzip2 1.0.8-6
    e2fsprogs 1.47.2-1
    expat 2.7.0-1
    filesystem 2024.11.21-1
    gcc-libs 14.2.1+r753+g1cd744a6828f-1
    gdbm 1.24-2
    glibc 2.41+r9+ga900dbaf70f0-1
    iana-etc 20250213-1
    keyutils 1.6.3-3
    krb5 1.21.3-1
    libevent 2.1.12-4
    libffi 3.4.7-1
    libldap 2.6.9-1
    libnsl 2.0.1-1
    libsasl 2.1.28-5
    libtirpc 1.3.6-1
    libverto 0.3.2-5
    libxcrypt 4.4.38-1
    linux-api-headers 6.13-1
    lmdb 0.9.33-1
    mpdecimal 4.0.0-2
    ncurses 6.5-3
    openssl 3.4.1-1
    pacman-mirrorlist 20250311-1
    python 3.13.2-1
    readline 8.2.013-1
    reflector 2023-3
    sqlite 3.49.1-1
    tzdata 2025b-1
    util-linux-libs 2.41-2
    zlib 1:1.3.1-2

I noticed that most of them were installed as dependencies when I installed reflector (the sole exception is

pacman-mirrors

which I tried before fixing the reflector bug). But there are no entries for a lot of other packages I can use and have used (calibre, kde-plasma, thunderbird among numerous others). In fact, when I run

sudo pacman -S *application*

, it assumes it's a brand new installation. Case in point: discord.

    [user@user ~]$ sudo pacman -S discord
    [sudo] password for user: 
    resolving dependencies...
    looking for conflicting packages...
    warning: dependency cycle detected:
    warning: systemd-libs will be installed before its libcap dependency
    warning: dependency cycle detected:
    warning: harfbuzz will be installed before its freetype2 dependency
    warning: dependency cycle detected:
    warning: mesa will be installed before its libglvnd dependency

    Packages (142) acl-2.3.2-1  adwaita-cursors-48.0-1  adwaita-fonts-48.2-1  adwaita-icon-theme-48.0-1  adwaita-icon-theme-legacy-46.2-3  at-spi2-core-2.56.0-1  attr-2.5.2-1  audit-4.0.3-1
               avahi-1:0.8+r194+g3f79789-3  brotli-1.1.0-3  ca-certificates-20240618-1  ca-certificates-mozilla-3.109-1  ca-certificates-utils-20240618-1  cairo-1.18.4-1  cantarell-fonts-1:0.303.1-2
               coreutils-9.6-4  cryptsetup-2.7.5-2  curl-8.12.1-1  dav1d-1.5.1-1  dbus-1.16.2-1  dbus-broker-36-4  dbus-broker-units-36-4  dbus-units-36-4  dconf-0.40.0-3  default-cursors-3-1
               desktop-file-utils-0.28-1  device-mapper-2.03.31-1  duktape-2.7.0-7  file-5.46-3  findutils-4.10.0-2  fontconfig-2:2.16.1-1  freetype2-2.13.3-3  fribidi-1.0.16-1  gdk-pixbuf2-2.42.12-2
               glib-networking-1:2.80.1-1  glib2-2.84.0-1  gmp-6.3.0-2  gnutls-3.8.9-1  graphite-1:1.3.14-4  grep-3.11-1  gsettings-desktop-schemas-48.0-1  gsettings-system-schemas-48.0-1
               gtk-update-icon-cache-1:4.18.2-1  gtk3-1:3.24.49-1  gzip-1.13-4  harfbuzz-10.4.0-1  hicolor-icon-theme-0.18-1  hwdata-0.393-1  icu-76.1-1  iso-codes-4.17.0-1  jbigkit-2.1-8  json-c-0.18-1
               json-glib-1.10.6-1  kbd-2.7.1-2  kmod-34.1-1  lcms2-2.17-1  leancrypto-1.2.0-2  libcap-2.75-1  libcap-ng-0.8.5-3  libcloudproviders-0.3.6-1  libcolord-1.4.7-2  libcups-2:2.4.11-2  libdaemon-0.14-6
               libdatrie-0.2.13-4  libdrm-2.4.124-1  libedit-20250104_3.1-1  libelf-0.192-4  libepoxy-1.5.10-3  libgcrypt-1.11.0-3  libglvnd-1.7.0-1  libgpg-error-1.51-1  libidn2-2.3.7-1  libjpeg-turbo-3.1.0-1
               libnghttp2-1.65.0-1  libnghttp3-1.8.0-1  libnotify-0.8.4-1  libp11-kit-0.25.5-1  libpciaccess-0.18.1-2  libpng-1.6.47-1  libproxy-0.5.9-1  libpsl-0.21.5-2  librsvg-2:2.60.0-1  libseccomp-2.5.6-1
               libsoup3-3.6.5-1  libssh2-1.11.1-1  libstemmer-2.2.0-2  libsysprof-capture-48.0-1  libtasn1-4.20.0-1  libthai-0.1.29-3  libtiff-4.7.0-1  libunistring-1.3-1  libx11-1.8.12-1  libxau-1.0.12-1
               libxcb-1.17.0-1  libxcomposite-0.4.6-2  libxcursor-1.2.3-1  libxdamage-1.1.6-2  libxdmcp-1.1.5-1  libxext-1.3.6-1  libxfixes-6.0.1-2  libxft-2.3.8-2  libxi-1.8.2-1  libxinerama-1.1.5-2
               libxkbcommon-1.8.1-1  libxml2-2.13.6-3  libxrandr-1.5.4-1  libxrender-0.9.12-1  libxshmfence-1.3.3-1  libxss-1.2.4-2  libxtst-1.2.5-1  libxxf86vm-1.1.6-1  llvm-libs-19.1.7-1
               lm_sensors-1:3.6.0.r41.g31d1f125-3  lz4-1:1.10.0-2  lzo-2.10-5  mesa-1:25.0.2-2  nettle-3.10.1-1  nspr-4.36-1  nss-3.109-1  p11-kit-0.25.5-1  pam-1.7.0-2  pambase-20230918-2  pango-1:1.56.3-1
               pcre2-10.45-1  pixman-0.44.2-1  popt-1.19-2  sed-4.9-3  shadow-4.17.4-1  shared-mime-info-2.4-1  spirv-tools-1:1.4.309.0-1  systemd-257.4-1  systemd-libs-257.4-1  tinysparql-3.9.1-1
               util-linux-2.41-2  wayland-1.23.1-1  xcb-proto-1.17.0-3  xkeyboard-config-2.44-1  xorg-xprop-1.2.8-1  xorgproto-2024.1-2  xz-5.6.4-1  zstd-1.5.7-2  discord-0.0.88-2

    Total Download Size:   222.99 MiB
    Total Installed Size:  927.22 MiB

    :: Proceed with installation? [Y/n] 

Ordinarily, there should be no total download size for the package. Instead, there should be a net installation size of 0, and it should indicate that a reinstallation is taking place.

So it seems to me like the pacman has been desynced from packages which have been installed before. I suspect it has something to do with a timeshift restoration I performed last week, but I could update the system immediately after that with no issue. Arguably though, I did not look clearly to see if app-packages were included.

Will appreciate some help. Thank you.

Last edited by themanofmanyways (2025-03-24 12:05:15)

Offline

#2 2025-03-24 12:01:55

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 24,477

Re: Pacman Seems Desynced From Installed Packages

Please wrap outputs in [ code ] not [ quote ] tags.

Is your /var/lib/pacman/ (or any parts of that path) a symlink or some volatile filesystem or a snapshot of your timeshift or something? sounds like that got hosed. That said, the wiki contains a page for this situation: https://wiki.archlinux.org/title/Pacman … l_database

But assuming it's just a timeshift fuckup you should be able to restore that to a sane snapshot state again. What's your output of

mount
sudo btrfs subvolume list /

Last edited by V1del (2025-03-24 12:07:09)

Offline

#3 2025-03-24 12:07:40

themanofmanyways
Member
Registered: 2025-03-24
Posts: 3

Re: Pacman Seems Desynced From Installed Packages

V1del wrote:

Please wrap outputs in [ code ] not [ quote ] tags.

Is your /var/lib/pacman/ (or any parts of that path) a symlink or some volatile filesystem or a snapshot of your timeshift or something? sounds like that got hosed. That said, the wiki contains a page for this situation: https://wiki.archlinux.org/title/Pacman … l_database

But assuming it's just a timeshift fuckup you should be able to restore that to a sane snapshot state again.


I did nothing to make it volatile. at least, not from memory. I'll try the timeshift backup again thanks. Maybe it will resolve the issue. Thanks.

Offline

#4 2025-03-24 12:09:04

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 24,477

Re: Pacman Seems Desynced From Installed Packages

See my edit for some diagnostic commands, I'm assuming @var is a snapshot in your case, that got restored to it's initial empty state somehow.

Offline

#5 2025-03-24 12:12:09

themanofmanyways
Member
Registered: 2025-03-24
Posts: 3

Re: Pacman Seems Desynced From Installed Packages

V1del wrote:

See my edit for some diagnostic commands, I'm assuming @var is a snapshot in your case, that got restored to it's initial empty state somehow.


Here is the result:

[user@user ~]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=12133748k,nr_inodes=3033437,mode=755,inode64)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755,inode64)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p3 on / type ext4 (rw,relatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev,inode64)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate,memory_recursiveprot)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=41,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=12554)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,nosuid,nodev,relatime,pagesize=2M)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/credentials/systemd-journald.service type tmpfs (ro,nosuid,nodev,noexec,relatime,nosymfollow,size=1024k,nr_inodes=1024,mode=700,inode64,noswap)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/credentials/systemd-resolved.service type tmpfs (ro,nosuid,nodev,noexec,relatime,nosymfollow,size=1024k,nr_inodes=1024,mode=700,inode64,noswap)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,nr_inodes=1048576,inode64)
/dev/nvme0n1p1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
/dev/sda1 on /run/media/ulysses/Storage type ext4 (rw,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=2430244k,nr_inodes=607561,mode=700,uid=1000,gid=1000,inode64)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)

[user@user ~]$ sudo btrfs subvolume list /
[sudo] password for user: 
sudo: btrfs: command not found

[user@user ~]$ 

I don't have btrfs installed I think?

Offline

#6 2025-03-31 20:57:54

mountaintrek
Member
Registered: 2024-02-01
Posts: 54

Re: Pacman Seems Desynced From Installed Packages

themanofmanyways wrote:

I had an issue with pacman not updating for several days and assumed it was from mirrors.
...
I noticed that most of them were installed as dependencies when I installed reflector (the sole exception is

pacman-mirrors

which I tried before fixing the
...

If the package pacman-mirrors is correct, are you sure your Linux Distribution is archlinux and not manjaro. You may just need to use the correct repos/mirrors and visit the manjaro forum.

cat /etc/os-release
cat /etc/pacman.d/mirrorlist

If your distribution is archlinux, bottom line, it appears your local database might be corrupted, perhaps that original pacman "issue".  Initially I would have checked the pacman console messages, pacman log, and the journal to address the original issue. If you have a backup, restore. Otherwise there is a wiki page that might help, pacman/Restore local database.

Offline

Board footer

Powered by FluxBB