If there are unsynced gws in kamailio database
because the db schema was corrupt this rev
should align the existing group_id fields and
remove the orphaned ones.
Thx agranig
It will be executed with no changes on new
deploys and new upgrades since the changes are
already edited in previous revs.
For those ones which already applied the original
revs this one will fix the asyncs but still won't
delete the inconsistent entries delted in
provisioning and still present in kamailio.
That's for another rev.
It's dropped an recreated. That makes the
group_id values are generated with the
default ones and that's not what we have in
provisioning database. The triggers fail as those
fields don't match.
This makes our 2.5 repos future proof as well.
To recap, that's the idea of the postinst file:
* nothing will be automatically executed on existing 2.5 ngcp systems
* nothing will be automatically executed on 2.5->2.6 ngcp upgrades
as soon as package version 2.6.4 (which will provide all the nessary
bugfixes) is available in the 2.6 repos
* if a system is running release 2.6 already then the system already
provides ngcp-db-schema >= 2.6.0 and <= 2.6.3, then the
ngcp-update-db-schema script will be executed automatically
From: Michael Prokop <mprokop@sipwise.com>
The ley that is tried to be created in 9868.up
has no group_id field so it won't be applied in
case you already have two peering groups with
same peering rules. In case you don't it will
apply but the resulting 2.6 version won't allow
you to have different peering groups with same
peering rules.
The solution is what follows: We edit the
existing db scripts to allow upgrades to work
well. This will make existing 2.6 systems and
new 2.6 systems to have different db scehmas.
And the existing ones will be still broken. A new
db rev 10860.up has been created to unify both
kind of systems (the ones which executed the
original revs and the ones which excuted the
edited ones) and it will also fix the existing
versions as it will be executed in existing 2.6
systems via postinst script.
Why postinst script? We can't trust users to
execute update-db-schema as we don't know all
of them. It's better to handle this automatically.
This postinst addition is being handled by Mika
in another commit.
This is supposed to help us getting the broken
/usr/share/ngcp-db-schema/db_scripts/diff/9868.up
script into existing 2.6 systems.
Needs excessive testing, not ready for release *yet*.
From: Michael Prokop <mprokop@sipwise.com>