티스토리 뷰

Network/PHP

Portable 웹서버 XAMPP

알 수 없는 사용자 2011. 3. 21. 16:10

Source : http://deepbird.tistory.com/368

 

 

간단히 웹어플리케이션을 테스트해볼 웹서버의 필요성을 느낌.

USB에 저장해 간단히 사용할 웹서버를 찾아 봄
http://www.apachefriends.org/en/xampp.html 의 XAMPP Lite를 다운로드 받아 USB에 저장함. 기본팩이 약 192메가, Lite팩이 약 115메가이다.
Apache, MySQL, PHP를 사용할 수 있다.  자세한 사항은 홈페이지 참조
라이트 버전의 경우 Filezilla FTP 서버와 Mercury Mail 이 빠져 있다.

1. 설치

1. 압축파일을 다운로드 받아 압축을 푼뒤 USB에 옮긴다.

2. 폴더를 열어 setup-xampp.bat 파일을 실행한다.
만약 xampp프로그램이 위치한 폴더가 루트디렉토리 바로 아래에 있다면 setup-xampp.bat를 실행할 필요없이 바로 시작할 수 있다.

3. xampp-control.exe 를 시작해 콘트롤패널을 통해 각 서비스를 시작하거나, 배치파일을 이용해 각 서비스를 시작하거나 중지한다.

4. 웹브라우저를 열어 http://localhost/ 나 http://127.0.0.1 로 접속한다.

5. 보안을 위해 http://localhost/security/index.php 에 접속해 mysql의 root 비밀번호를 지정한 뒤 mysql을 재시작한다.

 

2. 설정파일의 위치

· Apache basic configuration: .\xampp\apache\conf\httpd.conf

· Apache SSL: .\xampp\apache\conf\ssl.conf

· Apache Perl (only addon): .\xampp\apache\conf\perl.conf

· Apache Tomcat (only addon): .\xampp\apache\conf\java.conf

· Apache Python (only addon): .\xampp\apache\conf\python.conf

· PHP: .\xampp\apache\bin\php.ini (with the apache actually running php version)

· MySQL: .\xampp\mysql\bin\my.cnf

· phpMyAdmin: .\xampp\phpMyAdmin\config.inc.php

· FileZilla FTP: .\xampp\FileZillaFTP\FileZilla Server.xml

· Mercury Mail basic configuration: .\xampp\MercuryMail\MERCURY.INI

· Sendmail: .\xampp\sendmail\sendmail.ini

 

3. XAMPP에서 사용하는 기본 포트(변경가능)

· http 80 (HTTP)

· https 443 (SSL)

· mysql 3306

· ftp 21

· smtp 25

· pop3 110

· imap 143

· AJP/1.3 8009

· http-alt 8080 (Tomcat Default Port)

 

4. 삭제

압축 파일로 설치 한 경우 삭제는 모든 서비스를 중단한 뒤 설치된 디렉토리를 삭제하면 바로 삭제 된다.