개발환경 APM 설치하기
윈도10 64bit 환경
현재 웹호스팅 환경과 최대한 동일하게 하기 위해 예전 버전을 설치하였다.
64bit https://www.anindya.com/php-5-4-3-and-php-5-3-13-x64-64-bit-for-windows/
Apache
https://www.apachelounge.com/download/
PHP랑 맞추려면 x86 으로 설치해야 함
- [Apache 변수] conf > httpd.conf
- Define SRVROOT “c:/Apache24”
- ServerRoot “${SRVROOT}”
- DocumentRoot “${SRVROOT}/htdocs”
- ServerName 127.0.0.1:80 #제거
- [윈도 변수] Edit Environment Variables
- Path : c:/Apache24/bin
- 설치 : cmd 관리자권한 실행
- httpd -k install
- httpd -k start
- 127.0.0.1:80 접속
PHP
5.4.39.
https://windows.php.net/downloads/ > past realeses..
https://windows.php.net/downloads/releases/archives/
- php.ini-development > php.ini 로 변경
- extension_dir = “C:\Apache24\php-5.4.39\ext” ; 삭제
- Apache > conf > httpd.conf 에 추가 : php7 → php5로 수정
#PHP LoadModule php5_module "C:\php/php5apache2_4.dll" AddType application/x-httpd-php .php .html AddHandler application/x-httpd-php .php .html #configure the path to php.ini PHPIniDir "C:\Apache24\php-5.4.39"
- [cmd] httpd.exe -k restart
- <?php phpinfo(); ?> : htdocs 폴더에 넣고 접속, 실험
MySQL
5.0.90
https://dev.mysql.com/downloads/mysql/ > Archive 에서 찾아서 다운로드
- [환경변수] Path : c:\Apache24\mysql-5.0.90\bin
- my-small.ini > my.ini 로 변경
[mysqld] # set basedir to your installation path basedir=C:/Apache24/mysql-5.0.90 # set datadir to the location of your data directory datadir=C:/Apache24/mysql-5.0.90/data port=3306
- [cmd] mysqld –install
- php> php.ini : extension=php_mysql.dll (; 제거)
- [윈도 > System > Mysql > Start]
- [cmd] httpd -k restart
비밀번호 설정
초기에는 비밀번호 없음
- [cmd] mysql>bin> : mysql -u root -p mysql : 그냥 엔터치면 접속됨
- mysql> update user set pasword = password('비밀번호') where user = 'root';
- mysql> flush privileges;
- mysql> quit
phpMyAdmin
https://www.phpmyadmin.net/downloads/
https://www.phpmyadmin.net/files/4.0.10.20/
- php.ini
- extension=php_mbstring.dll
- extension=php_mysqli.dll
Reference
https://rlaehdgs12.tistory.com/5
https://yongku.tistory.com/entry/%EC%9C%88%EB%8F%84%EC%9A%B0-10Windows-10-%EC%9A%B4%EC%98%81%EC%B2%B4%EC%A0%9C%EC%97%90%EC%84%9C-APMApache-PHP-MySQL-%EC%84%A4%EC%B9%98-%EB%B0%8F-%EC%9B%B9%EC%84%9C%EB%B2%84-%EA%B5%AC%EC%B6%95%ED%95%98%EA%B8%B03-MySQL-%EC%84%A4%EC%B9%98?category=732841
Discussion