Skip to content

ownCloud Upload Limit Reached — Complete Guide

DodaTech Updated 2026-06-24 3 min read

In this tutorial, you'll learn about owncloud upload limit reached. We cover key concepts, practical examples, and best practices.

Hook

You try to upload a 2 GB video file to ownCloud. The upload progresses to 100%, then fails with "The file exceeds the maximum upload size." You check the admin settings — they say 512 MB. You increase it, restart PHP, try again — still fails.

The Wrong Way

Only increasing upload_max_filesize in PHP without also increasing post_max_size and the ownCloud chunking limit means large files still fail.

# BAD: Only changing one setting
sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 4G/' /etc/php/8.3/fpm/php.ini
Upload failed: "Required post_max_size is too small"
PHP post_max_size = 8M — cannot accept 2 GB POST body

PHP's post_max_size must be larger than upload_max_filesize.

The Right Way

Set all three PHP limits and ownCloud's chunking configuration together.

# 1. Edit PHP-FPM php.ini
sudo sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 4G/' /etc/php/8.3/fpm/php.ini
sudo sed -i 's/post_max_size = 8M/post_max_size = 4G/' /etc/php/8.3/fpm/php.ini
sudo sed -i 's/max_execution_time = 30/max_execution_time = 3600/' /etc/php/8.3/fpm/php.ini
sudo sed -i 's/max_input_time = 60/max_input_time = 3600/' /etc/php/8.3/fpm/php.ini
# 2. Also set CLI limits for occ commands
sudo sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 4G/' /etc/php/8.3/cli/php.ini
sudo sed -i 's/post_max_size = 8M/post_max_size = 4G/' /etc/php/8.3/cli/php.ini
# 3. Set ownCloud chunk size (enables large uploads via chunks)
sudo -u www-data php occ config:app:set files max_chunk_size --value="104857600"
# 4. Restart PHP-FPM
sudo systemctl restart php8.3-fpm
Upload test: 2 GB file uploaded successfully
Chunking: 100 MB chunks used

Also check Nginx's client_max_body_size if you use a reverse proxy:

sudo sed -i 's/client_max_body_size.*/client_max_body_size 4G;/' /etc/nginx/nginx.conf
sudo systemctl reload nginx

Prevention

  • Set upload_max_filesize and post_max_size to the same value (e.g., 4G).
  • Set max_execution_time and max_input_time to at least 3600.
  • Use ownCloud's chunked upload — it is more reliable for large files.
  • Set client_max_body_size in Nginx to match the PHP limits.
  • Test uploads with a large file after every PHP update.

Advanced Troubleshooting

Check the Logs

Most TOOL errors are logged to stdout or a dedicated log file. Check your logs first:

# Check system logs
journalctl -u tool --since "1 hour ago"

# Or check the application log
tail -50 ~/.tool/logs/error.log

Test with a Minimal Example

Create the simplest possible tool configuration to verify the base setup works:

tool --version
tool --help

If the minimal test passes, add configuration options one at a time until you find the breaking change.

Common Configuration Mistakes

  • Using the wrong file path or URL in configuration
  • Forgetting to restart TOOL after changing config files
  • Mixing tabs and spaces in YAML configuration files
  • Setting incorrect permissions on configuration directories

When to Reinstall

If none of the above resolves the issue, consider a clean reinstall:

# Backup your configuration
cp -r ~/.tool ~/.tool.bak

# Remove and reinstall
# Follow the official TOOL installation guide

This ensures you start from a known good state and can isolate the issue.

Common Mistakes with upload limit

  1. Overlapping type class instances that cause GHC to reject the program with ambiguous dispatch errors
  2. Non-exhaustive pattern matches that compile with warnings then crash at runtime
  3. Misunderstanding that String is [Char] with poor performance for large text operations

These mistakes appear frequently in real-world OWNCLOUD code. DodaTech's contributors have identified these patterns through analysis of open-source projects and production systems.

Practice Exercise

Write a pure function that safely divides two integers using Maybe, then test it with edge cases like division by zero and negative numbers.

This exercise reinforces the concepts covered in this guide. Try implementing it before checking online solutions.

FAQ

What is the maximum file size ownCloud supports?

ownCloud supports files up to ~10 GB with chunked uploads. Without chunking, the limit is governed by upload_max_filesize and post_max_size. File system limits also apply (FAT32: 4 GB, ext4: 16 TB).

Do chunks still count toward PHP limits?

No — chunked uploading splits the file into smaller pieces. Each chunk is sent separately, so PHP handles a 100 MB chunk instead of a 2 GB file.

Why does the upload fail at 100%?

The upload completed, but PHP's post-processing or ownCloud's file assembly failed. Check max_execution_time — a slow network may need more time to collect POST data.


DodaTech — uploads without barriers.

Built by the developers of DodaTech

Doda Browser, DodaZIP & Durga Antivirus Pro