Registering your ML2 mechanism driver with the Neutron server
Once the driver code is added, the next step is to register the driver with Neutron. In this recipe, we will see how to register the new mechanism driver with Neutron. We will also check whether our mechanism driver has been loaded and initialized successfully as we restart the Neutron server.
Getting ready
The previous recipe is the prerequisite for this recipe. The basic ML2 driver code is required to be placed at the location mentioned in the previous recipe.
How to do it…
With the appropriate credentials, SSH into your DevStack setup.
Open the
/etc/neutron/plugins/ml2/ml2_conf.ini
configuration file using your desired editor. For example, the command for the vi editor will be as follows:In the
[ml2]
section of the file, configuremechanism_drivers
, as follows:Next, open the
/opt/stack/neutron/neutron.egg-info/entry_points.txt
file using your desired editor. For example, the command for the vi editor will be as follows:In the
[neutron...