- How to Update Manjaro and Other Arch-based Linux Distributions
- Update Arch or Manjaro Linux using the command line
- How to Update Arch Linux
- How to update Arch Linux
- How to update the database and packages
- How to perform a forceful system update
- Bonus Tip
- Conclusion
- Pacman Commands Cheat Sheet for Arch Linux
- Updating and Upgrading Arch Linux
- Install Package(s) in Arch Linux
- Remove Package(s) in Arch Linux
- Query Package(s) in Arch Linux
- Arch Linux Pacman Cheat Sheet
How to Update Manjaro and Other Arch-based Linux Distributions
How to update Manjaro Linux or Arch Linux? This sounds like a simple topic, isn’t it? While this is certainly useful for beginners, reading these ‘simple topics’ often lead to some hidden gems that you might not be aware of.
For example, in this article, I’ll discuss both GUI and terminal ways of updating your Arch-based distribution. The interesting part is the subtle difference between pacman -Syu and pacman -Syyu (with an extra y) commands.
I am a Manjaro user and I love it. I have written this tutorial using Manjaro but the command part is applicable for other Arch-based distributions as well. I’ll also show the GUI application for Manjaro.
- Updating Manjaro and other Arch-based distributions using command line
- Updating Manjaro Linux using GUI
Let’s see how to keep your software and system up-to-date
Update Arch or Manjaro Linux using the command line
You can access the terminal by typing Ctrl+Alt+T or by clicking on the menu button on the left-hand side corner and finding it by typing terminal. Personally, I find that updating any distro through the terminal is faster and more robust.
The simplest way to update Arch Linux distributions is to use:
It compares the local package database against the distribution’s software repository. If there are any new package versions available, you will be prompted to type yes to update the outstanding packages.
There is another way to update your system.
You can notice the extra y in this command. The extra y forces the package manager to download the package database regardless of whether there is any change in the versions.
This is helpful when you have a corrupted package database and you want to force synchronization.
I don’t recommend using sudo pacman -Syyu all the time because it will unnecessarily take a long time to synchronize the database. It will also consume more network bandwidth.
As you can see in the image above, even if my system is up-to-date, the database is still being updated.
Note: Arch-based Garuda Linux provides a custom command garuda-update which should be using the pacman command underneath.
Recommended Read:
How to Update Arch Linux
Linux-based systems require frequent updates as the updates carry bug fixes, security updates, better interactivity, and much more. Arch Linux is among the Linux distros that have rolling releases that state that Arch Linux must be updated frequently to get the updates.
In Arch Linux, the advantages of updating the system are manifold, such as getting the latest version of packages or synchronizing the system’s database with the official repository. However, one can update the Arch Linux system to fix the broken packages and download the latest version to replace them.
Keeping in view the importance of updates on Arch Linux, this article provides the possible ways to update Arch Linux.
How to update Arch Linux
Arch Linux and its distributions have a package manager named Pacman such as apt in Debian-based distributions.
How to update the database and packages
The Pacman can be used to synchronize and update the system’s packages with the newest releases. To do so, use the following command:
The above image shows that the packages are up to date.
How to perform a forceful system update
What if you have broken packages and you want to update them as well?
In such a situation, the Pacman is exercised with the “-Syyu” flag. The “-Syu” just synchronized and upgraded the packages. However, the “-Syyu” will recreate the database with an upgraded set of packages and can be executed in the following manner:
It would take some time because all the packages would be downloaded whether they are broken or not.
Bonus Tip
Apart from updating the whole system’s database and packages. The Pacman allows you to update a single package as well by issuing the command written below.
The must be replaced with the package you want to update.
Note: In this article, all the commands are executed as a root user.
Conclusion
Arch Linux can be updated using the Pacman (package manager of Arch Linux). This article provides a descriptive guide to update Arch Linux. The package manager of Arch Linux named Pacman supports “-Syu” and “-Syyu” flags that can be used to update Arch Linux. The “-Syu” option synchronizes and updates the system, whereas the “-Syyu” flag downloads the fresh copies of all the packages. It is recommended to execute the “-Syu” in various scenarios such as, before installing any package, or for a routine system update. However, the “-Syyu” must be exercised only when there are broken packages in your Arch Linux.
Pacman Commands Cheat Sheet for Arch Linux
One uniqueness or key identifier of different Linux distributions is in the package manager they use to update, install, configure, and uninstall various targeted software packages. In Arch Linux, the package manager is called Pacman.
This tutorial seeks to walk you through some commonly used and unique Pacman commands that will make your Arch Linux interaction and experience easier and much more memorable.
It is highly advisable to be a root user or have Sudoer user privileges on your Arch Linux system to fully benefit from what the Pacman command has to offer.
Updating and Upgrading Arch Linux
If you only want to update the software database of your Arch Linux system, go with the following command:
To update and upgrade your Arch Linux system, go with the following command:
Install Package(s) in Arch Linux
If you have a specific package called an apache web server in mind that you wish to install, it is advisable to first search for the availability of the package. This step is useful because some Linux OS distributions identify common packages differently.
To install an identified package, adhere to the following command:
Supposing you have a local package or one that you have downloaded from a website and wish to install it, you need to adhere to the following command.
$ sudo pacman -U /path/to/your/installable/package
For all repo-based packages re-installation (during emergencies), implement the following command.
$ sudo pacman -Qnq | pacman -S -
Remove Package(s) in Arch Linux
To remove or uninstall a specific Arch Linux installed package, adhere to the following command.
$ sudo pacman -R name_of_package
To remove or uninstall an Arch Linux package together with its dependencies not tied to other active packages, reference the following command syntax:
$ sudo pacman -Rs name_of_package
To uninstall a specific Arch Linux package, remove its global configuration, and avoid its orphaned dependencies, use the following command syntax.
$ sudo pacman -Rns name_of_package
Query Package(s) in Arch Linux
You might wish to retrieve some information about an installed package. The command syntax to use is as follows:
$ pacman -Qi name_of_package
For the apache package we installed earlier, we can get the following info about it:
We can also query about an installable package and its associated dependencies via the command syntax:
$ sudo pacman -Sii name_of_package
To list installed packages, execute the command:
Arch Linux Pacman Cheat Sheet
Following are the list of commonly used commands for the Pacman package manager in Arch Linux.
Command | Description |
sudo pacman -Syy | Update package list |
sudo pacman -Syu | Update and upgrade all |
sudo pacman -S pkgname | Install specific package |
sudo pacman -Ss keyword | Find available packages |
sudo pacman -Qs keyword | Find available local packages |
sudo pacman -Ql pkgname | List all files from a package |
Sudo pacman -Rsc pkgname | Uninstall a package |
sudo pacman -Qii pkgname | List information on package |
With the Pacman command cheat sheet, you should be comfortable enough to take your Arch Linux OS experience to the next level.