PDA

View Full Version : What to change in php.ini and my.cnf for 20-30mb uploads?


BamaStangGuy
Fri 7th Jan '05, 3:24am
I'm not sure of all the changes I need to make for users to be able to upload 20-30mb files or larger...

max_execution_time = 120 ; Maximum execution time of each script, in seconds
max_input_time = 60 ; Maximum amount of time each script may spend parsing request data
memory_limit = 36M ; Maximum amount of memory a script may consume (8MB)

post_max_size = 10M

upload_max_filesize = 10M

and my.cnf

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
skip-innodb
max_connections = 250
key_buffer = 16M
myisam_sort_buffer_size = 64M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 1024
thread_cache_size = 64
wait_timeout = 3600
connect_timeout = 10
max_allowed_packet = 16M
max_connect_errors = 10
query_cache_limit = 1M
query_cache_size = 16M
query_cache_type = 1

[mysql.server]
user=mysql
basedir=/var/lib

[safe_mysqld]
err-log=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
open_files_limit=8192

[mysqldump]
quick
max_allowed_packet = 16M

[myisamchk]
key_buffer = 64M
sort_buffer = 64M
read_buffer = 16M
write_buffer = 16M


I assume those are the ones I need to change? If so what would be the optimal settngs for uploading large files like that

Is there a better way to do this other than php? I want to video and sound section on my site for users to upload videos and sounds of their cars to their user account and host them so they can link to others with my url

Thanks for any help that is recieved!

eva2000
Fri 7th Jan '05, 12:06pm
is this for uploading via vBulletin attachment system ? if so i advise against it, as vB was never intended to be a file storage system and such large files would be a strain even with attachments as files

i'd use a 3rd party app to storage these files in the filesystem not a database

but if you decided to ignore my warnings,

max_execution_time = 180 ; Maximum execution time of each script, in seconds
max_input_time = 60 ; Maximum amount of time each script may spend parsing request data
memory_limit = 16M ; Maximum amount of memory a script may consume (8MB)

post_max_size = 40M

upload_max_filesize = 40M

would be closer to what you need

BamaStangGuy
Fri 7th Jan '05, 2:05pm
is this for uploading via vBulletin attachment system ? if so i advise against it, as vB was never intended to be a file storage system and such large files would be a strain even with attachments as files

i'd use a 3rd party app to storage these files in the filesystem not a database

but if you decided to ignore my warnings,

max_execution_time = 180 ; Maximum execution time of each script, in seconds
max_input_time = 60 ; Maximum amount of time each script may spend parsing request data
memory_limit = 16M ; Maximum amount of memory a script may consume (8MB)

post_max_size = 40M

upload_max_filesize = 40M

would be closer to what you need
thank you and no this won't be handled by vbulletin, it will be a custom written script by a friend of mine that will handle the uploading and such

Again thanks for the help :)