Although Dovecot 1.2.15 is the latest Dovecot version in Debian Squeeze stable repository, you can upgrade it safely to 2.1 through backports.

Following the next steps you’ll be able to upgrade Dovecot to 2.1 in 2 minutes:

-Add the backports repository in /etc/apt/sources.list and comment the other repositories:

-Upgrade Dovecot through apt-get install (all the packages depending on it will be also upgraded) keeping the existing dovecot.conf file

You’ll see some warnings because of the old 1.2 dovecot.conf

-Convert dovecot.conf file to dovecot 2.1 format:

-Restart dovecot

Finally, check if everything is ok in dovecot.log and dovecot-info.log (it should be :))