{"id":2172,"date":"2025-02-23T16:49:36","date_gmt":"2025-02-23T16:49:36","guid":{"rendered":"https:\/\/technetsolutions.net\/?p=2172"},"modified":"2025-02-23T16:49:37","modified_gmt":"2025-02-23T16:49:37","slug":"how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli","status":"publish","type":"post","link":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/","title":{"rendered":"How to upgrade Debian 9 to Debian 10 Buster using the CLI"},"content":{"rendered":"\n<p>Prerequisites<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>A system running Debian 9<\/li>\n\n\n\n<li>A Debian user account with <strong>sudo<\/strong> privileges<\/li>\n\n\n\n<li>Access to a command line\/terminal window (<strong>Ctrl<\/strong>\u2013<strong>Alt<\/strong>\u2013<strong>F2<\/strong>)<\/li>\n\n\n\n<li>A recent snapshot (backup) of the system<\/li>\n<\/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 bakup of Server data 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 <strong>\/etc\/apt\/sources.list<\/strong> 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 <\/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 <strong>Stretch<\/strong> to <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<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/phoenixnap.com\/kb\/wp-content\/uploads\/2021\/04\/Debian-Version-10-Buster.png\" alt=\"Debian Version 10 Buster successful install\" class=\"wp-image-76133\"\/><\/figure>\n\n\n\n<p>4. <strong>Save<\/strong> the file using the keyboard combination <strong>Ctrl<\/strong>+<strong>O <\/strong>and <strong>Exit<\/strong> by pressing <strong>Ctrl<\/strong>+<strong>X<\/strong>.<\/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 <strong><code>hostnamectl<\/code><\/strong> 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 <strong>Operating System<\/strong> field should display <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 <strong><code>--purge autoremove<\/code><\/strong> 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 <strong>upgraded from Debian 9 to Debian 10.<\/strong><\/p>\n\n\n\n<p>For more information about the upgrade process, including notes and extensive documentation, please refer to the <a href=\"https:\/\/www.debian.org\/releases\/stable\/\" target=\"_blank\" rel=\"noreferrer noopener\">Debian release notes<\/a>.<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Prerequisites Upgrade to Debian Version 10 Buster Make sure to bakup of Server data prior to upgrading. That way, if anything breaks during the upgrade, you can easily restore your system configuration. Step 1: Update Package Manager and Repositories By default, Debian 9 refers to the repositories designated for Stretch. 1. First, create a backup [&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-2172","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v21.0 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to upgrade Debian 9 to Debian 10 Buster using the CLI - technetsolutions.net<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to upgrade Debian 9 to Debian 10 Buster using the CLI - technetsolutions.net\" \/>\n<meta property=\"og:description\" content=\"Prerequisites Upgrade to Debian Version 10 Buster Make sure to bakup of Server data prior to upgrading. That way, if anything breaks during the upgrade, you can easily restore your system configuration. Step 1: Update Package Manager and Repositories By default, Debian 9 refers to the repositories designated for Stretch. 1. First, create a backup [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/\" \/>\n<meta property=\"og:site_name\" content=\"technetsolutions.net\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/TechnetSolutions.net\" \/>\n<meta property=\"article:published_time\" content=\"2025-02-23T16:49:36+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-02-23T16:49:37+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/phoenixnap.com\/kb\/wp-content\/uploads\/2021\/04\/Debian-Version-10-Buster.png\" \/>\n<meta name=\"author\" content=\"technetsolution\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"technetsolution\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/\",\"url\":\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/\",\"name\":\"How to upgrade Debian 9 to Debian 10 Buster using the CLI - technetsolutions.net\",\"isPartOf\":{\"@id\":\"https:\/\/technetsolutions.net\/#website\"},\"datePublished\":\"2025-02-23T16:49:36+00:00\",\"dateModified\":\"2025-02-23T16:49:37+00:00\",\"author\":{\"@id\":\"https:\/\/technetsolutions.net\/#\/schema\/person\/33a2eaab7eef8be9022fc9a4c37c2136\"},\"breadcrumb\":{\"@id\":\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/technetsolutions.net\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to upgrade Debian 9 to Debian 10 Buster using the CLI\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/technetsolutions.net\/#website\",\"url\":\"https:\/\/technetsolutions.net\/\",\"name\":\"technetsolutions.net\",\"description\":\"technetsolutions.net\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/technetsolutions.net\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/technetsolutions.net\/#\/schema\/person\/33a2eaab7eef8be9022fc9a4c37c2136\",\"name\":\"technetsolution\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/technetsolutions.net\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/b3e06688ecbbb11dfcb794106978d4a0?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/b3e06688ecbbb11dfcb794106978d4a0?s=96&d=mm&r=g\",\"caption\":\"technetsolution\"},\"url\":\"https:\/\/technetsolutions.net\/index.php\/author\/admin\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to upgrade Debian 9 to Debian 10 Buster using the CLI - technetsolutions.net","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/","og_locale":"en_US","og_type":"article","og_title":"How to upgrade Debian 9 to Debian 10 Buster using the CLI - technetsolutions.net","og_description":"Prerequisites Upgrade to Debian Version 10 Buster Make sure to bakup of Server data prior to upgrading. That way, if anything breaks during the upgrade, you can easily restore your system configuration. Step 1: Update Package Manager and Repositories By default, Debian 9 refers to the repositories designated for Stretch. 1. First, create a backup [&hellip;]","og_url":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/","og_site_name":"technetsolutions.net","article_publisher":"https:\/\/www.facebook.com\/TechnetSolutions.net","article_published_time":"2025-02-23T16:49:36+00:00","article_modified_time":"2025-02-23T16:49:37+00:00","og_image":[{"url":"https:\/\/phoenixnap.com\/kb\/wp-content\/uploads\/2021\/04\/Debian-Version-10-Buster.png"}],"author":"technetsolution","twitter_card":"summary_large_image","twitter_misc":{"Written by":"technetsolution","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/","url":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/","name":"How to upgrade Debian 9 to Debian 10 Buster using the CLI - technetsolutions.net","isPartOf":{"@id":"https:\/\/technetsolutions.net\/#website"},"datePublished":"2025-02-23T16:49:36+00:00","dateModified":"2025-02-23T16:49:37+00:00","author":{"@id":"https:\/\/technetsolutions.net\/#\/schema\/person\/33a2eaab7eef8be9022fc9a4c37c2136"},"breadcrumb":{"@id":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/technetsolutions.net\/index.php\/2025\/02\/23\/how-to-upgrade-debian-9-to-debian-10-buster-using-the-cli\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/technetsolutions.net\/"},{"@type":"ListItem","position":2,"name":"How to upgrade Debian 9 to Debian 10 Buster using the CLI"}]},{"@type":"WebSite","@id":"https:\/\/technetsolutions.net\/#website","url":"https:\/\/technetsolutions.net\/","name":"technetsolutions.net","description":"technetsolutions.net","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/technetsolutions.net\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/technetsolutions.net\/#\/schema\/person\/33a2eaab7eef8be9022fc9a4c37c2136","name":"technetsolution","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/technetsolutions.net\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/b3e06688ecbbb11dfcb794106978d4a0?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/b3e06688ecbbb11dfcb794106978d4a0?s=96&d=mm&r=g","caption":"technetsolution"},"url":"https:\/\/technetsolutions.net\/index.php\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/posts\/2172","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/comments?post=2172"}],"version-history":[{"count":2,"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/posts\/2172\/revisions"}],"predecessor-version":[{"id":2174,"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/posts\/2172\/revisions\/2174"}],"wp:attachment":[{"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/media?parent=2172"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/categories?post=2172"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/technetsolutions.net\/index.php\/wp-json\/wp\/v2\/tags?post=2172"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}