[openstack-dev] [quantum] Understanding DHCP Agent

Mark McClain mark.mcclain at dreamhost.com
Fri Oct 26 15:37:50 UTC 2012


Trinath-

The DHCP agent uses both RPC and Notifications.  The general rule is that information originated by the Server flows via notifications and the agent uses RPC to request information from the Quantum server or notify the server of lease renewals. 

In a cold start situation, the agent will:

Make RPC call for active networks (the RPC flow is as your described below)
Start any DHCP services for active networks
Enter Notification Processing Loop
	- Wait for changes to Networks, Subnets, Ports
	- Modify DHCP daemon configs in response to those changes
		(If notification payload does not have enough information use RPC to clarify current state)

Does this clarify how the agent works?

mark

On Oct 26, 2012, at 11:10 AM, Trinath Somanchi <trinath.somanchi at gmail.com> wrote:

> Hi-
> 
> I was trying to understand how the Quantum DHCP agent Daemon works.  As I walk through the code, to understand the working on the Daemon,
> 
> I found it to be using rpc cast and call. But was lost into the code to find the correct data flow.
> 
> In my study I found this:
> 
> 
> 
> 
> quantum/agent/dhcp_agent.py     <--- the actual daemon agent, which makes the rpc.cast/rpc.call to fetch the data.
> 
>            A                  |                  <------ (Flow representing arrows)
>             |                  V
> quantum/db/dhcp_rpc_base.py     <---- which implements the QuantumPluginV2 to process the rpc.cast/rpc.call by the above agent.
> 
>              A                |                   <------ (Flow representing arrows)
>               |                V
> quantum/db/db_base_plugin_v2.py    <--- where the actual DB processing happens for the requests.     
> 
> 
>    
> 
> I have some doubts here, (though there very preliminary)
> 
> [1] The RPC cast and call are sent to the Quantum server ?
> [2] Am I in a right path of understanding the dhcp agent daemon working.
> 
> Kindly please help me understand the processes flow
> 
> Thanks in advance. 
> 
> -- 
> Regards,
> ----------------------------------------------
> Trinath Somanchi,
> +91 9866 235 130
> 
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20121026/8f79605e/attachment.html>


More information about the OpenStack-dev mailing list