{"id":485,"date":"2012-04-26T09:21:06","date_gmt":"2012-04-26T13:21:06","guid":{"rendered":"http:\/\/blog.alanporter.com\/?p=485"},"modified":"2012-04-26T09:21:06","modified_gmt":"2012-04-26T13:21:06","slug":"dist-upgrade","status":"publish","type":"post","link":"https:\/\/alanporter.com\/blog\/2012\/04\/26\/dist-upgrade\/","title":{"rendered":"Debian&#8217;s &#8220;dist-upgrade&#8221;"},"content":{"rendered":"<p>There seems to be a common misconception about Debian&#8217;s package manager &#8220;apt&#8221;, that the command &#8220;dist-upgrade&#8221; is used to upgrade to a new release. It is, but it isn&#8217;t. I wanted to clarify that here.<\/p>\n<p>Basically, there are 4 things that you might want to do as part of upgrading a system.<\/p>\n<ul>\n<li><code>apt-get update<\/code> &#8211; updates the list of available packages and versions<\/li>\n<li><code>apt-get upgrade<\/code> &#8211; upgrade packages that you already have<\/li>\n<li><code>apt-get dist-upgrade<\/code> &#8211; upgrade packages that you already have, PLUS install any new dependencies that have come up<\/li>\n<li>edit the sources files &#8211; change the release that you are tracking<\/li>\n<\/ul>\n<p>That means that to freshen up your packages to the latest versions on your current release, you should do &#8220;<code>apt-get update &amp;&amp; apt-get dist-upgrade<\/code>&#8220;. On some systems that track &#8220;testing&#8221;, which changes often, I do this almost daily.<\/p>\n<p>When you&#8217;re ready to &#8220;really upgrade&#8221; to a new release, you edit your sources files in <strong>\/etc\/apt\/sources<\/strong> and change the release names. If the source lists contain proper release names, like &#8220;etch&#8221;, &#8220;lenny&#8221;, &#8220;squeeze&#8221; or &#8220;wheezy&#8221;; then you change these names to the new release that you want (see <a href=\"http:\/\/www.debian.org\/releases\/\">http:\/\/www.debian.org\/releases\/<\/a>). If the source lists contain symbolic names like &#8220;stable&#8221;, &#8220;testing&#8221; and &#8220;unstable&#8221;, you do not need to change anything. When a new release is ready, the Debian people will change the symbols to point to the new release names. For example, right now, stable=squeeze and testing=wheezy.<\/p>\n<p style=\"padding-left: 30px;\">Note 1 &#8211; &#8220;unstable&#8221; never points to a named release&#8230; it&#8217;s the pre-release proving ground for packages, used before are ready for inclusion in the testing release.<\/p>\n<p style=\"padding-left: 30px;\">Note 2 &#8211; Don&#8217;t let these symbolic names fool you:<\/p>\n<ul style=\"padding-left: 30px;\">\n<li>&#8220;Stable&#8221; means &#8220;old, tried, tested, and rock solid&#8221;.\u00a0 It&#8217;s a very conservative choice.<\/li>\n<li>&#8220;Testing&#8221; does not mean &#8220;chaotic&#8221;. It is roughly the equivalent of Red Hat&#8217;s Fedora. It&#8217;s new stuff, and each package changes on its own schedule, but they usually play well together.<\/li>\n<li>&#8220;Unstable&#8221; is not nearly as unstable as the name implies. It&#8217;s like a beta release that may be updated daily.<\/li>\n<\/ul>\n<p>After your source lists look OK, you do the same thing you&#8217;ve always done: &#8220;<code>apt-get update &amp;&amp; apt-get dist-upgrade<\/code>&#8220;&#8221;<code>apt-get update &amp;&amp; apt-get dist-upgrade<\/code>&#8220;.<\/p>\n<p>If you&#8217;re running Ubuntu, the release names are at <a href=\"http:\/\/releases.ubuntu.com\/\">http:\/\/releases.ubuntu.com\/<\/a>. And they&#8217;ve made a nice wrapper script called &#8220;do-release-upgrade&#8221; that basically edits your source lists and does the dist-upgrade for you (it also does some other nice steps, like letting you review the changes).<\/p>\n<p>So there it is&#8230; fear not the &#8220;dist-upgrade&#8221;. In fact, most of the time, it is what you&#8217;ll want to run. It will make sure that you have all of the dependencies that you need.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>There seems to be a common misconception about Debian&#8217;s package manager &#8220;apt&#8221;, that the command &#8220;dist-upgrade&#8221; is used to upgrade to a new release. It is, but it isn&#8217;t. I wanted to clarify that here. Basically, there are 4 things that you might want to do as part of upgrading a system. apt-get update &#8211; [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,15],"tags":[],"class_list":["post-485","post","type-post","status-publish","format-standard","hentry","category-software","category-tips-tricks","count-0","even alt","author-alan","last"],"_links":{"self":[{"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/posts\/485","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/comments?post=485"}],"version-history":[{"count":0,"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/posts\/485\/revisions"}],"wp:attachment":[{"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/media?parent=485"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/categories?post=485"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/alanporter.com\/blog\/wp-json\/wp\/v2\/tags?post=485"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}