*New 12.1 series Release:
2019-11-08: XigmaNAS 12.1.0.4.7091 - released!

*New 11.3 series Release:
2019-10-19: XigmaNAS 11.3.0.4.7014 - released


We really need "Your" help on XigmaNAS https://translations.launchpad.net/xigmanas translations. Please help today!

Producing and hosting XigmaNAS costs money. Please consider donating for our project so that we can continue to offer you the best.
We need your support! eg: PAYPAL

webserver and owncloud increase upload limit

Webserver service.
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
negreasrin
Starter
Starter
Posts: 25
Joined: 15 Dec 2012 00:05
Location: Bucharest Romania
Status: Offline

webserver and owncloud increase upload limit

#1

Post by negreasrin » 15 Dec 2012 00:27

hello
i am new to forums ,i usually read and test
but i am stuck now .
please help
i need to increase the upload limit from owncloud ,current limit is 512m
i have tested on debian and the increase works,but debian uses apache
i have read and tested the following :

find / -name php.ini
/usr/local/etc/php.ini
edited php.ini but no luck
please help me to increase the limit to lighttpd and owncloud


thanks in advance
Read ,read ,test , and after that ask !
Google is your friend!
Ihave a NAS ,thanks to developers 4FREE!

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#2

Post by jparaja » 15 Dec 2012 19:33

Hi, how did you find the php.ini file. do i use a word pad? i too would like to increase owncloud upload file size.

thanks

User avatar
daoyama
Developer
Developer
Posts: 423
Joined: 25 Aug 2012 09:28
Location: Japan
Status: Offline

Re: webserver and owncloud increase upload limit

#3

Post by daoyama » 15 Dec 2012 20:20

Hi,

Try to edit /usr/local/bin/php-cgi-websrv.

Daisuke Aoyama
NAS4Free 10.2.0.2.2115 (x64-embedded), 10.2.0.2.2258 (arm), 10.2.0.2.2258(dom0)
GIGABYTE 5YASV-RH, Celeron E3400 (Dual 2.6GHz), ECC 8GB, Intel ET/CT/82566DM (on-board), ZFS mirror (2TBx2)
ASRock E350M1/USB3, 16GB, Realtek 8111E (on-board), ZFS mirror (2TBx2)
MSI MS-9666, Core i7-860(Quad 2.8GHz/HT), 32GB, Mellanox ConnectX-2 EN/Intel 82578DM (on-board), ZFS mirror (3TBx2+L2ARC/ZIL:SSD128GB)
Develop/test environment:
VirtualBox 512MB VM, ESXi 512MB-8GB VM, Raspberry Pi, Pi2, ODROID-C1

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#4

Post by jparaja » 16 Dec 2012 01:37

Thanks daoyama, but where do i find /usr/local/bin, is it in owncloud directory? sorry to sound so newb.

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4969
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: webserver and owncloud increase upload limit

#5

Post by raulfg3 » 16 Dec 2012 08:55

is in Nas4Free boot device.

use embeded file editor: Advanced|File Editor , locate file , and edit desired value, next, save it and restart NAS
12.0.0.4 (revision 6766)+OBI on SUPERMICRO X8SIL-F 8GB of ECC RAM, 12x3TB disk in 3 vdev in RaidZ1 = 32TB Raw size only 22TB usable

Wiki
Last changes

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#6

Post by jparaja » 16 Dec 2012 19:26

Will this increase owncloud upload limit and what command do I use?

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#7

Post by jparaja » 16 Dec 2012 22:02

OK, i think i know where i messed up. i installed owncloud on one of my drives instead of the data directory /mnt/data. im reinstalling owncloud correctly now and will report back

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#8

Post by jparaja » 16 Dec 2012 23:13

I want to set the max to 20gig. do i input 20g?


#!/bin/sh

SESSION_NAME="WS_PHPSESSID"
MEMORY_LIMIT="512M"
UPLOAD_MAX="512M"
POST_MAX="512M"

UPLOADDIR="`cat /var/etc/websrv-uploaddir.conf`"
if [ -z "$UPLOADDIR" ]; then
UPLOADDIR="/var/tmp/ftmp"
fi

/usr/local/bin/php-cgi -d session.name="$SESSION_NAME" -d memory_limit="$MEMORY_LIMIT" -d upload_max_filesize="$UPLOAD_MAX" -d post_max_size="$POST_MAX" -d upload_tmp_dir="$UPLOADDIR" "$@"

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4969
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: webserver and owncloud increase upload limit

