It turns out that with the new version Apache needs different configuration:
In the site configuration in /etc/apache2/sites-available/{mysite}.conf I added:
<FilesMatch \.php$>
SetHandler fcgid-script
</FilesMatch>
And commented out this:
#AddHandler fcgid-script .php
#AddHandler fcgid-script .php5
The same thing in /etc/apache2/mods-available/fcgid.conf