Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

fix(db): remove duplicate entries in centreon_acl table #6366

Merged
merged 6 commits into from
Jun 25, 2018

Conversation

sc979
Copy link
Contributor

@sc979 sc979 commented Jun 13, 2018

Removing MUL key with PRI key
Avoiding to launch the patch when customers service already applied it

@sc979 sc979 requested review from loiclau, bouda1 and kduret June 13, 2018 15:12
@sc979 sc979 force-pushed the MON-2723_Update_centAcl_support branch 2 times, most recently from fb2ecf7 to 4f4c0b3 Compare June 13, 2018 15:41
/**
* Retrieving index occurrences and dropping keys
*/
$search_index = 'SHOW INDEX FROM centreon_storage.centreon_acl WHERE Key_name LIKE \'index%\'';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do not use "centreon_storage" name directly. Some people have custom db name.
If you use pearDBO variable, you use storage database, so you don't need to specify it.

/**
* Stopping the cron
*/
shell_exec('sudo service crond stop');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do not stop service in upgrade process.
You have to implement a system to stop temporarily centAcl cron

@sc979 sc979 force-pushed the MON-2723_Update_centAcl_support branch 2 times, most recently from ce3382d to b330aee Compare June 14, 2018 14:29
@sc979 sc979 force-pushed the MON-2723_Update_centAcl_support branch from b330aee to 77988c2 Compare June 15, 2018 16:43
@kduret kduret force-pushed the MON-2723_Update_centAcl_support branch from 0d78379 to e7fdab3 Compare June 19, 2018 14:03
@kduret kduret changed the title fix(DB): upgrade DB to correct a bug fix(db): remove duplicate entries in centreon_acl table Jun 19, 2018
@kduret kduret merged commit 2e795fa into 2.8.x Jun 25, 2018
@kduret kduret deleted the MON-2723_Update_centAcl_support branch June 25, 2018 08:33
kduret pushed a commit that referenced this pull request Jun 25, 2018
* fix(DB): upgrade DB to correct a bug

* fix(DB): centAcl close DB connection before the update is achieved

* fix(acl): Add primary key and handle duplicate entries in centreon_acl

* fix(sql): delete duplicate entries in centreon_acl table

* feat(install): add base version to 2.8.24

* doc(upgrade): add empty release notes for 2.8.24
lpinsivy added a commit that referenced this pull request Nov 26, 2018
Since PR #6366, all values for host are: <host_id>,0 and not <host_id>,NULL
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants