Difference between revisions of "Neutron/DatabaseMigration"
< Neutron
Line 1: | Line 1: | ||
− | = | + | = Neutron Database Migration = |
− | + | When a developer submits a patch to Neutron that changes the database model, | |
− | When a developer submits a patch to | ||
a database migration script is required. | a database migration script is required. | ||
− | * Detail description : https://github.com/openstack/ | + | * Detail description : https://github.com/openstack/neutron/blob/master/neutron/db/migration/README |
== Howto == | == Howto == | ||
− | # | + | # Neutron repo $git checkout master |
# Run devstack (with your plugin) | # Run devstack (with your plugin) | ||
− | + | # Stop neutron services | |
− | # Stop | + | # Neutron repo $git checkout <your feature branch> |
− | # | + | # neutron-db-manage --config-file /etc/neutron/neutron.conf --config-file <plugin.ini> revision -m "Description" --autogenerate |
− | # | + | # Restart Neutron services (if needed) |
− | # Restart | ||
[note] First 20 chars of "Description" is used as a part of a filename of a migration script. | [note] First 20 chars of "Description" is used as a part of a filename of a migration script. |
Revision as of 02:25, 22 August 2013
Neutron Database Migration
When a developer submits a patch to Neutron that changes the database model, a database migration script is required.
- Detail description : https://github.com/openstack/neutron/blob/master/neutron/db/migration/README
Howto
- Neutron repo $git checkout master
- Run devstack (with your plugin)
- Stop neutron services
- Neutron repo $git checkout <your feature branch>
- neutron-db-manage --config-file /etc/neutron/neutron.conf --config-file <plugin.ini> revision -m "Description" --autogenerate
- Restart Neutron services (if needed)
[note] First 20 chars of "Description" is used as a part of a filename of a migration script.