[Solved] Can not upload large file whose name is Chinese

Hello community,

I hope this message finds you well. This is my first time seeking help, and I’m encountering an issue with my Nextcloud server installation. I followed the official instructions using Apache2 and MariaDB.(manual installation with Archive file)

The problem arises when I attempt to upload large files (exceeding 100MB) with Chinese filenames via the web page. The upload process gets stuck at “estimating time left.” Surprisingly, if I change the file name to English, the upload proceeds smoothly. Additionally, I’ve observed that small files (less than 1MB) with Chinese names, including those renamed to match the problematic larger files, succeed to upload.

It seems that the issue is specifically related to the upload of large files with Chinese filenames. Any insights or guidance on resolving this matter would be highly appreciated.

Thank you in advance for your assistance.

Best regards,


Have you referred to NC instance logs to see what errors / warnings if any, are being generated.

Thank you for your attention. I have checked logs, there is nothing new in logs after my upload failure.

Hi @Toby_Chen

What level of verbosity are you logs set to output? Make sure you have ALL options checked. You should be seeing something relating to your attempted upload.

From your dashboard:
Adminstration Settings > Logging.

Click on the 3 menu dots to the left of the ‘Level’ heading, select all options.
Retry your upload and see what is entered in to the log.

Have you enabled 4 byte database support, this will almost certainly be needed for Chinese characters.

Enabling MySQL 4-byte support — Nextcloud latest Administration Manual latest documentation (refer to the correct documentation for your release)

Yes, I am. As I installed it following the official instruction, I am sure that I did.

CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
CREATE DATABASE IF NOT EXISTS nextcloud CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
GRANT ALL PRIVILEGES ON nextcloud.* TO 'username'@'localhost';

The log info double-check is not available now due to my reinstallation of my server. I need to reinstall nextcloud, it takes time.
This seems not my only issue. There is someone else mentioned this bug on github issues

Whatever, thank you very much.

So do you also only get this issue when uploading via the web console?

Which browser had you used?

Could you post a sample file name here, not the file just the file name if possible. I’ll attempt to replicate.

Could be similar to this: php - UTF-8 Characters in XMLHttpRequest are corrupted - Stack Overflow

So do you also only get this issue when uploading via the web console?

Sorry, I forgot to try this on my Android client. So as far as I concern, this happenes only via web uploading. WebDAV is fine as I have tried.

Which browser had you used?

I have tried Chrome Version 120.0.6099.109 (Official Build) (x86_64) and Safari Version 17.0 (19616. Both of them are on my Macbook Pro 2020(Intel chip, MacOS Sonoma, Version 14.0 ).

Could you post a sample file name here, not the file just the file name if possible. I’ll attempt to replicate.

I have tried, any characters in Chinese can replicate this issue.
eg. 测试.pdf (“测试” means “test” in Chinese)

Thank you for your time.

If you are using Nextcloud 28 already, it’s likely a bug that our uploader does not encode the file path properly.

The related report on GitHub: https://github.com/nextcloud/server/issues/42327

I’ve uploaded a 115Mb file with your 测试 ‘test’ file name.
Uploaded successfully.
I was using Ubuntu Linux 22.04 with Firefox 120.0.1

I am however using NC 26.0.5.

If you are able you might want to try using a docker image of 26.0.0 and see if the problem persists.

Actually, I am the same persion who posted the issue on github. Now, this issue closed as it is solved. Thanks to all developers and contributors, after upgrading to 28.0.1, this issue disappeared. Now I can upload large file with Chinese filename successfully!

Thank you for your test which tends to help me, now I am using the latest version 28.0.1 as my issue is solved in this version.

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.