I am new to PHP frameworks having only ever created simple apps from scratch using my non-conformed and somewhat hectic standards. I read up about oven.php and am keen to see what it is made of. Show Whilst installing it I had a few issues that I have solved however, there is a warning I can’t get rid of. It is not fatal from what I can see but I am keen to make good. If you’re expecting big file uploads, some considerations have to be taken into account. Setups based on your needs can be configured. General Considerations
The space temporarily consumed in the upload directory will not count against the user quota. If a user has no quota left in his peronal storage and the quota excludes external mounts, uploads to a windows network drive share as example will succeed. The file temporarily created in the upload directory will not count against his personal storage.
Configuration via .htaccess/user.iniownCloud comes with its own 7 file. When using 8, PHP settings in PrivateTmp=false3 are not accessed. These settings must then be set in the PrivateTmp=false4 file. 8 will read settings from any .user.ini file in the same directory as the .php file that is being served via a web server.Set the following parameters inside the corresponding file using your own desired values, as in the following examples, both files are located in the ownCloud root folder: .user.ini
.htaccess
If you see PHP timeouts in your log files, increase the timeout values, which are in seconds, as in the example below. Use the 2 prefix like above when configuring the PrivateTmp=false3 file:
Consider that any settings made in PrivateTmp=false3 or PrivateTmp=false4 may need to be repopulated after an upgrade of ownCloud. Configuring via PHP Global SettingsIf you don’t want to use the ownCloud PrivateTmp=false3 or PrivateTmp=false4 file, you may configure PHP globally instead. Make sure to comment out or remove any lines in PrivateTmp=false3 if you added any like in the section above. If you are running ownCloud on a 32-bit system, any 9 directive in your PrivateTmp=false5 file needs to be commented out. See the Loaded Configuration File section of to find your relevant php.ini files. Set the following parameters inside the corresponding php.ini file using your own desired file size values, as in the following example:
If you see PHP timeouts in your log files, increase the timeout values, which are in seconds, as in the example below:
Configuring via a Virtual HostYou can configure php parameters also per virtual host - if you have access to the Apache configuration file. This eliminates the need to maintain custom settings in a PrivateTmp=false4 or PrivateTmp=false3 file especially on upgrades. Note the mandatory prefix 3 before the php parameter.
If you see PHP timeouts in your log files, increase the timeout values, which are in seconds, as in the example below:
Configuring via ownCloudAs an alternative to the PrivateTmp=false7 of PHP (e.g., if you don’t have access to your PrivateTmp=false5) you can also configure some parameters in 6.
General Upload IssuesVarious environmental factors could cause a restriction of the upload size. Examples are:
Apache DirectivesApache with mod_reqtimeoutThe mod_reqtimeout Apache module could also stop large uploads from completing. If you’re using this module and uploads of large files fail, either disable it in your Apache config or increase the configured 5 values.Disable mod_reqtimeout on Ubuntu On Ubuntu, you can disable the module by running the following command: PrivateTmp=false0Disable mod_reqtimeout on CentOS On CentOS, comment out the following line in 6:PrivateTmp=false1 When you have run 7 or updated 6, restart Apache.There are also several other configuration options in your web server config which could prevent the upload of larger files. Refer to your web server’s manual for how to configure those values correctly: Apache with mod_fcgidIf you are using Apache 2.4 with mod_fcgid, as of February/March 2016, 9 still needs to be significantly increased from its default value to avoid the occurrence of segmentation faults when uploading big files. This is not a regular setting but serves as a workaround for Apache with mod_fcgid bug #51747.Setting 9 significantly higher than usual may no longer be necessary, once bug #51747 is fixed.Long-Running UploadsFor very long-running uploads those lasting longer than 1h to public folders, when chunking is not in effect, 1 should be set to a significantly large value in 6. If not, large file uploads will fail with a file locking error, because the Redis garbage collection will delete the initially acquired file lock after 1 hour by default.To estimate a good value, use the following formula: PrivateTmp=false2 For the value of "slowest assumed upload connection", take the upload speed of the user with the slowest connection and divide it by two. For example, let’s assume that the user with the slowest connection has an 8MBit/s DSL connection; which usually indicates the download speed. This type of connection would, usually, have 1MBit/s upload speed (but confirm with the ISP). Divide this value in half, to have a buffer when there is network congestion, to arrive at 512KBit/s as the final value. |