{"id":38306,"date":"2022-04-01T16:38:14","date_gmt":"2022-04-01T16:38:14","guid":{"rendered":"https:\/\/ubuntuhandbook.org\/?p=38306"},"modified":"2022-04-01T16:38:14","modified_gmt":"2022-04-01T16:38:14","slug":"upgrade-ubuntu-20-04-to-ubuntu-22-04-lts","status":"publish","type":"post","link":"https:\/\/ubuntuhandbook.org\/index.php\/2022\/04\/upgrade-ubuntu-20-04-to-ubuntu-22-04-lts\/","title":{"rendered":"How to Upgrade From Ubuntu 20.04 to Ubuntu 22.04 LTS (Step-by-Step Guide)"},"content":{"rendered":"<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo.webp\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo-250x250.webp\" alt=\"\" width=\"250\" height=\"250\" class=\"alignleft size-thumbnail wp-image-38307\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo-250x250.webp 250w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo-300x300.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo-600x600.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo-768x768.webp 768w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/ubuntu2204-logo.webp 1200w\" sizes=\"auto, (max-width: 250px) 100vw, 250px\" \/><\/a><\/p>\n<p>Ubuntu 22.04 Jammy Jellyfish now is in final beta stage! Here&#8217;s how you can upgrade to the new LTS from Ubuntu 20.04!<\/p>\n<p><b>NOTE: the steps below now will upgrade to Ubuntu 22.04 Beta at the moment. Though, the beta will be upgraded to the final stable release automatically in next month by running regular updates.<\/b><\/p>\n<h3>What&#8217;s New in Ubuntu 22.04:<\/h3>\n<p>The new Ubuntu 22.04 LTS features <b>Linux Kernel 5.15<\/b> and <b>GNOME 42<\/b> desktop. It&#8217;s a long term support release with 5 years support. The <a href=\"https:\/\/lists.ubuntu.com\/archives\/ubuntu-announce\/2022-March\/000278.html\" rel=\"noopener\" target=\"_blank\">Final Beta<\/a> was announced with changes including:<\/p>\n<ul>\n<li>Full dark\/light mode via appearance settings.<\/li>\n<li>10 accent colors.<\/li>\n<li>New screenshot UI (press Print-Screen to start it).<\/li>\n<li>Switch Firefox to Mozilla&#8217;s Snap package.<\/li>\n<li>Defaults to Wayland compare to Ubuntu 20.04.<\/li>\n<li>LibreOffice 7.3, Thunderbird 91.<\/li>\n<li>Python 3.10, Ruby 3.0, Mesa 22, PulseAudio 16, CUPS 2.4, PostgreSQL 14.2<\/li>\n<li>See <a href=\"https:\/\/discourse.ubuntu.com\/t\/jammy-jellyfish-release-notes\/24668\" rel=\"noopener\" target=\"_blank\">release note<\/a> for more.<\/li>\n<\/ul>\n<h3>Preparation:<\/h3>\n<p>Before getting started, there are some things need to do first! They are important to prevent upgrade failure.<\/p>\n<p>1.) <b>Backup! Backup! Backup!<\/b> The upgrade process may fail due to different reasons. So, it&#8217;s important to back your data, bookmarks, etc.<\/p>\n<p>2.)  <b>Disable third-party PPAs<\/b>. This can be done by launching &#8216;Software &#038; Updates&#8217; utility and navigate to &#8216;Other Software&#8217; tab.<\/p>\n<p><i>If possible, I&#8217;d recommend to purge PPAs which also downgrade these third-party software packages. Especially for ffmpeg, mesa, etc.<\/i><\/p>\n<div id=\"attachment_38308\" style=\"width: 610px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-3party-ppas.webp\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38308\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-3party-ppas-600x294.webp\" alt=\"\" width=\"600\" height=\"294\" class=\"size-large wp-image-38308\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-3party-ppas-600x294.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-3party-ppas-300x147.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-3party-ppas-768x377.webp 768w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-3party-ppas.webp 1026w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/a><p id=\"caption-attachment-38308\" class=\"wp-caption-text\">Disable or remove 3 party PPAs<\/p><\/div>\n<p>3.) Also in &#8216;Software &#038; Updates&#8217; tool, navigate to &#8216;Updates&#8217; tab. There choose &#8216;Notify me of a new Ubuntu version: <b>For long term support versions<\/b>&#8216;.<\/p>\n<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-lts.webp\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-lts-600x294.webp\" alt=\"\" width=\"600\" height=\"294\" class=\"aligncenter size-large wp-image-38309\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-lts-600x294.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-lts-300x147.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-lts-768x377.webp 768w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-lts.webp 1026w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/a><\/p>\n<p>4.) <b>Remove proprietary drivers<\/b> from &#8216;Additional Drivers&#8217; tab, and use an open-source driver instead. You may skip this step if your PC does not have a dedicated GPU.<\/p>\n<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-propdrivers.webp\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-propdrivers-600x294.webp\" alt=\"\" width=\"600\" height=\"294\" class=\"aligncenter size-large wp-image-38311\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-propdrivers-600x294.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-propdrivers-300x147.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-propdrivers-768x377.webp 768w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/remove-propdrivers.webp 1026w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/a><\/p>\n<p>5.) <b>Remove other Desktop Environments!<\/b> If you have other desktops (e.g., KDE, XFCE, Cinnamon), it&#8217;s better to remove them, so to speed up the upgrade process.<\/p>\n<p>6.) <b>Disable User Extensions<\/b>. Disable user installed Gnome Extensions via Gnome Tweaks tool!<\/p>\n<h3>Upgrade to Ubuntu 22.04:<\/h3>\n<p><b>NOTE: The upgrade process may fail! If you can&#8217;t afford to have a broken system, please do a clean install instead of upgrading it!<\/b><\/p>\n<p>1.) Firstly, press <b>Ctrl+Alt+T<\/b> on keyboard to open terminal. When it opens, run the command below to install all available system updates:<\/p>\n<pre>sudo apt update && sudo apt full-upgrade<\/pre>\n<div id=\"attachment_38312\" style=\"width: 610px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-38312\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/apt-fullupgrade-600x177.webp\" alt=\"\" width=\"600\" height=\"177\" class=\"size-large wp-image-38312\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/apt-fullupgrade-600x177.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/apt-fullupgrade-300x89.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/apt-fullupgrade-768x227.webp 768w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/apt-fullupgrade.webp 800w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><p id=\"caption-attachment-38312\" class=\"wp-caption-text\">install all available system updates<\/p><\/div>\n<p>And, restart your computer if you have not run system updates for a long time.<\/p>\n<p>2.) Next, in terminal run the command below to run update manager to check distribution update:<\/p>\n<pre>update-manager -d -c<\/pre>\n<p>If there are still available updates or removals, click on &#8216;Install Now&#8217; and re-run the command.<\/p>\n<p><a href=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-jammy.webp\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-jammy-600x276.webp\" alt=\"\" width=\"600\" height=\"276\" class=\"aligncenter size-large wp-image-38313\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-jammy-600x276.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-jammy-300x138.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/notify-jammy.webp 747w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/a><\/p>\n<p>3.) Once you see the prompt for Ubuntu 22.04. Click on &#8220;Upgrade&#8221; button, and confirm in the next &#8216;Release Notes&#8217; dialog.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/release-note-600x538.webp\" alt=\"\" width=\"600\" height=\"538\" class=\"aligncenter size-large wp-image-38314\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/release-note-600x538.webp 600w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/release-note-300x269.webp 300w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/release-note.webp 634w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/p>\n<p>4.) It will pop-up another dialog asks to confirm via &#8216;Start Upgrade&#8217; button. Once you click on it, the &#8216;Distribution Upgrade&#8217; wizard will pop-up indicates the upgrading process.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/upgrade-wizard.png\" alt=\"\" width=\"390\" height=\"308\" class=\"aligncenter size-full wp-image-38315\" srcset=\"https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/upgrade-wizard.png 390w, https:\/\/ubuntuhandbook.org\/wp-content\/uploads\/2022\/04\/upgrade-wizard-300x237.png 300w\" sizes=\"auto, (max-width: 390px) 100vw, 390px\" \/><\/p>\n<p>5.) <b>Don&#8217;t go far away from your computer!!<\/b> There will be a few more confirm dialogs, so you have to keep an eye on the screen. <\/p>\n<p>If everything goes well, there will be a dialog asks to &#8220;Restart&#8221; to complete the upgrade.<\/p>\n<p><i>Sadly, I went out when it was &#8216;<u>Getting new packages<\/u>&#8216;. And the upgrade process failed at blank screen when I was back! So there&#8217;s no screenshot for this step.<\/i><\/p>\n<h3>Troubleshoot:<\/h3>\n<p>There may be various reasons that the upgrade failed. Here are the issues in my case.<\/p>\n<p>As mentioned, the upgrade failed in my case and the laptop run into blank screen. And, I did following steps that successfully finish the upgrade.<\/p>\n<p>1.) Force reboot and login. Press <b>Ctrl+Alt+F2 (F3 ~ F6)<\/b> and type username, then password to log into tty console if GDM (login screen) does not start. Or, select boot &#8220;Advanced -> recover mode -> drop root shell prompt&#8221; from boot-loader if Ubuntu refused to boot!<\/p>\n<p>2.) Once logged in, try running command to configure unfinished packages:<\/p>\n<pre>sudo dpkg --configure -a<\/pre>\n<p>3.) And, try to fix broken dependencies via command:<\/p>\n<pre>sudo apt -f install<\/pre>\n<p>In my case, some third-party packages (e.g., libfilezilla12 from xtradeb PPA, and libreoffice-common from LibreOffice Fresh PPA) break the dependencies! And, the command failed with something look like:<\/p>\n<blockquote><p><i>trying to overwrite &#8216;&#8230;&#8217;, which is also in package libfilezilla12 0.27.1~extradeb1<br \/>\nErrors were encountered while processing:<br \/>\n&#8230;<br \/>\nE: Sub-process \/usr\/bin\/dpkg returned an error code(1)<\/i><\/p><\/blockquote>\n<p>To fix the issue, just remove the package via command (replace package name &#8216;libfilezilla12&#8217; accordingly):<\/p>\n<pre>sudo dpkg -P libfilezilla12<\/pre>\n<p>Then re-run the <code>sudo apt -f install<\/code> until it&#8217;s done successfully without error!<\/p>\n<p>4.) Install all available system updates via command:<\/p>\n<pre>sudo apt full-upgrade<\/pre>\n<p>If everything goes well, clean up via command:<\/p>\n<pre>sudo apt remove --autoremove<\/pre>\n<p>And finally restart computer via <code>reboot<\/code> command.<\/p>\n<p>5.) Some packages are however missing in my case after restart. They were fixed by manually installing the packages via the commands below.<\/p>\n<ul>\n<li>No login screen or non-gnome login screen, run command and then reboot:\n<pre>sudo apt install gdm3 && sudo dpkg-reconfigure gdm3<\/pre>\n<\/li>\n<li>Miss pre-installed extensions (left-dock, desktop icons, and appindicator), run command and then log out and back in:\n<pre>sudo apt install gnome-shell-extension-ubuntu-dock gnome-shell-extension-appindicator gnome-shell-extension-desktop-icons-ng<\/pre>\n<\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>Ubuntu 22.04 Jammy Jellyfish now is in final beta stage! Here&#8217;s how you can upgrade to the new LTS from Ubuntu 20.04! NOTE: the steps below now will upgrade to Ubuntu 22.04 Beta at the moment. Though, the beta will be upgraded to the final stable release automatically in next month by running regular updates. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":38307,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[153],"class_list":["post-38306","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-howtos","tag-ubuntu"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/38306","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/comments?post=38306"}],"version-history":[{"count":0,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/posts\/38306\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/media\/38307"}],"wp:attachment":[{"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/media?parent=38306"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/categories?post=38306"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ubuntuhandbook.org\/index.php\/wp-json\/wp\/v2\/tags?post=38306"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}