-
DNSMasq 로 로컬 DNS서버 설정카테고리 없음 2014. 10. 8. 18:59
맥에 DNSMasq설치하고 설정하는 것을 설명합니다.
[용어]
- DNSMasq
- 소규모 네트워크를 위한 DNS, TFTP, DHCP 등의 서버스를 제공하는 경량 서버.
- 문서: http://www.thekelleys.org.uk/dnsmasq/doc.html
- Homebrew
- OS X용 패키지 관리자.
- 설명: http://brew.sh/index_ko.html
- 설치: http://tedcafe.tistory.com/142
_______________________________________________
[DNSMasq 설치]
- 설치 참고문서: http://blog.philippklaus.de/2012/02/install-dnsmasq-locally-on-mac-os-x-via-homebrew/
- 설정 파일 참고: http://blogging.dragon.org.uk/howto-setup-dnsmasq-as-dns-dhcp/
$ brew install dnsmasq
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/dnsmasq-2.72.mavericks.bottle.tar.gz
######################################################################## 100.0%
==> Pouring dnsmasq-2.72.mavericks.bottle.tar.gz
==> Caveats
To configure dnsmasq, copy the example configuration to /usr/local/etc/dnsmasq.conf
and edit to taste.
cp /usr/local/opt/dnsmasq/dnsmasq.conf.example /usr/local/etc/dnsmasq.conf
To have launchd start dnsmasq at startup:
sudo cp -fv /usr/local/opt/dnsmasq/*.plist /Library/LaunchDaemons
Then to load dnsmasq now:
sudo launchctl load /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist
==> Summary
[환경설정 복사]
cp /usr/local/Cellar/dnsmasq/2.57/dnsmasq.conf.example /usr/local/etc/dnsmasq.conf
기본적으로 /etc/hosts파일을 이용한다.
[런처데몬용 설정]
런처데몬 설정파일 복사
sudo cp /usr/local/Cellar/dnsmasq/2.72/homebrew.mxcl.dnsmasq.plist /Library/LaunchDaemons/
데몬 설정파일 로드
sudo launchctl load -w /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist
데몬 시작
sudo launchctl start homebrew.mxcl.dnsmasq
데목 중지
sudo launchctl stop homebrew.mxcl.dnsmasq
반응형