---
title: "Upgrade Debian Lenny to Squeeze"
date: "2012-03-28"
modified: "2013-03-04"
path: "/79-upgrade-debian-lenny-to-squeeze.html"
section: "/ramblings"
aliases:
  - "/79"
  - "/79-upgrade-debian-lenny-to-squeeze"
  - "/79.html"
  - "/ramblings/79-upgrade-debian-lenny-to-squeeze.html"
---

You need to first edit the sources used for the apt repo's:

```
nano /etc/apt/sources.list
```

Now replace existing (or comment out the existing just in case):

```
deb http://mirror.bytemark.co.uk/debian/ squeeze main non-free contrib
deb-src http://mirror.bytemark.co.uk/debian/ squeeze main non-free contrib
 
deb http://mirror.bytemark.co.uk/debian/ squeeze-updates main contrib non-free
deb-src http://mirror.bytemark.co.uk/debian/ squeeze-updates main contrib non-free
 
#deb http://software.virtualmin.com/gpl/debian/ virtualmin-squeeze main
#deb http://software.virtualmin.com/gpl/debian/ virtualmin-universal main
 
#deb http://packages.dotdeb.org stable all
#deb-src http://packages.dotdeb.org stable all
```

Now update the distribution:

```
sudo apt-get update
sudo apt-get install apt dpkg
sudo apt-get dist-upgrade
```

You should restart the server to make sure all is ok - pot luck my friends:

```
shutdown -r now
```

Reboot – hopefully all ok!
