Contents

System/OS
2014.04.05 22:34

[linux] resolv.con 초기화 되는 문제

Views 4694 Comment 0
?

Shortcut

PrevPrev Article

NextNext Article

Larger Font Smaller Font Up Down Go comment Print
?

Shortcut

PrevPrev Article

NextNext Article

Larger Font Smaller Font Up Down Go comment Print
network를 재시작하면, resolv.conf가 자동 초기화 되는 현상을 겪었다.
그러던중 아래와 같은 원인과 해결책을 찾았다.

리눅스에서 DNS 설정을 바꾸려고 아래 파일을 수정한다.
/etc/resolv.conf
그리고 아래와 같이 서비스를 재시작 하거나 리부팅한다.
/sbin/service network restart
 
하지만  vmware 상에서는 /etc/resolv.conf 수동설정이 안된다.
DHCP 로 ip 를 자동으로 할당 받을때 /sbin/dhclient-script 에 의해서 resolv.conf 파일이 새로 생성되기 때문이다.
(vi /var/log/boot.log 를 보면 dhclient-script 가 /etc/resolv.conf 를 수정하는 것을 알수 있다.)
 
이 문제를 해결하기 위해서 /sbin/dhclient-script 가 /etc/resolv.conf 를 수정하지 못하도록 파일 속성을 불변으로 바꾼다.
chattr +i /etc/resolv.conf


[참고] 아래와 같은 경고가 나온다면 참고..
Bringing up interface eth0: Determining if ip address 121.78.127.197 is already in use for device eth0...
[해결방법] https://www.hooni.net/xe/39012

?

List of Articles
No. Category Subject Author Date Views
885 Develop [ios] iOS 의 인앱구매 소개 file hooni 2014.04.29 3895
884 Develop [js] Array.splice() 설명 hooni 2014.04.24 3060
883 Develop [ios] 아이폰에서 진동(Vibrate) 기능 추가하기 hooni 2014.04.18 3530
882 Develop [ios] iOS 사운드 관련 프레임워크 hooni 2014.04.18 3071
881 Develop [ios] Sprite Kit & 사운드 재생시 백그라운드 진입시 앱이 비정상적으로 종료됨 hooni 2014.04.18 3432
880 Develop [ios] DatePicker iOS 6.x 이하 디자인. file hooni 2014.04.10 4121
879 Develop [ios] UIWebView 캐쉬 삭제 hooni 2014.04.08 3705
878 Develop [ios] UITableView 특정 Row만 Update hooni 2014.04.08 4840
» System/OS [linux] resolv.con 초기화 되는 문제 hooni 2014.04.05 4694
876 System/OS [linux] CentOS 6.5 에서 "Bringing up interface eth0: Determining if ip address 121.78.127.197 is already in use for device eth0..." hooni 2014.04.05 4961
875 Develop [ios] CoreData 사용하기 (튜토리얼) hooni 2014.03.28 3231
874 Develop [ios] SQLite 사용하기(튜토리얼) + 샘플코드 file hooni 2014.03.28 3749
Board Pagination Prev 1 ... 20 21 22 23 24 25 26 27 28 29 ... 98 Next
/ 98