게시판의 업로드 파일 한 개당, "파일 업로드 용량"을 2G 이상으로 변경하는 법

게시판의 업로드 파일 한 개당, "파일 업로드 용량"을 2G 이상으로 변경하는 법

QA

게시판의 업로드 파일 한 개당, "파일 업로드 용량"을 2G 이상으로 변경하는 법

본문

! 그누보드5의 게시판,  "파일 업로드 용량"(https://policy.glitter.kr/qa_php/board_up_limit.png)을

 

2G ( 2,147,483,647 bytes 이상으로 변경하고 싶습니다.

 

!. "업로드 파일 한 개당 "  용량을 늘리는 방법은 없나요?

 

!. nginx.conf 와 php.ini는 모두 변경하여, 2G까지는 잘 작동이 되는데, ~~

 

== nginx.conf


. . .
    proxy_read_timeout            1800s;
    proxy_connect_timeout         1800s;
    proxy_send_timeout            1800s;
    fastcgi_read_timeout          1800s;
    fastcgi_send_timeout          1800s;
    resolver_timeout              5s;
    client_header_timeout         10s;
    client_body_timeout           1800s;
    send_timeout                  1800s;
    keepalive_timeout             1800s 1800s;
    client_max_body_size          20480M;
    http2_max_client_body_buffer_size 16m;
    server_names_hash_max_size    8192;
    server_names_hash_bucket_size 128;
. . .

 

== php.ini


. . .
[core]
allow_url_fopen = 1
allow_url_include = 0
auto_detect_line_endings = 0
auto_globals_jit = 1
default_charset = UTF-8
default_mimetype = text/html
default_socket_timeout = 60
disable_classes =
disable_functions =
display_startup_errors = 0
docref_ext =
docref_root =
enable_dl = Off
enable_post_data_reading = 1
error_log_mode = 0644
error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED
expose_php = Off
extension_dir = /usr/local/lib/php82/modules
file_uploads = 1
hard_timeout = 1800
html_errors = off
ignore_repeated_errors = 0
ignore_repeated_source = 0
ignore_user_abort = 0
implicit_flush = 1
include_path = .:/usr/share/pear
log_errors = On
max_execution_time = 1800
max_file_uploads = 20
max_input_nesting_level = 64
max_input_time = -1
max_input_vars = 1000
max_multipart_body_parts = -1
memory_limit = 1638M
output_buffering = Off
post_max_size = 102400M
precision = 14
realpath_cache_size = 4096K
realpath_cache_ttl = 120
register_argc_argv = Off
report_memleaks = 1
report_zend_debug = 0
request_order = GP
sendmail_path = /usr/bin/ssmtp -t
serialize_precision = -1
short_open_tag = On
SMTP = localhost
smtp_port = 25
sys_temp_dir = /var/services/tmp
unserialize_max_depth = 4096
upload_max_filesize = 102400M
upload_tmp_dir = /var/services/tmp
variables_order = GPCS
xmlrpc_error_number = 0
xmlrpc_errors = 0
. . .

 

--- 업로드 파일 한개당, 2G (2,147,483,647 bytes) 까지는 업로드가 잘 됩니다. ---

    >> 업로드 테스트 하기

 

>> 그누보드5의 용량의 한계치, 2G (2,147,483,647 bytes)가 설정 되어 있군요.

 

.                                                   ※  . . . 조언 부탁드립니다.

이 질문에 댓글 쓰기 :

답변 3

php에서 업로드 용량은 2기가가 최대치 인걸로 알고 있습니다.

설정하는 방법은 httpd.conf 또는 .htaccess에서 

 

php_value upload_max_filesize 50M  <- 예시
php_value post_max_size 100M <- 예시

 

요런식으로 설정해서 조절하실수있습니다. 

물론 php.ini에서도 설정이 가능합니다.

 

php.ini에 설정하려면 

 

upload_max_filesize = 50M  ; 예시: 50MB로 설정
post_max_size = 100M       ; 예시: 100MB로 설정

 

요런식으로 해보시기 바랍니다.

참고로 아파치 서버 기준입니다.

nginx 자체에도 허용용량 있어서 삽질하느라 딥빡쳤던 기억이 ㅋㅋ

답변을 작성하시기 전에 로그인 해주세요.
전체 3,216
QA 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1404호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT