OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
pacman-aur low occasional DISPUTE

Silence 'ldconfig: ... is not a symbolic link' after every upgrade

archomarchyendeavouroscachyosmanjarodesktoplaptop
CORRECTED An auditor found the fix wrong or incomplete and rewrote it. · checked against Omarchy omarchy 4.0.4-1 on 2026-10-05
AUDIT NOTE

Thread 305501 supports the diagnosis: pacman -Qo showed all three files unowned, left by a manual pacman -U of an old libxml2, and deleting them silenced ldconfig. Two defects remain in the current text. First, it states that libxml2.so.2 belongs to no current Arch package. That is false: [extra] ships libxml2-legacy 2.13.9-2, whose file list (archlinux.org, retrieved) contains /usr/lib/libxml2.so.2, and the AUR has icu75 for libicudata.so.75. The earlier audit inferred this from a local pacman -Qo, which only proves the file is unowned on that one machine. A program still linked to libxml2.so.2 is exactly why such a stray copy gets made, so the reader needs to know the packaged replacement exists. Second, the delete step is a copy-paste sudo rm of the three example paths, and the in-use check greps only libxml2.so.2, despite the sentence telling the reader not to act on the example names. The corrected fix builds the list from ldconfig's own output, skips anything pacman owns, and moves rather than deletes, so a mistake is reversible. The parsing sed and the pacman -Qo exit codes were tested here (libxml2.so.2 unowned rc=1, libxml2.so.16 owned rc=0). ldconfig and the move were not run, since they need root.

The cause above was not rewritten and may still contain the error described. The fix below is the corrected version.
RISK

Moves files out of /usr/lib. The loop skips anything pacman -Qo reports as owned, and moves rather than deletes, so a library a program still needs can be put back from /root/stray-libs or replaced by its packaged equivalent (libxml2-legacy for libxml2.so.2). Run it only after a full system update.

Symptom

Every pacman transaction that installs anything prints, just before Running post-transaction hooks...:


ldconfig: /usr/lib/libicudata.so.75 is not a symbolic link
ldconfig: /usr/lib/libicuuc.so.75 is not a symbolic link
ldconfig: /usr/lib/libxml2.so.2 is not a symbolic link

The upgrade itself completes. Running sudo ldconfig by hand prints the same lines.

Cause

ldconfig expects a library's soname (libfoo.so.N) to be a symlink to the real versioned file. When a regular file sits at that name instead, ldconfig warns. The usual origin is a library copied into /usr/lib by hand, or by a vendor installer, to fix some earlier breakage. That file is owned by no package, so pacman never updates or removes it, and the warning repeats forever. Less often the file is owned by a package that ships it that way, which is a packaging quirk and harmless.

Fix

Find out who owns each file ldconfig complains about. Use pacman -Qo (the local database), not pacman -F, which searches the files database and can be stale:


sudo ldconfig 2>&1 | sed -n 's/^ldconfig: \(.*\) is not a symbolic link$/\1/p' | xargs -r pacman -Qo

Each path prints either is owned by <package> or error: No package owns <path>.

**Unowned files.** These are stray copies, usually left by copying a library in by hand or by installing an old package file with pacman -U. Update the system fully first:


# Omarchy 4
omarchy update
# Plain Arch
sudo pacman -Syu

Then move every unowned file ldconfig names out of the library path. Owned files are skipped. Moving instead of deleting keeps a copy you can put back:


sudo mkdir -p /root/stray-libs
for f in $(sudo ldconfig 2>&1 | sed -n 's/^ldconfig: \(.*\) is not a symbolic link$/\1/p'); do
  pacman -Qo "$f" >/dev/null 2>&1 || sudo mv -v "$f" /root/stray-libs/
done
sudo ldconfig

A silent sudo ldconfig confirms the fix. If a program then fails with error while loading shared libraries: libxml2.so.2: cannot open shared object file, it still needs the old soname. Install the packaged copy rather than restoring the stray one:


sudo pacman -S libxml2-legacy

libxml2-legacy is in [extra] and ships /usr/lib/libxml2.so.2. For an old ICU soname such as libicudata.so.75, the AUR package icu75 is the packaged equivalent. Once nothing breaks, delete the backup with sudo rm -r /root/stray-libs.

**Owned by a package.** Check whether its files still match the package, and reinstall it after a full update if they do not:


pacman -Qkk <package>
sudo pacman -S <package>

If it still warns after a reinstall, the package ships a regular file at the soname. That is harmless and can be reported to the packager.

Verify

sudo ldconfig prints nothing.

Sources

ldconfig-is-not-a-symbolic-link