웹마스터 팁
page_full_width" class="col-xs-12" |cond="$__Context->page_full_width">
mod_gzip 적용시 php 인클루드를 실패해서 포기하신분 보세요
2002.12.08 20:41
문서의 순서
1. gzip 모듈을 설정하는 방법
2. httpd conf 내용 ( 제가 사용하는 것입니다)
3. php 에서의 설정 내용 ( 제가 사용하는 것입니다)
------------------------------------------------
1.
Module Name: mod_gzip.c
Content handlers: mod_gzip_handler , application/x-httpd-cgi , cgi-script , *
Configuration Phase Participation: Create Directory Config, Merge Directory Configs, Create Server Config, Merge Server Configs
Request Phase Participation: Check Type
Module Directives:
mod_gzip_on - Yes=mod_gzip will handle requests. No=mod_gzip is disabled.
mod_gzip_add_header_count - Yes=Add header byte counts to Common Log Format output total(s).
mod_gzip_keep_workfiles - Yes=Keep any work files used. No=Automatically delete any work files used.
mod_gzip_dechunk - Yes=Allow removal of 'Transfer-encoding: chunked' when necessary.
mod_gzip_min_http - Minimum HTTP protocol value to support. 1000 = HTTP/1.0 1001 = HTTP/1.1
mod_gzip_minimum_file_size - Minimum size ( bytes ) of a file eligible for compression
mod_gzip_maximum_file_size - Maximum size ( bytes ) of a file eligible for compression
mod_gzip_maximum_inmem_size - Maximum size ( bytes ) to use for in-memory compression.
mod_gzip_temp_dir - The directory to use for work files and compression cache
mod_gzip_item_include - ARG1=[mime,handler,file,uri,reqheader,rspheader] ARG2=[Name of item to INCLUDE in list of things that should be compressed]
mod_gzip_item_exclude - ARG1=[mime,handler,file,uri,reqheader,rspheader] ARG2=[Name of item to EXCLUDE from list of things that should be compressed]
mod_gzip_command_version - User defined pickup string to use for mod_gzip version command.
mod_gzip_can_negotiate - Yes=Negotiate/send static compressed versions of files No=Do not negotiate.
mod_gzip_handle_methods - mod_gzip_handle_methods GET|POST [GET|POST]
mod_gzip_static_suffix - mod_gzip_static_suffix suffix
mod_gzip_send_vary - mod_gzip_send_vary on|off
mod_gzip_update_static - mod_gzip_update_static yes|no
2. httpd conf 의 내용 ( 제가 사용하는 것입니다)
<IfModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk yes
mod_gzip_min_http 1001
mod_gzip_minimum_file_size 300
mod_gzip_maximum_file_size 0
mod_gzip_maximum_inmem_size 1024000
mod_gzip_keep_workfiles No
mod_gzip_item_include file .jsp$
mod_gzip_item_include file .org$
mod_gzip_item_include file .shtml$
mod_gzip_item_include file .htm$
mod_gzip_item_include file .html$
mod_gzip_item_include file .php$
mod_gzip_item_include file .php3$
mod_gzip_item_include file .php4$
mod_gzip_item_include mime text/.*
mod_gzip_item_include mime text/.htm
mod_gzip_item_include mime text/htm$
mod_gzip_item_include mime text/.html
mod_gzip_item_include mime text/html$
mod_gzip_item_include mime text/.php
mod_gzip_item_include mime text/php$
mod_gzip_item_include mime text/.php3
mod_gzip_item_include mime text/php3$
mod_gzip_item_include mime text/.php4
mod_gzip_item_include mime text/php4$
mod_gzip_item_include handler perl-script$
mod_gzip_item_include handler server-status$
mod_gzip_item_include handler server-info$
mod_gzip_item_include mime httpd/unix-directory
mod_gzip_item_include mime application/x-httpd-php
mod_gzip_item_exclude file ".css$"
mod_gzip_item_exclude file ".js$"
mod_gzip_item_exclude mime image/.*
mod_gzip_item_exclude reqheader "User-agent: Mozilla/4.0[678]"
mod_gzip_temp_dir /ramdrv/ztemp #이부분은 탬프를 지정하는 부분입니다 저는 램드라이브를 사용합니다
</IfModule>
3. php 설정에서 아래 부분을 그대로 적용하세요
output_buffering = 8192 ;이부분에 적용할 값을 모를 경우 1또는 On으로 하세요
output_handler =ob_gzhandler
zlib.output_compression = Off
마치면서.. 계속적인 논란이 있는 mod_gzip 의 효능/성능에 대해서는 직접 체감해보시기 바랍니다 wow입니다 :)
1. gzip 모듈을 설정하는 방법
2. httpd conf 내용 ( 제가 사용하는 것입니다)
3. php 에서의 설정 내용 ( 제가 사용하는 것입니다)
------------------------------------------------
1.
Module Name: mod_gzip.c
Content handlers: mod_gzip_handler , application/x-httpd-cgi , cgi-script , *
Configuration Phase Participation: Create Directory Config, Merge Directory Configs, Create Server Config, Merge Server Configs
Request Phase Participation: Check Type
Module Directives:
mod_gzip_on - Yes=mod_gzip will handle requests. No=mod_gzip is disabled.
mod_gzip_add_header_count - Yes=Add header byte counts to Common Log Format output total(s).
mod_gzip_keep_workfiles - Yes=Keep any work files used. No=Automatically delete any work files used.
mod_gzip_dechunk - Yes=Allow removal of 'Transfer-encoding: chunked' when necessary.
mod_gzip_min_http - Minimum HTTP protocol value to support. 1000 = HTTP/1.0 1001 = HTTP/1.1
mod_gzip_minimum_file_size - Minimum size ( bytes ) of a file eligible for compression
mod_gzip_maximum_file_size - Maximum size ( bytes ) of a file eligible for compression
mod_gzip_maximum_inmem_size - Maximum size ( bytes ) to use for in-memory compression.
mod_gzip_temp_dir - The directory to use for work files and compression cache
mod_gzip_item_include - ARG1=[mime,handler,file,uri,reqheader,rspheader] ARG2=[Name of item to INCLUDE in list of things that should be compressed]
mod_gzip_item_exclude - ARG1=[mime,handler,file,uri,reqheader,rspheader] ARG2=[Name of item to EXCLUDE from list of things that should be compressed]
mod_gzip_command_version - User defined pickup string to use for mod_gzip version command.
mod_gzip_can_negotiate - Yes=Negotiate/send static compressed versions of files No=Do not negotiate.
mod_gzip_handle_methods - mod_gzip_handle_methods GET|POST [GET|POST]
mod_gzip_static_suffix - mod_gzip_static_suffix suffix
mod_gzip_send_vary - mod_gzip_send_vary on|off
mod_gzip_update_static - mod_gzip_update_static yes|no
2. httpd conf 의 내용 ( 제가 사용하는 것입니다)
<IfModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk yes
mod_gzip_min_http 1001
mod_gzip_minimum_file_size 300
mod_gzip_maximum_file_size 0
mod_gzip_maximum_inmem_size 1024000
mod_gzip_keep_workfiles No
mod_gzip_item_include file .jsp$
mod_gzip_item_include file .org$
mod_gzip_item_include file .shtml$
mod_gzip_item_include file .htm$
mod_gzip_item_include file .html$
mod_gzip_item_include file .php$
mod_gzip_item_include file .php3$
mod_gzip_item_include file .php4$
mod_gzip_item_include mime text/.*
mod_gzip_item_include mime text/.htm
mod_gzip_item_include mime text/htm$
mod_gzip_item_include mime text/.html
mod_gzip_item_include mime text/html$
mod_gzip_item_include mime text/.php
mod_gzip_item_include mime text/php$
mod_gzip_item_include mime text/.php3
mod_gzip_item_include mime text/php3$
mod_gzip_item_include mime text/.php4
mod_gzip_item_include mime text/php4$
mod_gzip_item_include handler perl-script$
mod_gzip_item_include handler server-status$
mod_gzip_item_include handler server-info$
mod_gzip_item_include mime httpd/unix-directory
mod_gzip_item_include mime application/x-httpd-php
mod_gzip_item_exclude file ".css$"
mod_gzip_item_exclude file ".js$"
mod_gzip_item_exclude mime image/.*
mod_gzip_item_exclude reqheader "User-agent: Mozilla/4.0[678]"
mod_gzip_temp_dir /ramdrv/ztemp #이부분은 탬프를 지정하는 부분입니다 저는 램드라이브를 사용합니다
</IfModule>
3. php 설정에서 아래 부분을 그대로 적용하세요
output_buffering = 8192 ;이부분에 적용할 값을 모를 경우 1또는 On으로 하세요
output_handler =ob_gzhandler
zlib.output_compression = Off
마치면서.. 계속적인 논란이 있는 mod_gzip 의 효능/성능에 대해서는 직접 체감해보시기 바랍니다 wow입니다 :)
댓글 2
-
DukeEYS
2002.12.09 10:51
-
류청
2002.12.09 10:07
안녕하세요!! DukeEYS 글 잘 읽었읍니다. 저도 어제 웹 서버 설치를 했읍니다.
zend optimizer 적용해서요..
아직 mod_gzip은 집 컴에다 테스트 좀 하고 해야 겠네요.
관리하는 서버에 직접 적용할수가 없어서요..
그럼 좋은 하루 되세요!
이번 기회에 리누기를 벋고 프비를 입어보세요
아주 잘 맞는 옷이 될듯합니다 :) 저는 윈도즈의 광신도이자 프비의 팬입니다 :)
정통 UNIX 혈통의 프비는 안정성과 퍼포먼스가 그 어느 OS 보다 뛰어나지만 아직은
그리고 앞으로도 호환성에 있어서는 윈도즈를 따라올 OS 는 금세기에는 없을듯 합니다
너무 과장인가??? ㅋㅋㅋㅋ 향후 10년 혹은 20년으루 하죠 어쨌든 류청님 여기서 보니까
특히 반갑네요 :) 부디 성공 하시길.... 영원히 꺼지지 않는 프비의 세계도 접해보시길....