#9

Post by raulfg3 » 16 Dec 2012 23:27

personally I think 20GBis too much, try 1 GB first, next try 4GB, keep in mind time necesary to upload 20GB using ADSL line ( asimetric).


example for 1GB

Code: Select all

#!/bin/sh

SESSION_NAME="WS_PHPSESSID"
MEMORY_LIMIT="1024M"
UPLOAD_MAX="1024M"
POST_MAX="1024M"

UPLOADDIR="`cat /var/etc/websrv-uploaddir.conf`"
if [ -z "$UPLOADDIR" ]; then
UPLOADDIR="/var/tmp/ftmp"
fi

/usr/local/bin/php-cgi -d session.name="$SESSION_NAME" -d memory_limit="$MEMORY_LIMIT" -d upload_max_filesize="$UPLOAD_MAX" -d post_max_size="$POST_MAX" -d upload_tmp_dir="$UPLOADDIR" "$@"
example for 4GB

Code: Select all

#!/bin/sh

SESSION_NAME="WS_PHPSESSID"
MEMORY_LIMIT="4096M"
UPLOAD_MAX="4096M"
POST_MAX="4096M"

UPLOADDIR="`cat /var/etc/websrv-uploaddir.conf`"
if [ -z "$UPLOADDIR" ]; then
UPLOADDIR="/var/tmp/ftmp"
fi

/usr/local/bin/php-cgi -d session.name="$SESSION_NAME" -d memory_limit="$MEMORY_LIMIT" -d upload_max_filesize="$UPLOAD_MAX" -d post_max_size="$POST_MAX" -d upload_tmp_dir="$UPLOADDIR" "$@"

PD: remenber that you can split file in several parts ( using winzip, or winRAR or etc...) so really no need to upload 20GB in one big file
12.0.0.4 (revision 6766)+OBI on SUPERMICRO X8SIL-F 8GB of ECC RAM, 12x3TB disk in 3 vdev in RaidZ1 = 32TB Raw size only 22TB usable

Wiki
Last changes

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#10

Post by jparaja » 17 Dec 2012 00:37

Thank you raulfg3, It work perfectly. this is the first time i use the file editor in nas4free.

negreasrin
Starter
Starter
Posts: 25
Joined: 15 Dec 2012 00:05
Location: Bucharest Romania
Status: Offline

Re: webserver and owncloud increase upload limit

#11

Post by negreasrin » 17 Dec 2012 16:16

daoyama wrote:Hi,

Try to edit /usr/local/bin/php-cgi-websrv.

Daisuke Aoyama

thanks a lot

always the developer can help.

worked like a charm
thanks
Read ,read ,test , and after that ask !
Google is your friend!
Ihave a NAS ,thanks to developers 4FREE!

negreasrin
Starter
Starter
Posts: 25
Joined: 15 Dec 2012 00:05
Location: Bucharest Romania
Status: Offline

Re: webserver and owncloud increase upload limit

#12

Post by negreasrin » 17 Dec 2012 16:19

jparaja wrote:Hi, how did you find the php.ini file. do i use a word pad? i too would like to increase owncloud upload file size.

thanks
to find use this command without quotes "find / -name php.ini" ,but editing this will Not increase your limit
to increase your limit follow Daisuke Aoyama post and use nas4free file editor
Read ,read ,test , and after that ask !
Google is your friend!
Ihave a NAS ,thanks to developers 4FREE!

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#13

Post by jparaja » 17 Dec 2012 17:34

every time i set upload limit in file editor and save, it resets back to 512 after a reboot. how do i make it stick?

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4969
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: webserver and owncloud increase upload limit

#14

Post by raulfg3 » 17 Dec 2012 20:39

jparaja wrote:every time i set upload limit in file editor and save, it resets back to 512 after a reboot. how do i make it stick?
probably you have an embeded install, easy way to have persistent is to have a full install.

You can save your config, do a new fresh full install and restore your config.

Now you cahanges are persistent.


PD: If you are worried about life of your USB, you can allways save logs on data disk to minimize writes on Flash disk ( search the forum , there are a lot of usefull info of how to do , and in wiki too).
12.0.0.4 (revision 6766)+OBI on SUPERMICRO X8SIL-F 8GB of ECC RAM, 12x3TB disk in 3 vdev in RaidZ1 = 32TB Raw size only 22TB usable

Wiki
Last changes

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#15

Post by jparaja » 20 Dec 2012 02:47

