WAS 9

Apache httpd 2.4 virutalhost, reverseproxy 설정 (location, IP 제한 등)

1. httpd.conf 수정 (주석처리 해제: 첫 # 글자 삭제)LoadModule proxy_module modules/mod_proxy.soLoadModule proxy_http_module modules/mod_proxy_http.so # Virtual hostsInclude conf/extra/httpd-vhosts.conf 2. extra/httpd-vhosts.conf 수정 (reverseproxy 설정 + location별 IP 제한) DocumentRoot "${SRVROOT}/htdocs" ProxyRequests Off ProxyPreserveHost On Require ip 허용할IP1 허용할IP2 Require ip 허용할IP1 허용할IP2 ProxyPass/nagioshttp:/..

WAS 2017.10.19

Apache Commons Fileupload UTF-8 환경 한글파일명 깨짐 해결

Tomcat JVM -Dfile.encoding=UTF-8 사용시 문제가 해결되는 듯 하지만, console log 한글이 깨지게 된다. 아래와 같이 설정후 해결되어서 기록차 남김... if(ServletFileUpload.isMultipartContent(request)) {DiskFileItemFactory factory = new DiskFileItemFactory();factory.setSizeThreshold(THRESHOLD_SIZE);factory.setRepository(new File(System.getProperty("java.io.tmpdir")));ServletFileUpload upload = new ServletFileUpload(factory);upload.setHeaderEn..

WAS 2014.11.25

PHP ext 모듈 컴파일 및 설치

환경: CentOS 6.5 (Basic Server, yum groupinstall "Development Tools" 등 기본 라이브러리 설치됨) httpd-2.4.9 (./configure --enable-module=so --enable-so --enable-mods-shared=ssl --enable-ssl=shared --enable-mods-shared-all --enable-rewrite) php-5.5.12 (./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql) 1) PHP 소스 디렉토리 ext 폴더에서 아래 명령어 실행 (cf. /php-5.5.12/ext) # /usr/local/bin/phpize ; ./configur..

WAS 2014.05.22

nginx_1.2.6 + php_5.4.10

1. nginx conf 수정 (conf/nginx.conf)...# location 바깥쪽 (server) 로 빼주면 전역 변수처럼 $document_root 로 치환된다.# location 안쪽에 root를 쓰면 그 block 안에서만 처리됨root d:/server/htdocs;...location / { index index.html index.htm index.php; }location ~ \.php$ { fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; # web root 경로 include fastcgi_params; } 2. p..

WAS/Nginx 2012.12.30

Windows / apache_2.4.3 + php_5.4.10 + mod_fcgid_2.3.7

프로그램 폴더 httpd-2.4.3-win32 (Apache) d:/server/apache php-5.4.10-Win32-VC9-x86 (PHP) d:/server/php mod_fcgid-2.3.7-win32 (Fast CGI) d:/server/apache/modules* Apache 2.4.3과 mod_fcgid-2.3.7 Win32 binary 위치http://www.apachelounge.com/download/(thread-safe module 사용에 주의) 1. Module 로드LoadModule fcgid_module modules/mod_fcgid.so 2. d:/server/apache/conf/httpd.conf 수정DocumentRoot "d:/server/htdocs"...Add..

WAS/Apache 2012.12.29

ISAPI / CGI(fastcgi, fcgid) / mpm(worker, prefork, event)

처리 방식 특성 서버 방식 Apache 사용 mod Process non-threaded (thread-safe) non-thread-safe 모듈 사용 가능 안정성, 다소 느림 mpm=prefork (Apache) FastCGI (IIS) Thread threaded (non-thread-safe) thread-safe 모듈 사용해야함 확장성, 다소 빠름 mpm=worker (Apache) ISAPI(IIS) mod_fcgid (mod_fastcgi) Event event-driven (async.) 저비용, 빠름, 확장성 검증 필요 mpm=event (Apache 2.4) Nginx [apache vs nginx]Apache: 많은 reference, 많고 안정화된 mod (특히 mod_rewrite..

WAS/Apache 2012.12.29