Updated after couple months using yay -Syyu.
Update fails after some time with a meesage /var/cache/ … pacman missing.
I found out pacman is now missing.
I restored to my latest backup 11/dec/2023 using timeshift and repeated the update process using pacman -Syyu
same failure, but this time appart from pacman someother libraries are missing and cannot run timeshift. I manually restored missing timeshift libs and manage to restore the latest bckup from 11/12/2023.
Not sure how should I proceed in order to update the system properly. Any advise? am I doing something wrong?
It rather sounds like something on your system has got corrupted before the upgrade. I’d suggest going back to an earlier backup and making sure your system is fully operational before trying to upgrade again.
Then use the mouse to mark the text inside the terminal emulator (the last 20-30 lines or so should suffice) and paste it into a comment inside a code fence like this example
Instead of full update, I tried only with pacman, which seems to be the origin of the problem, The update fails and pacman is no longer in the system:
~/projects >>> yay -S pacman [130]
Sync Explicit (1): pacman-6.0.2-16
resolving dependencies...
looking for conflicting packages...
Packages (1) pacman-6.0.2-16
Total Installed Size: 4,84 MiB
Net Upgrade Size: 0,00 MiB
:: Proceed with installation? [Y/n]
(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%
(1/1) checking available disk space [##############################################################################################################################################################] 100%
:: Processing package changes...
error: could not open file /var/cache/pacman/pkg/pacman-6.0.2-16-x86_64.pkg.tar.zst: No such file or directory
error: could not commit transaction
error: failed to commit transaction (transaction aborted)
Errors occurred, no packages were upgraded.
-> error installing repo packages
Thanks for the advice, I’ll try to do that. Just for clarification, yes, I know yay is wrapping pacman, but everything is fine before I execute “yay -S pacman”. I mean pacman is removed as a consequence of this operation somehow… Also libalpm.so.13 is not there anymore.
pamac install pacman
pamac: error while loading shared libraries: libalpm.so.13: cannot open shared object file: No such file or directory
Through the link I downloaded “pacman-static” and after deleting empty folder “/var/lib/pacman/pacman-6.0.2-16” I was able to reinstall pacman.
After that I could make a full update with no issue apparently. No idea why could the pacman update kept getting “corrupted” in the first place though.