lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] How can I get a DNS Server IP automatically


From: David Empson
Subject: Re: [lwip-users] How can I get a DNS Server IP automatically
Date: Thu, 13 Nov 2008 11:17:46 +1300

HuangZhenhua address@hidden wrote:
> Another question, What is the difference between DHCP and AutoIP?
 
DHCP involves a server supplying the client with an IP address, subnet mask, gateway and other configuration parameters (e.g. DNS is almost always supplied). The client may supply an identification string. The server is responsible for picking the appropriate IP address, which it might do by allocating from a pool of available addresses, or assigning a fixed address based on the client's ID or MAC address.
 
AutoIP (also known as APIPA for "Automatic Private IP Addressing") is a mechanism where a device assigns itself a random IP address from a particular range reserved for AutoIP (169.254.0.0/16). No server is involved.The subnet mask used is always 255.255.0.0, there is no gateway, and it doesn't have any other configuration parameters such as DNS.
 
After picking a random AutoIP address, the device polls the network to check whether that address is already in use by something else. If it is, then the device picks another random IP address and tries again.
 
AutoIP is often used in ad hoc networks which are temporarily set up between two or more devices, e.g. you could use it when you plug a laptop into an embedded device via a direct Ethernet cable. If both devices use AutoIP then they will be able to talk to each other. Actually finding each other may require something like sending a broadcast ping, or using a name-based service advertising and discovery protocol like SLP, NetBIOS or Apple's Bonjour (multicast DNS, with DNS service discovery).
 
 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]