Hi raulfg3, why can't I upload a 3gig file? My upload limit is 10gig

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4969
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: webserver and owncloud increase upload limit

#16

Post by raulfg3 » 20 Dec 2012 07:53

What Filesystem do you use? ext2 have a 2GB limit
12.0.0.4 (revision 6766)+OBI on SUPERMICRO X8SIL-F 8GB of ECC RAM, 12x3TB disk in 3 vdev in RaidZ1 = 32TB Raw size only 22TB usable

Wiki
Last changes

jparaja
NewUser
NewUser
Posts: 13
Joined: 13 Dec 2012 00:46
Status: Offline

Re: webserver and owncloud increase upload limit

#17

Post by jparaja » 20 Dec 2012 15:49

All drives formated to UFS

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4969
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: webserver and owncloud increase upload limit

#18

Post by raulfg3 » 20 Dec 2012 17:07

jparaja wrote:Hi raulfg3, why can't I upload a 3gig file? My upload limit is 10gig
not sure, try , 2GB, 1GB , 512MB to determine what is the file size limit.

PD: revise your config to be sure that use data disk and not boot disk to store upload files.
12.0.0.4 (revision 6766)+OBI on SUPERMICRO X8SIL-F 8GB of ECC RAM, 12x3TB disk in 3 vdev in RaidZ1 = 32TB Raw size only 22TB usable

Wiki
Last changes

maxxximilian
NewUser
NewUser
Posts: 9
Joined: 06 Nov 2012 19:04
Status: Offline

Re: webserver and owncloud increase upload limit

#19

Post by maxxximilian » 12 May 2013 20:21

jparaja wrote:Hi raulfg3, why can't I upload a 3gig file? My upload limit is 10gig
I have the same problem and I figured out that file size limit is 2GB. Upload limit is set to 12GB on php-cgi-websrv file. Filesystem is ZFS, Owncloud is installed to data storage (where I have many files over 2GB). Is there any way to fix this?

Btw, in NAS4Free web panel, Diagnostics, Log are errors like:
lighttpd[33244]: (request.c.1182) request-size too long: 2835343949 -> 413
lighttpd[18084]: (request.c.1182) request-size too long: 6920716363 -> 413

and so on.
NAS4Free 10.2.0.2.2218 X64 full, CPU Intel Xeon E3-1230v5, RAM 64 GB, MB Supermicro X11SSH-F, Fractal Design Define Mini, 1x32GB SataDOM system, 3x4TB WD RED data on RAIDZ1

athena
NewUser
NewUser
Posts: 3
Joined: 24 Apr 2014 22:57
Status: Offline

Re: webserver and owncloud increase upload limit

#20

Post by athena » 01 May 2014 04:05

maxxximilian wrote:
jparaja wrote:Hi raulfg3, why can't I upload a 3gig file? My upload limit is 10gig
I have the same problem and I figured out that file size limit is 2GB. Upload limit is set to 12GB on php-cgi-websrv file. Filesystem is ZFS, Owncloud is installed to data storage (where I have many files over 2GB). Is there any way to fix this?

Btw, in NAS4Free web panel, Diagnostics, Log are errors like:
lighttpd[33244]: (request.c.1182) request-size too long: 2835343949 -> 413
lighttpd[18084]: (request.c.1182) request-size too long: 6920716363 -> 413

and so on.
Did you end up finding out the issue? I am currently encountering the exact same problem.

maxxximilian
NewUser
NewUser
Posts: 9
Joined: 06 Nov 2012 19:04
Status: Offline

Re: webserver and owncloud increase upload limit

#21

Post by maxxximilian » 15 May 2014 08:54

No. I think it is Owncloud limitation.
NAS4Free 10.2.0.2.2218 X64 full, CPU Intel Xeon E3-1230v5, RAM 64 GB, MB Supermicro X11SSH-F, Fractal Design Define Mini, 1x32GB SataDOM system, 3x4TB WD RED data on RAIDZ1

athena
NewUser
NewUser
Posts: 3
Joined: 24 Apr 2014 22:57
Status: Offline

Re: webserver and owncloud increase upload limit

#22

Post by athena » 03 Jun 2014 21:38

I figured out how to upload files larger than 2GB after a lot of searching and head banging. I will share it in the hopes that it will help somebody.

In addition to the changes for php-cgi-websrv, you also need to change the websrv file in /etc/rc.d/
Open the websrv file change the following parameter:
server.max-request-size= 5243440000 # or whatever you want max file size to be (this would set it to 5GB)

Post Reply

Return to “WebServer”