ownCloud define upload size

Discussion in 'Installation/Configuration' started by Ark74, Dec 12, 2015.

  1. Ark74

    Ark74 Member

    Hi!
    First i wanna say that ISPConfig 3 is a great admin system, first i thought it would be painful to learn and use, but the more i use it the more i like it. :)
    I have follow the Ubuntu 14.04 - Apache Perfect Server to set ISPConfig manual, here my question.

    I was wondering, on a standard ownCloud you can usually set the max size file to upload which is 513MB.
    But on this same forum i read somewhere, that to modify the size of upload files, you need to set the FcgidMaxRequestLen directive on ISPConfig, i've tested it and it's true, i have set it for ~50MB, but ownCloud keeps saying 513MB.

    Do i need to use some specific configuration to be able to display the true allowed size or modify within ownCloud the max file size?

    I'm using
    • Apache 2.4.7
    • PHP 5.5.9
      • SuEXEC
      • Fast-CGI
    Here the directives that i'm using on this owncloud instance,

    PHP open_basedir
    <code>
    ....phpmyadmin:/dev/urandom​
    </code>

    Apache *
    <code>
    FcgidMaxRequestLen 50000000

    RewriteEngine On
    RewriteCond %{HTTPS} off
    RewriteRule (.*) h t t p s://%{HTTP_HOST}%{REQUEST_URI}

    Header always set Strict-Transport-Security "max-age=15768000"​
    </code>
    * Using SSL redirection.
    Note: h t t p s -> https
    Any idea?
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    The setting FcgidMaxRequestLen is a variable of the mod fcgi module, it is not ispconfig specific and it does not define the upload size. This setting exists to prevent that someone can overload your server by sending to huge packages between the web server and the php process. The default from debian can be too small for some cases, that's why it can be useful to set it to a higher value, but that's not the upload size. The max upload size is defined in php.ini, if you are unsure which php.ini file is used, add a php file with phpinnfo() command inside in the website and check the output, it will show you the php.ini that is used by this php process.
     
  3. blackfox123

    blackfox123 Member

    I ran into this recently, i tried setting php.ini files, and ended up scouring through the entire configuration for anything in relation to this problem - surprisingly there are a lot of ways to set/reset this..

    ownCloud has their own config file included at the default installation..
    Try:

    vi ./.user.ini
    upload_max_filesize=50M
    post_max_size=50M

    You can also verify to see if this is really the problem in the phpinfo(); as it states which variable is set as the master and local.
     
  4. Ark74

    Ark74 Member

    ownCloud rewrites php options using .htaccess, and it work fine, i've uploaded 1.7 G files on a home server with another *buntu 14.04 / owncloud installation.

    On the ISPConfig server if i don't set the FcgidMaxRequestLen to the same size that ownCloud indicates (or any size) then i can't upload files larges than 131072 (confirmed on log/error.log).

    So now that i get it, my question really is,

    Is this the desired behavior for security purposes?
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    See

    http://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html#fcgidmaxrequestlen

    Which probably uses mod_php, so you can not compare the setup wth a multi user fcgi or fpm php setup. mod_php is only used on servers that run just a single website as it can not run php under different users.
     
  6. Ark74

    Ark74 Member

    Ohhh!
    That explains it!
    Thank you :D
     

Share This Page