{"id":379,"date":"2020-12-18T11:58:27","date_gmt":"2020-12-18T14:58:27","guid":{"rendered":"http:\/\/xaxowareti.com.br\/?p=379"},"modified":"2020-12-18T11:58:29","modified_gmt":"2020-12-18T14:58:29","slug":"how-to-upgrade-debian-9-stretch-to-linux-debian-10-buster","status":"publish","type":"post","link":"https:\/\/xaxowareti.com.br\/?p=379","title":{"rendered":"How To Upgrade Debian 9 Stretch To Linux Debian 10 Buster"},"content":{"rendered":"\n<p>Introduction<\/p>\n\n\n\n<p><strong>Debian<\/strong>&nbsp;is a popular version, or fork, of the Linux operating system.<\/p>\n\n\n\n<p>The most recently released version is Debian 10, codenamed&nbsp;<strong>Buster.<\/strong>&nbsp;The previous version Debian 9 Stretch is officially supported until June 2022. The newer version offers a longer support period and new features, so it is highly recommended to upgrade if running Debian 9.<\/p>\n\n\n\n<p>This tutorial will walk you through&nbsp;<strong>how to upgrade from Debian 9 (Stretch) to Debian 10 (Buster)<\/strong>.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/phoenixnap.com\/kb\/wp-content\/uploads\/2019\/03\/how-to-upgrade-debian-strech-to-debian-buster.png\" alt=\"how to upgrade debian strech to debian buster\" class=\"wp-image-80295\"\/><\/figure><\/div>\n\n\n\n<p>Prerequisites<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>A system running Debian 9<\/li><li>A Debian user account with&nbsp;<strong>sudo<\/strong>&nbsp;privileges<\/li><li>Access to a command line\/terminal window (<strong>Ctrl<\/strong>\u2013<strong>Alt<\/strong>\u2013<strong>F2<\/strong>)<\/li><li>A recent snapshot (backup) of the system<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Upgrade to Debian Version 10 Buster<\/h2>\n\n\n\n<p>Make sure to<a href=\"https:\/\/phoenixnap.com\/kb\/rsync-back-up-data\" target=\"_blank\" rel=\"noreferrer noopener\">&nbsp;back up your system and data<\/a>&nbsp;prior to upgrading. That way, if anything breaks during the upgrade, you can easily restore your system configuration.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 1: Update Package Manager and Repositories<\/h3>\n\n\n\n<p>By default, Debian 9 refers to the repositories designated for Stretch.<\/p>\n\n\n\n<p>1. First, create a backup copy of the&nbsp;<strong>\/etc\/apt\/sources.list<\/strong>&nbsp;file:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo cp \/etc\/apt\/sources.list \/etc\/apt\/sources.list.bak<\/code><\/pre>\n\n\n\n<p>2. Then, open the file for editing (we are using&nbsp;<a href=\"https:\/\/phoenixnap.com\/kb\/use-nano-text-editor-commands-linux\" target=\"_blank\" rel=\"noreferrer noopener\">GNU nano<\/a>&nbsp;for text editing):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo nano \/etc\/apt\/sources.list<\/code><\/pre>\n\n\n\n<p>3. Change all the references in this file from&nbsp;<strong>Stretch<\/strong>&nbsp;to&nbsp;<strong>Buster<\/strong>. The entries should appear as follows:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>deb http:\/\/deb.debian.org\/debian debian buster main\n\ndeb http:\/\/deb.debian.org\/debian buster-updates main\n\ndeb http:\/\/deb.debian.org\/debian buster\/updates main<\/code><\/pre>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/phoenixnap.com\/kb\/wp-content\/uploads\/2019\/03\/Debian-Version-10-Buster.png\" alt=\"Debian Version 10 Buster successful install\" class=\"wp-image-76133\"\/><\/figure><\/div>\n\n\n\n<p>4.&nbsp;<strong>Save<\/strong>&nbsp;the file using the keyboard combination&nbsp;<strong>Ctrl<\/strong>+<strong>O&nbsp;<\/strong>and&nbsp;<strong>Exit<\/strong>&nbsp;by pressing&nbsp;<strong>Ctrl<\/strong>+<strong>X<\/strong>.<\/p>\n\n\n\n<p>You can also check for&nbsp;<a href=\"https:\/\/www.debian.org\/mirror\/list\" target=\"_blank\" rel=\"noreferrer noopener\">FTP download mirrors<\/a>&nbsp;to replace the web address .<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 2: Upgrade from Debian 9 to Debian 10<\/h3>\n\n\n\n<p>1. Update the local package lists:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt-get update<\/code><\/pre>\n\n\n\n<p>2. Next, run updates on the software packages to prepare for the operating system upgrade:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt-get upgrade<\/code><\/pre>\n\n\n\n<p>3. Finally, run the distribution upgrade:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt-get dist-upgrade<\/code><\/pre>\n\n\n\n<p>4. Once the process completes, reboot the system to boot into Debian 10 Buster:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo reboot<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Step 3: Verify Debian 10 Update<\/h3>\n\n\n\n<p>You can use the&nbsp;<code><strong>hostnamectl<\/strong><\/code>&nbsp;command to display the OS version with the command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>hostnamectl<\/code><\/pre>\n\n\n\n<p>The&nbsp;<strong>Operating System<\/strong>&nbsp;field should display&nbsp;<strong>Debian GNU\/Linux 10 (buster)<\/strong>.<\/p>\n\n\n\n<p><strong>The output should appear as:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>PRETTY_NAME=\"Debian GNU\/Linux 10 (buster)\"\nNAME=\"Debian GNU\/Linux\"\nVERSION_ID=\"10\"\nVERSION=\"10 (buster)\"\nID=debian\nHOME_URL=\"https:\/\/www.debian.org\/\"\nSUPPORT_URL=\"https:\/\/www.debian.org\/support\"\nBUG_REPORT_URL=\"https:\/\/bugs.debian.org\/\"<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">(Optional) Step 4: Remove Outdated Packages<\/h3>\n\n\n\n<p>After the upgrade to Debian 10, your system might have outdated packages and dependencies which are no longer necessary.<\/p>\n\n\n\n<p>To remove outdated packages, run the&nbsp;<strong><code>--purge autoremove<\/code><\/strong>&nbsp;command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>sudo apt --purge autoremove<\/code><\/pre>\n\n\n\n<p>Conclusion<\/p>\n\n\n\n<p>By following the directions above, you should have successfully&nbsp;<strong>upgraded from Debian 9 to Debian 10.<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Introduction Debian&nbsp;is a popular version, or fork, of the Linux operating system. The most recently released version is Debian 10, codenamed&nbsp;Buster.&nbsp;The previous version Debian 9 Stretch is officially supported until June 2022. The newer version offers a longer support period and new features, so it is highly recommended to upgrade if running Debian 9. This [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-379","post","type-post","status-publish","format-standard","hentry","category-sem-categoria"],"_links":{"self":[{"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=\/wp\/v2\/posts\/379","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=379"}],"version-history":[{"count":1,"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=\/wp\/v2\/posts\/379\/revisions"}],"predecessor-version":[{"id":380,"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=\/wp\/v2\/posts\/379\/revisions\/380"}],"wp:attachment":[{"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=379"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=379"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xaxowareti.com.br\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=379"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}