Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to downgrade Arch Linux package

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces how Arch Linux software package degradation, the article is very detailed, has a certain reference value, interested friends must read it!

Sometimes, you want to update to the latest version, but you may get stuck with broken packages. Don't panic! In this case, you can simply roll back to the old stable package. This short tutorial describes how to downgrade a package in Arch Linux and its variants such as Antergos, Manjaro Linux

Downgrading a package in Arch Linux

In Arch Linux, there is a utility called "downgrade" that helps you downgrade installed packages to whatever older version is available. This utility will check your local cache and remote server (Arch Linux repository) for older versions of the desired package. You can select any old stable package from this list and install it.

This package is not available in the official repository, you need to add the unofficial archlinuxfr repository.

To do this, edit the/etc/pacman.conf file:

$ sudo nano /etc/pacman.conf

Add the following line:

[archlinuxfr]SigLevel = NeverServer = http://repo.archlinux.fr/$arch

Save and close the file.

Use the following command to update the repository:

$ sudo pacman -Sy

Then install the Downgrade utility in the terminal using the following command:

$ sudo pacman -S downgrade

Example output:

resolving dependencies... looking for conflicting packages... Packages (1) downgrade-5.2.3-1Total Download Size: 0.01 MiBTotal Installed Size: 0.10 MiB:: Proceed with installation? [Y/n]

A typical use of the "downgrade" command is:

$ sudo downgrade [PACKAGE, ...] [-- [PACMAN OPTIONS]]

Let's say you want to downgrade Opera web browser to whatever older version is available.

To this end, run:

$ sudo downgrade opera

This command lists all available opera packages (old and new) from local cache and remote mirror.

Example output:

Available packages:1) opera-37.0.2178.43-1-x86_64.pkg.tar.xz (local)2) opera-37.0.2178.43-1-x86_64.pkg.tar.xz (remote)3) opera-37.0.2178.32-1-x86_64.pkg.tar.xz (remote)4) opera-36.0.2130.65-2-x86_64.pkg.tar.xz (remote)5) opera-36.0.2130.65-1-x86_64.pkg.tar.xz (remote)6) opera-36.0.2130.46-2-x86_64.pkg.tar.xz (remote)7) opera-36.0.2130.46-1-x86_64.pkg.tar.xz (remote)8) opera-36.0.2130.32-2-x86_64.pkg.tar.xz (remote)9) opera-36.0.2130.32-1-x86_64.pkg.tar.xz (remote)10) opera-35.0.2066.92-1-x86_64.pkg.tar.xz (remote)11) opera-35.0.2066.82-1-x86_64.pkg.tar.xz (remote)12) opera-35.0.2066.68-1-x86_64.pkg.tar.xz (remote)13) opera-35.0.2066.37-2-x86_64.pkg.tar.xz (remote)14) opera-34.0.2036.50-1-x86_64.pkg.tar.xz (remote)15) opera-34.0.2036.47-1-x86_64.pkg.tar.xz (remote)16) opera-34.0.2036.25-1-x86_64.pkg.tar.xz (remote)17) opera-33.0.1990.115-2-x86_64.pkg.tar.xz (remote)18) opera-33.0.1990.115-1-x86_64.pkg.tar.xz (remote)19) opera-33.0.1990.58-1-x86_64.pkg.tar.xz (remote)20) opera-32.0.1948.69-1-x86_64.pkg.tar.xz (remote)21) opera-32.0.1948.25-1-x86_64.pkg.tar.xz (remote)22) opera-31.0.1889.174-1-x86_64.pkg.tar.xz (remote)23) opera-31.0.1889.99-1-x86_64.pkg.tar.xz (remote)24) opera-30.0.1835.125-1-x86_64.pkg.tar.xz (remote)25) opera-30.0.1835.88-1-x86_64.pkg.tar.xz (remote)26) opera-30.0.1835.59-1-x86_64.pkg.tar.xz (remote)27) opera-30.0.1835.52-1-x86_64.pkg.tar.xz (remote)28) opera-29.0.1795.60-1-x86_64.pkg.tar.xz (remote)29) opera-29.0.1795.47-1-x86_64.pkg.tar.xz (remote)30) opera-28.0.1750.51-1-x86_64.pkg.tar.xz (remote)31) opera-28.0.1750.48-1-x86_64.pkg.tar.xz (remote)32) opera-28.0.1750.40-1-x86_64.pkg.tar.xz (remote)33) opera-27.0.1689.76-1-x86_64.pkg.tar.xz (remote)34) opera-27.0.1689.69-1-x86_64.pkg.tar.xz (remote)35) opera-27.0.1689.66-1-x86_64.pkg.tar.xz (remote)36) opera-27.0.1689.54-2-x86_64.pkg.tar.xz (remote)37) opera-27.0.1689.54-1-x86_64.pkg.tar.xz (remote)38) opera-26.0.1656.60-1-x86_64.pkg.tar.xz (remote)39) opera-26.0.1656.32-1-x86_64.pkg.tar.xz (remote)40) opera-12.16.1860-2-x86_64.pkg.tar.xz (remote)41) opera-12.16.1860-1-x86_64.pkg.tar.xz (remote)select a package by number:

Simply enter the package number of your choice and press Enter to install.

That's it. Currently installed packages will be downgraded to older versions.

So, how do you avoid corrupted packages and make Arch Linux more stable?

Check Arch Linux news [2] and forums [3] before updating Arch Linux to see if there are any reported issues. I've been using Arch Linux as my primary operating system for the past few weeks, and here are some simple tips I've found during that time to avoid installing unstable packages in Arch Linux.

Avoid partial escalation. This means never running pacman -Sy. This command will partially upgrade your system when installing the package. Instead, use pacman -Syu to update the system first, then use package -S to install the package. Avoid using pacman -Syu -force command. - The force flag ignores package and file conflicts and may end up with a broken package or a corrupted system. Do not skip dependency checks. This means don't use pacman -Rdd. This command avoids dependency checking when deleting packages. If you run this command, another critical dependency required by an important package can also be removed. Eventually, it will damage your Arch Linux. It is always a good habit to backup important data and configuration files regularly to avoid data loss. Be careful when installing third-party packages and unofficial packages such as AUR. Do not install packages that are undergoing significant development. That's all for "How Arch Linux packages are downgraded." Thanks for reading! Hope to share the content to help everyone, more relevant knowledge, welcome to pay attention to the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report