Upgrading from 3.0.4 to 3.2.0

I tried doing the automatic update, but it failed (mySQL server has gone away).

I can easily do the manual update, but will i have to do anything to the database?

As explained here, you’ll only need to backup your config and maybe reinstall custom plugins:

https://piwik.org/docs/update/#the-manual-three-step-update