Change database for migrating hosts
Below is our current database schema:
In this structure, it is impossible to recognize which Kea daemon holds a specific IP or hostname reservation. So, we don't know on which Kea daemon perform the migration.
I want to make the below changes:
- Replace the
ip_reservation
table's reference tohost
table with reference tolocal_host
. - Move the
hostname
column fromhost
tolocal_host
table - (Optionally) Add a single-column primary key to the
local_host
table and add a unique index on thehost_id
,data_source
, anddaemon_id
to preserve the existing constraints.