(Nextcloud 21.x & nginx) 404: Not Found

After uprading NC from 20.x to 21.x I got following messages in settings/admin/overview:

Your web server is not properly set up to resolve “/.well-known/webfinger”. Further information can be found in the documentation.

Your web server is not properly set up to resolve “/.well-known/nodeinfo”. Further information can be found in the documentation.

“Documentation” pointed to the latest server admin manual. I checked it and found the nginx server configuration changed since the time when I installed NC (at that time NC 19.x).

So I created new nginx configuration using admin manual for NC 21 version. But now whenever I try to log in using web interface, all I see is:

404: Not found

I have put back the old NC19-config, and NC starts (albeit with those two warning messages). But when I try to start NC-server with NC21-config, I always get “404: Not found”. So where is the problem?

For comparison, here is nginx-configuration for Nextcloud 19.x and 21.x:

https://docs.nextcloud.com/server/19/admin_manual/installation/nginx.html
https://docs.nextcloud.com/server/21/admin_manual/installation/nginx.html

Did you adapt the root-directive in your nginx-configuration for Nextcloud 19 (which you then also need to do for the other configuration)?

root /var/www/nextcloud;

Yes, I did. Actually, the only four config settings I modified are
server_name
ssl_certificate
ssl_certificate_key
root

When I try “nginx -t”, it does not report any problems…

The configurations from the documentation you posted above are working in the installations I administrate.

Without seeing at least a diff of the configurations you use for Nextcloud 19 and Nextcloud 21 it is not possible to help any further. Best would be, you posted both.