The 'correct' way to update

Running Manjaro KDE.

When updates are available, I get a notification in the system tray. Now, I can go about updating in three different ways:

  • From the command line β€” sudo pacman -Syyu
  • From the KDE discover app and
  • From pamac app

Which is the best method? In terms of the update going ahead without any errors, etc. and easy recovery in case of any errors?

1 Like

… I dont think so.
Unless something has changed recently … thats just for things like KDE addons/widgets/themes (and maybe SNAPs and stuff) … its not interacting with Manjaro Repos at all.
(also thus why I avoid it entirely except for maybe a quick browse of an icon theme)

Perfectly fine, classic update.
(the 2 'y’s would not be necessary unless you touched mirrors … but by default pamac has a background service that sorts mirrors … so if that is enabled, then 2 'y’s must be used)

That works too.

I guess it could also be noted that pacman does not handle any SNAPs, Flatpaks, or AUR packages … just regular repo ones. You would need other managers or methods to update those if you update your system using pacman.

pamac on the other hand should handle all of those.

So if you use pamac and snaps and stuff … probably use that.

I dont … so my update looks more like this (pacman update, then yay for AUR packages):

sudo pacman -Syu && yay -Sua --devel
7 Likes

Only tested it on KDE Plasma-git version and works decently fine for everything, including Manjaro updates. Even shows the mirrors used that can be enabled or disabled, and custom mirrors like herecura.
Still prefer pamac or pacman tho.

2 Likes

AFAIK they behave pretty much the same.
Only on specific updates some GUIs may freeze during the update, in which case it will be explicitly recommended to use CLI clients in the announcement thread. Otherwise, you can use whichever you want.

you may also consider in case of huge updates, specially when kernels, xorg, systemd etc. are involved, and stable has often huge updates, to do it in tty

log off your account than Ctrl+Alt+F2 or F3
type your user name
type password
than type sudo pacman -Syu
type again your password
and go

1 Like

For the most part, they should all work fine.
Personally i prefer running pacman -Syyu (usually just in yakuake), because of the more detailed output, should anything special happen.
For some critical updates it’s recommended to go to a TTY (as already mentioned), but that’s pretty rare.
If you want to be on the (more or less) safe side without bothering with TTY, you could also run screen before running pacman -Syyu, that way the update would continue even if your DE/UI would crash during update.

1 Like

Discover can install repo packages with it’s optional dependency packagekit-qt5 installed. However, using PackageKit is neither recommended nor supported.

3 Likes

For a quick check I run pacman -Syu.

Then I run my conky which shows me my last timeshift snapshot/back-in-time backup.

After that, for a big upgrade, log out and enter a TTY…
Then I run pacman -Syu and follow up with β€˜topgrade’ which catches everything that pacman misses (including zsh, flatpak, snap, and firmware)

2 Likes

Yay covers it all.

yay for yay! It’s really very clever.

I just ran β€œman screen” in a terminal and couldn’t find anything about it, what is it? What does it do?

I have been making a timeshift restore point and then running pacman -Syyu then if there was AUR builds in Pamac I would build them in there. I am relatively new to Manjaro/Arch though.

Hmmm… ? :thinking:

❯ pacman -F /usr/bin/screen
usr/bin/screen is owned by extra/screen 4.8.0-2

https://www.gnu.org/software/screen/

as far as i understand it, when running screen first, it β€œdetaches” the terminal session from the terimal emulator. So if the UI crashes, it still can run in the β€œbackground” and complete the update.
I don’t usually do that on my system, but for example when i do a bigger update remote on my mums PC (living thousands of miles apart), i don’t want to risk anything ^^

Yay doesn’t cover ALL. That’s why topgrade is useful.
Topgrade runs yay.

To do a quick dry run, use topgrade -n
~ >>> topgrade -n

―― 08:18:35 - System update ――――――――――――――――――――――――――――――――――――――――――――――――――――
Dry running: /usr/bin/yay -Pw
Dry running: /usr/bin/yay --pacman /usr/bin/pacman -Syu --devel

―― 08:18:35 - oh-my-zsh ――――――――――――――――――――――――――――――――――――――――――――――――――――――――
Pulling custom plugins and themes
Would pull /home/ben/.oh-my-zsh/custom/plugins/zsh-autosuggestions
Would pull /home/ben/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting
Dry running: sh /home/ben/.oh-my-zsh/tools/upgrade.sh

―― 08:18:35 - Flatpak User Packages ――――――――――――――――――――――――――――――――――――――――――――
Dry running: /usr/bin/flatpak update --user -y
Dry running: /usr/bin/flatpak update --system -y

―― 08:18:35 - snap ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――
Dry running: /usr/bin/sudo /usr/bin/snap refresh

―― 08:18:35 - Firmware upgrades ――――――――――――――――――――――――――――――――――――――――――――――――
Dry running: /usr/bin/fwupdmgr refresh
Dry running: /usr/bin/fwupdmgr get-updates

―― 08:18:35 - Summary ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――
System update: OK
oh-my-zsh: OK
Flatpak: OK
snap: OK
Firmware upgrades: OK

It’s plain to see that it will pick up on more things in your system than just pacman or yay - so it makes a nice follower to ensure you didn’t miss anything.

Pacman is best for major upgrades - then follow with yay if you like, or topgrade to make sure nothing gets missed. I’m not sure I’d recommend topgrade as the first line of attack though - as I’ve been reminded, pacman is the big player here - the rest are not official tools.

So far so good - I guess I’ll keep on doing it this way until I run into issues.

And I’ll stay with yay, since I don’t use flatpaks or snaps.

Hi,

I am a noob but I would highly recommend to setup the preinstalled Timeshift app for an β€œon demand” full system backup with the Rsync option and enabling the β€œinclude home folder and hidden items” too so that you have a full system backup that you can restore in minutes. Without adding the hidden files in home folder your restore will be partial (no custom configuration/settings etc)!

1 Like

Personally me, as a fresh ex Win10 user this is what I wanna use, the β€œUPDATE ALL” button in the App Store app (Pamac), based on the β€œupdates available” system try notification :wink:

Shall I dare to click on it after a full Timeshift backup or better to wait a few days until pros test it a bit? 210 updates are available now it says, 750MB… I am scared to death! :sweat_smile:

Pacman -Syu and yay -Syu

Yes, it is good practice to run timeshift before altering your system.

1 Like