Upgrade Debian 6 squeeze to Debian 7 wheezy

This is a simple procedure how to upgrade Debian 6 squeeze to Debian 7 wheezy. This is aimed to systems that doesn’t have any custom manual tweaks or installed software that it’s not from the package manager.

First thing you need to do is make backup of your /etc directory. The upgrade process will NOT modify anything in your /home directory. Also for this upgrade apt-get is the preferred method not aptitude.

For those who want more detailed procedure you can read the official upgrade procedure from here.

Update Debian squeeze

Get the latest updates for Debian squeeze:

apt-get update
apt-get upgrade
apt-get dist-upgrade

Upgrade to Debian wheezy

Change the source list file to the new Debian version and make the upgrade

sed -i 's/squeeze/wheezt/' /etc/apt/sources.list
apt-get update
apt-get dist-upgrade -d
apt-get upgrade
apt-get dist-upgrade

Now you can reboot into your Debian wheezy system


Check your Debian version

lsb_release -a

You should get this output

No LSB modules are available.
Distributor ID:	Debian
Description:	Debian GNU/Linux 7.0 (wheezy)
Release:	7.0
Codename:	wheezy

That is it, now you have your system upgraded from Debian squeeze to Debian wheezy

Debian Website: http://www.debian.org/

Notify of
1 Comment
Newest Most Voted
Inline Feedbacks
View all comments
10 years ago

thanks, great blog

shouldn’t the ‘wheetz’ in “sed -i ‘s/squeeze/wheezt/’ /etc/apt/sources.list” be a wheezy though?

Also you say one should backup the /etc folder. I assume you need to restore this backup after the upgrade, otherwise it wouldn’t help too much, right?