dhcpcd/ko

From Gentoo Wiki
Jump to:navigation Jump to:search
This page is a translated version of the page Dhcpcd and the translation is 50% complete.
Outdated translations are marked like this.
Resources

동적 호스트 설정 프로토콜 클라이언트 데몬(Dynamic Host Configuration Protocol Client Daemon) (dhcpcd)은 젠투 리눅스에서 널리 사용하는 DHCP 클라이언트입니다. IPv4 설정과 IPv6 설정을 다 다루는 기능이 있습니다.

설치

USE 플래그

USE flags for net-misc/dhcpcd A fully featured, yet light weight RFC2131 compliant DHCP client

debug Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
embedded Embed the definitions of dhcp options in the dhcpcd executable
ipv6 Add support for IP version 6
privsep Enable support for privilege separation
udev Enable virtual/udev integration (device discovery, power and storage device support, etc)

Emerge

dhcpcd를 설치하려면 다음 명령을 사용하십시오:

root #emerge --ask net-misc/dhcpcd

설정

파일

모든 dhcpcd 설정은 /etc/dhcpcd.conf 파일에 들어가지만, 최근에는 DHCP 서버가 동작하는 라우터 또는 액세스 포인트에 대부분의 컴퓨터가 붙어있다는 점을 특별히 미리 간주하여 대부분의 설치 상태 그대로인 상황에서 dhcpcd가 동작합니다. man 5 dhcpcd.conf[1] 명령은 고급 설정 과정이 필요한 경우에 도움을 줄 수 있습니다.

정적 IP 주소

이 경우 네트워크 인터페이스 카드는 정적 IP 주소로 설정해야하며, /etc/dhcpcd.conf에 데이터를 추가해야합니다.[1] 다음은 원하는 편집기를 사용하여 DHCPCD 설정 파일에 직접 정적 주소, 라우팅 주소, DNS 주소를 추가해 넣는 예제입니다:

파일 /etc/dhcpcd.conf
static ip_address=192.168.0.10/24
static routers=192.168.0.1
static domain_name_servers=192.168.0.1

IPv6 Prefix Request

파일 /etc/dhcpcd.confRequest a prefix for eth0.lan to be routed publicly with eth0.wan.
# Disable router solicitations for all interfaces, enable only for selected ones
noipv6rs
 
# Interface configuration for the ''wan'' vlan on the ''eth0'' interface
interface eth0.wan
  # Enable router solicitation for this interface
  ipv6rs
  # Request a normal address usins ''iaid'' 1 for interface ''eth0.wan''
  ia_na 1
  # Request a prefix using ''iaid'' 2 and assign it to the ''eth0.lan'' interface using ''sla_id'' 0
  ia_pd 2 eth0.lan/0

사용법

실행

root #dhcpcd --help
usage: dhcpcd   [-46ABbDdEGgHJKkLnpqTVw]                                                                             
                [-C, --nohook hook] [-c, --script script]                                                            
                [-e, --env value] [-F, --fqdn FQDN] [-f, --config file]                                              
                [-h, --hostname hostname] [-I, --clientid clientid]                                                  
                [-i, --vendorclassid vendorclassid] [-l, --leasetime seconds]                                        
                [-m, --metric metric] [-O, --nooption option]                                                        
                [-o, --option option] [-Q, --require option]                                                         
                [-r, --request address] [-S, --static value]                                                         
                [-s, --inform address[/cidr]] [-t, --timeout seconds]                                                
                [-u, --userclass class] [-v, --vendor code, value]                                                   
                [-W, --whitelist address[/cidr]] [-y, --reboot seconds]                                              
                [-X, --blacklist address[/cidr]] [-Z, --denyinterfaces pattern]                                      
                [-z, --allowinterfaces pattern] [interface] [...]                                                    
       dhcpcd   -k, --release [interface]                                                                            
       dhcpcd   -U, --dumplease interface                                                                            
       dhcpcd   --version                                                                                            
       dhcpcd   -x, --exit [interface]  

서비스로 실행

DHCPCD로 네트워크 관리하기를 참고하십시오.

1회용 DHCP

네트워크 인터페이스에 1회용 DHCP를 설정하려면 다음 명령을 실행하십시오:

root #dhcpcd eth0

위 명령의 eth0을 적당한 네트워크 인터페이스 이름으로 바꾸었는지 확인하십시오.

Renew a lease

To renew the lease on eth0, --rebind or -n can be used:

root #dhcpcd -n eth0

Release a lease

To release a lease on eth0, --release or -k can be used:

root #dhcpcd -k eth0

Troubleshooting

추가 참조

외부 자료

참고 자료

  1. 1.0 1.1 Roy Marples. DHCPCD.CONF(5), Roy Marples's personal blog, March 9th, 2015. Retrieved on May 07th, 2015.