참고 링크
http://misoin.wordpress.com/2012/06/05/redis-%EB%B3%B5%EC%A0%9C-masterslaves/
Redis를 Windows 설치 하기
http://judydba.tistory.com/201
1. 설정 파일 생성
C:\Redis\Config 디렉토리에 redis.conf 파일을 복사하여 redis_master.conf, redis_slave.conf 파일을 생성.
## Redis_master.conf
Port : 7379
Bind : 아이피주소
logfile D:\DB\Redis\log\master_redis.log
dbfilename D:\DB\Redis\dump_master.rdb
-- Security Sectioin
Requirepass의 주석을 해제. 원하는 비밀번호 생성
##. Redis_slave.conf
Port : 8379
Bind : 아이피주소
logfile D:\DB\Redis\log\redis_slave.log
dbfilename D:\DB\Redis\dump_slave.rdb
-- replication section
slaveof 아이피주소 7379
-- master auth
masterauth foobared
-- 주석 제거
repl-ping-slave-period 10
repl-timeout 60
2. 윈도우 서비스 등록
sc create "REDIS_Master" binpath= "c:\Redis\RedisService.exe C:\Redis\Config\redis_master.conf" start= "auto" DisplayName= "REDIS_Master"
sc create "REDIS_Slave" binpath= "c:\Redis\RedisService.exe C:\Redis\Config\redis_slave.conf" start= "auto" DisplayName= "REDIS_Slave"
3. 로그 확인
## master Server
[6624] 07 Jun 16:58:40 # Windows does not support daemonize. Start Redis as service
[6624] 07 Jun 16:58:40 * Server started, Redis version 2.4.5
[6624] 07 Jun 16:58:40 * DB loaded from disk: 0 seconds
[6624] 07 Jun 16:58:40 * The server is now ready to accept connections on port 7379
[6624] 07 Jun 16:58:45 * Slave ask for synchronization
[6624] 07 Jun 16:58:45 * Starting BGSAVE for SYNC
[6624] 07 Jun 16:58:45 * Foregroud saving started by pid 6624
[6624] 07 Jun 16:58:45 * DB saved on disk
[6624] 07 Jun 16:58:45 * Background saving terminated with success
[6624] 07 Jun 16:58:45 * Synchronization with slave succeeded
## Slave Server
[1044] 07 Jun 16:58:45 * The server is now ready to accept connections on port 8379
[1044] 07 Jun 16:58:45 * Connecting to MASTER...
[1044] 07 Jun 16:58:45 * MASTER <-> SLAVE sync started
[1044] 07 Jun 16:58:45 * Non blocking connect for SYNC fired the event.
[1044] 07 Jun 16:58:45 * MASTER <-> SLAVE sync: receiving 10 bytes from master
[1044] 07 Jun 16:58:45 * MASTER <-> SLAVE sync: Loading DB in memory
[1044] 07 Jun 16:58:45 * MASTER <-> SLAVE sync: Finished with success
4. 연결 및 복제 테스트
## master 서버 연결
--a는 패스워드이다. 복제간 테스트 할때 conf 파일에 설정된 정보
## Slave 서버 연결
복제 테스트 완료!!.