[Solution] “Not enough free space” while using nginx reverse proxy

Hi everyone,

after some time using my selfhosted NextCloud server at home I’ve realized, that I’m unable to upload any file using web browser (Android client had no problems).
After reading lot of articles, discussions, etc…, here is what I found out:

the error is caused by nginx reverse proxy configuration, specially by location entry for FastCGI
if the “location ~ .php$” is set for the whole “server” section, file upload doesn’t work. don’t ask my why, will try to investigate in the future

Solution:
use only nested “location ~ .php$” sections whitin each section where PHP is needed, like in following example:

location /api
        {
        root   /usr/share/nginx/html;
        index  index.php;
        location ~ \.php$ 
            {
            root   /usr/share/nginx/html;
            try_files $uri =404;
            fastcgi_pass   <FastCGI server>:9000;
            fastcgi_index  index.php;
            fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
            include        fastcgi_params;
            }
        }

/BR
ZoloN

1 Like