Hacker News new | ask | show | jobs
by sidkshatriya 45 days ago
> The upgrade mechanism from 7.9 to 8.0 is still gloriously simple, and exactly the same as it has been for many years

The upgrade mechanism on a typical Linux distribution is _even more_ gloriously simple, and exactly the same as it has been for many years.

  # Fedora/RHEL
  $ sudo dnf upgrade -y

  # Debian/Ubuntu
  $ sudo apt update && sudo apt upgrade -y

  # Arch Linux
  $ sudo pacman -Syu

The false distinction between the OS packages and user local (/usr/local) packages during upgrade causes much unneeded complexity. FreeBSD is making this go away which is welcome.
5 comments

    # Debian/Ubuntu
    $ sudo apt update && sudo apt upgrade -y
But this is equivalent to syspatch && pkg_add -u , this does not upgrade the computer from one version of the OS to the next.
For a rolling release like Arch Linux you just always use pacman -Syu.

But yes you are correct, if you want to upgrade a Ubuntu distribution like 26.04 you do need to issue a command like `sudo apt dist-upgrade` which is admittedly an additional command. But then you could run 26.04 for many years. In OpenBSD anytime the base system/kernel is upgraded for a security fix or point release you need to do a slightly more complex dance.

> a command like `sudo apt dist-upgrade`

That is still wrong.

The correct form is `apt-get dist-upgrade` but that's just the command to update all packages to the latest versions in the same release of the OS. It is the equivalent of `apt full-upgrade` if you have the more modern `apt` command rather than `apt-get`.

So, no, that will not upgrade your distro.

The recommended course of action for Debian is to edit the repository config files, change to the new release names, and then do a full update.

It's a big job.

https://www.debian.org/releases/stable/release-notes/upgradi...

Ubuntu wraps this in simpler tools: `do-release-upgrade` from the shell, or Software Updater for GUI users.

I just upgraded my Ubuntu 24.04 box to 26.04, and my OpenBSD 7.9 box to 8.0. OpenBSD is quicker and easier.

I'm pretty sure it takes more to move debian 11 to debian 12 and Arch doesn't even have versions
Arch upgrades are really fun if you don't run pacman for a year or more. It rarely works in your favor to not run pacman on a extremely frequent schedule.
Hey, you'd love this one:

  guix pull && guix system reconfigure
To undo, it's:

  guix roll-back
(now, where is guix-bsd?..)

https://guix.gnu.org/manual/1.5.0/en/html_node/Upgrading-Gui...

And don't forget to cross your fingers so the upgrade does not break your system... like what happened to me when systemd came out.
A typical Debian upgrade process is more involved than that.