May I know what are the changes needed in the DHCP message formats if I want to convert into ipv6 environment?

Now I am using ipv4 dhcp client and ipv4 dhcp server. But I want to implement this using ipv6 dhcp client and ipv6 dhcp server. Tell me various places where I need to concentrate to implement or extend my ipv4 functionality to support ipv6 also.


The question of implementing IPv6 is an open-ended question that's really too long to go into in much detail here on this page. But I will attempt to address your question about address autoconfiguration.

First of all, in an IPv6 environment, it may not be required to run DHCP at all - automatic network configuration and address assignment is typically done using stateless autoconfiguration, where the router advertises the prefix used on that particular LAN and (simplifying) the client mashes together the network prefix with the computer's MAC address to configure the network. Router advertisments may also contain DNS information. There is also an IPv6 version of DHCP, but it's not entirely clear if it's going to be useful in your deployment.

Some useful references might be IPv6.com: IPv6 - Auto Configuration vs DHCPv6 by Kaushik Das and the Wikipedia articles on DHCPv6 and the Neighbor Discovery Protocol.

Finally, as a bit of an aside, I notice you seem to think in terms of "converting" your network to IPv6. It's not quite that simple. IPv6 and IPv4 are not interoperable - a machine with IPv4 only has no way of reaching a machine with IPv6 only. As of the time this post was written, the vast majority of services on the internet are accessible using IPv4 only, and there are also a lot of applications you might use that aren't quite ready for IPv6, or you may need to communicate with computers that have only IPv4. Except for specialized applications with no need to communicate with the outside world, an IPv6-only network is not going to be practical. Whatever you do, during the period in which we are going to be transitioning from IPv4 to IPv6, which will probably be many years, you will want to run a "dual stack" deployment, where hosts receive both IPv4 and IPv6 connectivity. IPv6 will be required in addition to, rather than instead of IPv4.