You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ap...@apache.org on 2013/04/04 07:51:00 UTC
git commit: updated refs/heads/4.1 to f1c7f40
Updated Branches:
refs/heads/4.1 489010123 -> f1c7f4022
bug CLOUDSTACK-1842: adding the missing os type in upgrade script
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
Branch: refs/heads/4.1
Commit: f1c7f4022a406098ad23424d381d924f185ba456
Parents: 4890101
Author: Abhinandan Prateek <ap...@apache.org>
Authored: Thu Apr 4 11:15:59 2013 +0530
Committer: Abhinandan Prateek <ap...@apache.org>
Committed: Thu Apr 4 11:15:59 2013 +0530
----------------------------------------------------------------------
setup/db/db/schema-40to410.sql | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db/db/schema-40to410.sql
----------------------------------------------------------------------
diff --git a/setup/db/db/schema-40to410.sql b/setup/db/db/schema-40to410.sql
index 5fe7127..8c70c6a 100644
--- a/setup/db/db/schema-40to410.sql
+++ b/setup/db/db/schema-40to410.sql
@@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Network', 'DEFAULT', 'manage
INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT', 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic going into specified list of zones is not metered');
INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT', 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL', 'Traffic going into specified list of zones is metered. For metering all traffic leave this parameter empty');
+
+
+INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
+INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Rohit Yadav <ro...@citrix.com>.
On Thu, Apr 4, 2013 at 9:47 PM, Abhinandan Prateek <
Abhinandan.Prateek@citrix.com> wrote:
> I was wondering that during a clean install the template.sql inserts these
> os types in DB and then runs the upgrade from 40 to 410.
> Since I added these os types in 40-410 it throws duplicate key exception.
>
> I guess to fix this we need to remove this os type from the template
> instead of 40 to 410 upgrade script.
>
Yes, this would work. The way we should upgrade from now on is that we
freeze the create-schema and template.sql as it was for 4.0 and our
upgrade paths should add/remove any type/column.
Cheers.
>
> Rohit, since you restructured the upgrades, can you comment ?
>
> -abhi
>
>
>
>
> On 04/04/13 7:27 PM, "Chip Childers" <ch...@sungard.com> wrote:
>
> >Abhi,
> >
> >Can you please review? This is now a blocker.
> >
> >On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
> >>
> >>
> >> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
> >>
> >>> Updated Branches:
> >>> refs/heads/4.1 489010123 -> f1c7f4022
> >>>
> >>>
> >>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
> >>>
> >>>
> >>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
> >>> Commit:
> >>>http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
> >>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
> >>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
> >>>
> >>> Branch: refs/heads/4.1
> >>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
> >>> Parents: 4890101
> >>> Author: Abhinandan Prateek<ap...@apache.org>
> >>> Authored: Thu Apr 4 11:15:59 2013 +0530
> >>> Committer: Abhinandan Prateek<ap...@apache.org>
> >>> Committed: Thu Apr 4 11:15:59 2013 +0530
> >>>
> >>> ----------------------------------------------------------------------
> >>> setup/db/db/schema-40to410.sql | 4 ++++
> >>> 1 files changed, 4 insertions(+), 0 deletions(-)
> >>> ----------------------------------------------------------------------
> >>>
> >>>
> >>>
> >>>
> >>>
> http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db
> >>>/db/schema-40to410.sql
> >>> ----------------------------------------------------------------------
> >>> diff --git a/setup/db/db/schema-40to410.sql
> >>> b/setup/db/db/schema-40to410.sql
> >>> index 5fe7127..8c70c6a 100644
> >>> --- a/setup/db/db/schema-40to410.sql
> >>> +++ b/setup/db/db/schema-40to410.sql
> >>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
> >>> ('Network', 'DEFAULT', 'manage
> >>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
> >>>'DEFAULT',
> >>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic
> >>>going
> >>> into specified list of zones is not metered');
> >>>
> >>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
> >>>'DEFAULT',
> >>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL',
> >>>'Traffic
> >>> going into specified list of zones is metered. For metering all traffic
> >>> leave this parameter empty');
> >>> +
> >>> +
> >>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
> >>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
> >>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
> >>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
> >>
> >>
> >> Seems have introduce a bug.
> >>
> >> With a fresh install of CS4.1 on CentOS (6.4), first startp of
> >> cloud-management service doesn't works.
> >>
> >> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
> >>
> >> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
> >> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
> >> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
> >> ERROR [utils.db.ScriptRunner] (Timer-1:)
> >>
> >>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExceptio
> >>n:
> >> Duplicate entry '163' for key 'PRIMARY'
> >> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to
> >>execute
> >> upgrade script:
> >>/usr/share/cloudstack-management/setup/db/schema-40to410.sql
> >>
> >>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExceptio
> >>n:
> >> Duplicate entry '163' for key 'PRIMARY'
> >> at
> >>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
> >> at
> >>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
> >> at
> >>
> >>com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker
> >>.java:173)
> >> at
> >>
> >>com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.j
> >>ava:233)
> >> at
> >>
> >>com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.jav
> >>a:358)
> >> at
> >>
> >>com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(Compon
> >>entContext.java:90)
> >> at
> >> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
> >> at java.util.TimerThread.mainLoop(Timer.java:534)
> >> at java.util.TimerThread.run(Timer.java:484)
> >> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity
> >>check
> >> failed. Refuse to startup
> >>
> >>
> >> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04
> >>32/64)
> >> are already exists.
> >>
> >>
> >> Milamber
> >>
> >>
> >>>
> >>>
> >>
> >>
>
>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Abhinandan Prateek <Ab...@citrix.com>.
On 04/04/13 9:51 PM, "Chip Childers" <ch...@sungard.com> wrote:
>On Thu, Apr 04, 2013 at 04:17:26PM +0000, Abhinandan Prateek wrote:
>> I was wondering that during a clean install the template.sql inserts
>>these
>> os types in DB and then runs the upgrade from 40 to 410.
>> Since I added these os types in 40-410 it throws duplicate key
>>exception.
>>
>> I guess to fix this we need to remove this os type from the template
>> instead of 40 to 410 upgrade script.
>>
>> Rohit, since you restructured the upgrades, can you comment ?
>
>Hmm... this is an odd situation to have to work through.
>
>How about using "INSERT IGNORE" in the upgrade script? That should
>work.
Yes this will work, I think that is what I should have used in the first
place.
>
>>
>> -abhi
>>
>>
>>
>>
>> On 04/04/13 7:27 PM, "Chip Childers" <ch...@sungard.com> wrote:
>>
>> >Abhi,
>> >
>> >Can you please review? This is now a blocker.
>> >
>> >On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
>> >>
>> >>
>> >> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
>> >>
>> >>> Updated Branches:
>> >>> refs/heads/4.1 489010123 -> f1c7f4022
>> >>>
>> >>>
>> >>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>> >>>
>> >>>
>> >>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
>> >>> Commit:
>> >>>http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
>> >>> Tree:
>>http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
>> >>> Diff:
>>http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>> >>>
>> >>> Branch: refs/heads/4.1
>> >>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
>> >>> Parents: 4890101
>> >>> Author: Abhinandan Prateek<ap...@apache.org>
>> >>> Authored: Thu Apr 4 11:15:59 2013 +0530
>> >>> Committer: Abhinandan Prateek<ap...@apache.org>
>> >>> Committed: Thu Apr 4 11:15:59 2013 +0530
>> >>>
>> >>>
>>----------------------------------------------------------------------
>> >>> setup/db/db/schema-40to410.sql | 4 ++++
>> >>> 1 files changed, 4 insertions(+), 0 deletions(-)
>> >>>
>>----------------------------------------------------------------------
>> >>>
>> >>>
>> >>>
>> >>>
>>
>>>>>http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/
>>>>>db
>> >>>/db/schema-40to410.sql
>> >>>
>>----------------------------------------------------------------------
>> >>> diff --git a/setup/db/db/schema-40to410.sql
>> >>> b/setup/db/db/schema-40to410.sql
>> >>> index 5fe7127..8c70c6a 100644
>> >>> --- a/setup/db/db/schema-40to410.sql
>> >>> +++ b/setup/db/db/schema-40to410.sql
>> >>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration`
>>VALUES
>> >>> ('Network', 'DEFAULT', 'manage
>> >>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
>> >>>'DEFAULT',
>> >>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic
>> >>>going
>> >>> into specified list of zones is not metered');
>> >>>
>> >>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
>> >>>'DEFAULT',
>> >>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL',
>> >>>'Traffic
>> >>> going into specified list of zones is metered. For metering all
>>traffic
>> >>> leave this parameter empty');
>> >>> +
>> >>> +
>> >>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id,
>>display_name)
>> >>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
>> >>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id,
>>display_name)
>> >>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
>> >>
>> >>
>> >> Seems have introduce a bug.
>> >>
>> >> With a fresh install of CS4.1 on CentOS (6.4), first startp of
>> >> cloud-management service doesn't works.
>> >>
>> >> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
>> >>
>> >> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
>> >> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
>> >> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
>> >> ERROR [utils.db.ScriptRunner] (Timer-1:)
>> >>
>>
>>>>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExcept
>>>>io
>> >>n:
>> >> Duplicate entry '163' for key 'PRIMARY'
>> >> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to
>> >>execute
>> >> upgrade script:
>> >>/usr/share/cloudstack-management/setup/db/schema-40to410.sql
>> >>
>>
>>>>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExcept
>>>>io
>> >>n:
>> >> Duplicate entry '163' for key 'PRIMARY'
>> >> at
>> >>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
>> >> at
>> >>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>> >> at
>> >>
>>
>>>>com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeCheck
>>>>er
>> >>.java:173)
>> >> at
>> >>
>>
>>>>com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker
>>>>.j
>> >>ava:233)
>> >> at
>> >>
>>
>>>>com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.j
>>>>av
>> >>a:358)
>> >> at
>> >>
>>
>>>>com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(Comp
>>>>on
>> >>entContext.java:90)
>> >> at
>> >>
>>com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
>> >> at java.util.TimerThread.mainLoop(Timer.java:534)
>> >> at java.util.TimerThread.run(Timer.java:484)
>> >> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity
>> >>check
>> >> failed. Refuse to startup
>> >>
>> >>
>> >> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04
>> >>32/64)
>> >> are already exists.
>> >>
>> >>
>> >> Milamber
>> >>
>> >>
>> >>>
>> >>>
>> >>
>> >>
>>
>>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Chip Childers <ch...@sungard.com>.
On Thu, Apr 04, 2013 at 04:17:26PM +0000, Abhinandan Prateek wrote:
> I was wondering that during a clean install the template.sql inserts these
> os types in DB and then runs the upgrade from 40 to 410.
> Since I added these os types in 40-410 it throws duplicate key exception.
>
> I guess to fix this we need to remove this os type from the template
> instead of 40 to 410 upgrade script.
>
> Rohit, since you restructured the upgrades, can you comment ?
Hmm... this is an odd situation to have to work through.
How about using "INSERT IGNORE" in the upgrade script? That should
work.
>
> -abhi
>
>
>
>
> On 04/04/13 7:27 PM, "Chip Childers" <ch...@sungard.com> wrote:
>
> >Abhi,
> >
> >Can you please review? This is now a blocker.
> >
> >On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
> >>
> >>
> >> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
> >>
> >>> Updated Branches:
> >>> refs/heads/4.1 489010123 -> f1c7f4022
> >>>
> >>>
> >>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
> >>>
> >>>
> >>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
> >>> Commit:
> >>>http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
> >>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
> >>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
> >>>
> >>> Branch: refs/heads/4.1
> >>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
> >>> Parents: 4890101
> >>> Author: Abhinandan Prateek<ap...@apache.org>
> >>> Authored: Thu Apr 4 11:15:59 2013 +0530
> >>> Committer: Abhinandan Prateek<ap...@apache.org>
> >>> Committed: Thu Apr 4 11:15:59 2013 +0530
> >>>
> >>> ----------------------------------------------------------------------
> >>> setup/db/db/schema-40to410.sql | 4 ++++
> >>> 1 files changed, 4 insertions(+), 0 deletions(-)
> >>> ----------------------------------------------------------------------
> >>>
> >>>
> >>>
> >>>
> >>>http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db
> >>>/db/schema-40to410.sql
> >>> ----------------------------------------------------------------------
> >>> diff --git a/setup/db/db/schema-40to410.sql
> >>> b/setup/db/db/schema-40to410.sql
> >>> index 5fe7127..8c70c6a 100644
> >>> --- a/setup/db/db/schema-40to410.sql
> >>> +++ b/setup/db/db/schema-40to410.sql
> >>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
> >>> ('Network', 'DEFAULT', 'manage
> >>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
> >>>'DEFAULT',
> >>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic
> >>>going
> >>> into specified list of zones is not metered');
> >>>
> >>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
> >>>'DEFAULT',
> >>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL',
> >>>'Traffic
> >>> going into specified list of zones is metered. For metering all traffic
> >>> leave this parameter empty');
> >>> +
> >>> +
> >>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
> >>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
> >>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
> >>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
> >>
> >>
> >> Seems have introduce a bug.
> >>
> >> With a fresh install of CS4.1 on CentOS (6.4), first startp of
> >> cloud-management service doesn't works.
> >>
> >> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
> >>
> >> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
> >> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
> >> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
> >> ERROR [utils.db.ScriptRunner] (Timer-1:)
> >>
> >>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExceptio
> >>n:
> >> Duplicate entry '163' for key 'PRIMARY'
> >> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to
> >>execute
> >> upgrade script:
> >>/usr/share/cloudstack-management/setup/db/schema-40to410.sql
> >>
> >>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExceptio
> >>n:
> >> Duplicate entry '163' for key 'PRIMARY'
> >> at
> >>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
> >> at
> >>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
> >> at
> >>
> >>com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker
> >>.java:173)
> >> at
> >>
> >>com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.j
> >>ava:233)
> >> at
> >>
> >>com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.jav
> >>a:358)
> >> at
> >>
> >>com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(Compon
> >>entContext.java:90)
> >> at
> >> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
> >> at java.util.TimerThread.mainLoop(Timer.java:534)
> >> at java.util.TimerThread.run(Timer.java:484)
> >> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity
> >>check
> >> failed. Refuse to startup
> >>
> >>
> >> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04
> >>32/64)
> >> are already exists.
> >>
> >>
> >> Milamber
> >>
> >>
> >>>
> >>>
> >>
> >>
>
>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Abhinandan Prateek <Ab...@citrix.com>.
Yes, I will take a look.
On 04-Apr-2013, at 7:27 PM, "Chip Childers" <ch...@sungard.com> wrote:
> Abhi,
>
> Can you please review? This is now a blocker.
>
> On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
>>
>>
>> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
>>
>>> Updated Branches:
>>> refs/heads/4.1 489010123 -> f1c7f4022
>>>
>>>
>>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>>>
>>>
>>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
>>> Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
>>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
>>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>>>
>>> Branch: refs/heads/4.1
>>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
>>> Parents: 4890101
>>> Author: Abhinandan Prateek<ap...@apache.org>
>>> Authored: Thu Apr 4 11:15:59 2013 +0530
>>> Committer: Abhinandan Prateek<ap...@apache.org>
>>> Committed: Thu Apr 4 11:15:59 2013 +0530
>>>
>>> ----------------------------------------------------------------------
>>> setup/db/db/schema-40to410.sql | 4 ++++
>>> 1 files changed, 4 insertions(+), 0 deletions(-)
>>> ----------------------------------------------------------------------
>>>
>>>
>>>
>>> http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db/db/schema-40to410.sql
>>> ----------------------------------------------------------------------
>>> diff --git a/setup/db/db/schema-40to410.sql
>>> b/setup/db/db/schema-40to410.sql
>>> index 5fe7127..8c70c6a 100644
>>> --- a/setup/db/db/schema-40to410.sql
>>> +++ b/setup/db/db/schema-40to410.sql
>>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
>>> ('Network', 'DEFAULT', 'manage
>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic going
>>> into specified list of zones is not metered');
>>>
>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL', 'Traffic
>>> going into specified list of zones is metered. For metering all traffic
>>> leave this parameter empty');
>>> +
>>> +
>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
>>
>>
>> Seems have introduce a bug.
>>
>> With a fresh install of CS4.1 on CentOS (6.4), first startp of
>> cloud-management service doesn't works.
>>
>> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
>>
>> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
>> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
>> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
>> ERROR [utils.db.ScriptRunner] (Timer-1:)
>> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
>> Duplicate entry '163' for key 'PRIMARY'
>> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to execute
>> upgrade script: /usr/share/cloudstack-management/setup/db/schema-40to410.sql
>> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
>> Duplicate entry '163' for key 'PRIMARY'
>> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
>> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>> at
>> com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:173)
>> at
>> com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:233)
>> at
>> com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:358)
>> at
>> com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(ComponentContext.java:90)
>> at
>> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
>> at java.util.TimerThread.mainLoop(Timer.java:534)
>> at java.util.TimerThread.run(Timer.java:484)
>> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity check
>> failed. Refuse to startup
>>
>>
>> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04 32/64)
>> are already exists.
>>
>>
>> Milamber
>>
>>
>>
>>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Chip Childers <ch...@sungard.com>.
On Thu, Apr 04, 2013 at 04:17:26PM +0000, Abhinandan Prateek wrote:
> I was wondering that during a clean install the template.sql inserts these
> os types in DB and then runs the upgrade from 40 to 410.
> Since I added these os types in 40-410 it throws duplicate key exception.
>
> I guess to fix this we need to remove this os type from the template
> instead of 40 to 410 upgrade script.
>
> Rohit, since you restructured the upgrades, can you comment ?
>
> -abhi
Actually, yes, insert ignore should work. Here's how it behaves:
mysql> desc foo;
+-------+---------------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+-------+---------------------+------+-----+---------+----------------+
| id | bigint(20) unsigned | NO | PRI | NULL | auto_increment |
| u | int(11) | YES | UNI | NULL | |
+-------+---------------------+------+-----+---------+----------------+
2 rows in set (0.00 sec)
mysql> insert into foo (id, u) values (3, 3);
Query OK, 1 row affected (0.00 sec)
mysql> select * from foo;
+----+------+
| id | u |
+----+------+
| 3 | 3 |
+----+------+
1 row in set (0.00 sec)
mysql> insert into foo (id, u) values (3, 3);
ERROR 1062 (23000): Duplicate entry '3' for key 'PRIMARY'
mysql> insert ignore into foo (id, u) values (3, 4);
Query OK, 0 rows affected (0.00 sec)
mysql> select * from foo;
+----+------+
| id | u |
+----+------+
| 3 | 3 |
+----+------+
1 row in set (0.00 sec)
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Abhinandan Prateek <Ab...@citrix.com>.
Chip,
Thanks for reverting.
-Abhi
On 04-Apr-2013, at 7:30 PM, "Chip Childers" <ch...@sungard.com> wrote:
> I've reverted that commit from 4.1.
>
> Abhi, please correct the change and commit to master. Please then
> provide either a Patch Request email for me to cherry-pick over to the
> 4.1 branch, or submit a reviewboard entry for me to apply to 4.1.
>
> Thanks!
>
> On Thu, Apr 4, 2013 at 9:56 AM, Chip Childers <ch...@sungard.com> wrote:
>> Abhi,
>>
>> Can you please review? This is now a blocker.
>>
>> On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
>>>
>>>
>>> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
>>>
>>>> Updated Branches:
>>>> refs/heads/4.1 489010123 -> f1c7f4022
>>>>
>>>>
>>>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>>>>
>>>>
>>>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
>>>> Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
>>>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
>>>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>>>>
>>>> Branch: refs/heads/4.1
>>>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
>>>> Parents: 4890101
>>>> Author: Abhinandan Prateek<ap...@apache.org>
>>>> Authored: Thu Apr 4 11:15:59 2013 +0530
>>>> Committer: Abhinandan Prateek<ap...@apache.org>
>>>> Committed: Thu Apr 4 11:15:59 2013 +0530
>>>>
>>>> ----------------------------------------------------------------------
>>>> setup/db/db/schema-40to410.sql | 4 ++++
>>>> 1 files changed, 4 insertions(+), 0 deletions(-)
>>>> ----------------------------------------------------------------------
>>>>
>>>>
>>>>
>>>> http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db/db/schema-40to410.sql
>>>> ----------------------------------------------------------------------
>>>> diff --git a/setup/db/db/schema-40to410.sql
>>>> b/setup/db/db/schema-40to410.sql
>>>> index 5fe7127..8c70c6a 100644
>>>> --- a/setup/db/db/schema-40to410.sql
>>>> +++ b/setup/db/db/schema-40to410.sql
>>>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
>>>> ('Network', 'DEFAULT', 'manage
>>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>>>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic going
>>>> into specified list of zones is not metered');
>>>>
>>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>>>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL', 'Traffic
>>>> going into specified list of zones is metered. For metering all traffic
>>>> leave this parameter empty');
>>>> +
>>>> +
>>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
>>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
>>>
>>>
>>> Seems have introduce a bug.
>>>
>>> With a fresh install of CS4.1 on CentOS (6.4), first startp of
>>> cloud-management service doesn't works.
>>>
>>> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
>>>
>>> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
>>> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
>>> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
>>> ERROR [utils.db.ScriptRunner] (Timer-1:)
>>> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
>>> Duplicate entry '163' for key 'PRIMARY'
>>> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to execute
>>> upgrade script: /usr/share/cloudstack-management/setup/db/schema-40to410.sql
>>> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
>>> Duplicate entry '163' for key 'PRIMARY'
>>> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
>>> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>>> at
>>> com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:173)
>>> at
>>> com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:233)
>>> at
>>> com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:358)
>>> at
>>> com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(ComponentContext.java:90)
>>> at
>>> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
>>> at java.util.TimerThread.mainLoop(Timer.java:534)
>>> at java.util.TimerThread.run(Timer.java:484)
>>> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity check
>>> failed. Refuse to startup
>>>
>>>
>>> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04 32/64)
>>> are already exists.
>>>
>>>
>>> Milamber
>>>
>>>
>>>
>>>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Chip Childers <ch...@sungard.com>.
I've reverted that commit from 4.1.
Abhi, please correct the change and commit to master. Please then
provide either a Patch Request email for me to cherry-pick over to the
4.1 branch, or submit a reviewboard entry for me to apply to 4.1.
Thanks!
On Thu, Apr 4, 2013 at 9:56 AM, Chip Childers <ch...@sungard.com> wrote:
> Abhi,
>
> Can you please review? This is now a blocker.
>
> On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
>>
>>
>> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
>>
>>> Updated Branches:
>>> refs/heads/4.1 489010123 -> f1c7f4022
>>>
>>>
>>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>>>
>>>
>>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
>>> Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
>>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
>>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>>>
>>> Branch: refs/heads/4.1
>>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
>>> Parents: 4890101
>>> Author: Abhinandan Prateek<ap...@apache.org>
>>> Authored: Thu Apr 4 11:15:59 2013 +0530
>>> Committer: Abhinandan Prateek<ap...@apache.org>
>>> Committed: Thu Apr 4 11:15:59 2013 +0530
>>>
>>> ----------------------------------------------------------------------
>>> setup/db/db/schema-40to410.sql | 4 ++++
>>> 1 files changed, 4 insertions(+), 0 deletions(-)
>>> ----------------------------------------------------------------------
>>>
>>>
>>>
>>> http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db/db/schema-40to410.sql
>>> ----------------------------------------------------------------------
>>> diff --git a/setup/db/db/schema-40to410.sql
>>> b/setup/db/db/schema-40to410.sql
>>> index 5fe7127..8c70c6a 100644
>>> --- a/setup/db/db/schema-40to410.sql
>>> +++ b/setup/db/db/schema-40to410.sql
>>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
>>> ('Network', 'DEFAULT', 'manage
>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic going
>>> into specified list of zones is not metered');
>>>
>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL', 'Traffic
>>> going into specified list of zones is metered. For metering all traffic
>>> leave this parameter empty');
>>> +
>>> +
>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
>>
>>
>> Seems have introduce a bug.
>>
>> With a fresh install of CS4.1 on CentOS (6.4), first startp of
>> cloud-management service doesn't works.
>>
>> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
>>
>> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
>> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
>> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
>> ERROR [utils.db.ScriptRunner] (Timer-1:)
>> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
>> Duplicate entry '163' for key 'PRIMARY'
>> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to execute
>> upgrade script: /usr/share/cloudstack-management/setup/db/schema-40to410.sql
>> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
>> Duplicate entry '163' for key 'PRIMARY'
>> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
>> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>> at
>> com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:173)
>> at
>> com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:233)
>> at
>> com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:358)
>> at
>> com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(ComponentContext.java:90)
>> at
>> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
>> at java.util.TimerThread.mainLoop(Timer.java:534)
>> at java.util.TimerThread.run(Timer.java:484)
>> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity check
>> failed. Refuse to startup
>>
>>
>> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04 32/64)
>> are already exists.
>>
>>
>> Milamber
>>
>>
>>>
>>>
>>
>>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Abhinandan Prateek <Ab...@citrix.com>.
I was wondering that during a clean install the template.sql inserts these
os types in DB and then runs the upgrade from 40 to 410.
Since I added these os types in 40-410 it throws duplicate key exception.
I guess to fix this we need to remove this os type from the template
instead of 40 to 410 upgrade script.
Rohit, since you restructured the upgrades, can you comment ?
-abhi
On 04/04/13 7:27 PM, "Chip Childers" <ch...@sungard.com> wrote:
>Abhi,
>
>Can you please review? This is now a blocker.
>
>On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
>>
>>
>> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
>>
>>> Updated Branches:
>>> refs/heads/4.1 489010123 -> f1c7f4022
>>>
>>>
>>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>>>
>>>
>>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
>>> Commit:
>>>http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
>>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
>>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>>>
>>> Branch: refs/heads/4.1
>>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
>>> Parents: 4890101
>>> Author: Abhinandan Prateek<ap...@apache.org>
>>> Authored: Thu Apr 4 11:15:59 2013 +0530
>>> Committer: Abhinandan Prateek<ap...@apache.org>
>>> Committed: Thu Apr 4 11:15:59 2013 +0530
>>>
>>> ----------------------------------------------------------------------
>>> setup/db/db/schema-40to410.sql | 4 ++++
>>> 1 files changed, 4 insertions(+), 0 deletions(-)
>>> ----------------------------------------------------------------------
>>>
>>>
>>>
>>>
>>>http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db
>>>/db/schema-40to410.sql
>>> ----------------------------------------------------------------------
>>> diff --git a/setup/db/db/schema-40to410.sql
>>> b/setup/db/db/schema-40to410.sql
>>> index 5fe7127..8c70c6a 100644
>>> --- a/setup/db/db/schema-40to410.sql
>>> +++ b/setup/db/db/schema-40to410.sql
>>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
>>> ('Network', 'DEFAULT', 'manage
>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
>>>'DEFAULT',
>>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic
>>>going
>>> into specified list of zones is not metered');
>>>
>>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage',
>>>'DEFAULT',
>>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL',
>>>'Traffic
>>> going into specified list of zones is metered. For metering all traffic
>>> leave this parameter empty');
>>> +
>>> +
>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
>>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
>>
>>
>> Seems have introduce a bug.
>>
>> With a fresh install of CS4.1 on CentOS (6.4), first startp of
>> cloud-management service doesn't works.
>>
>> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
>>
>> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
>> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
>> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
>> ERROR [utils.db.ScriptRunner] (Timer-1:)
>>
>>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExceptio
>>n:
>> Duplicate entry '163' for key 'PRIMARY'
>> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to
>>execute
>> upgrade script:
>>/usr/share/cloudstack-management/setup/db/schema-40to410.sql
>>
>>com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationExceptio
>>n:
>> Duplicate entry '163' for key 'PRIMARY'
>> at
>>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
>> at
>>com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
>> at
>>
>>com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker
>>.java:173)
>> at
>>
>>com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.j
>>ava:233)
>> at
>>
>>com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.jav
>>a:358)
>> at
>>
>>com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(Compon
>>entContext.java:90)
>> at
>> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
>> at java.util.TimerThread.mainLoop(Timer.java:534)
>> at java.util.TimerThread.run(Timer.java:484)
>> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity
>>check
>> failed. Refuse to startup
>>
>>
>> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04
>>32/64)
>> are already exists.
>>
>>
>> Milamber
>>
>>
>>>
>>>
>>
>>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Chip Childers <ch...@sungard.com>.
Abhi,
Can you please review? This is now a blocker.
On Thu, Apr 4, 2013 at 9:25 AM, Milamber <mi...@apache.org> wrote:
>
>
> Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
>
>> Updated Branches:
>> refs/heads/4.1 489010123 -> f1c7f4022
>>
>>
>> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>>
>>
>> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
>> Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
>> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
>> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>>
>> Branch: refs/heads/4.1
>> Commit: f1c7f4022a406098ad23424d381d924f185ba456
>> Parents: 4890101
>> Author: Abhinandan Prateek<ap...@apache.org>
>> Authored: Thu Apr 4 11:15:59 2013 +0530
>> Committer: Abhinandan Prateek<ap...@apache.org>
>> Committed: Thu Apr 4 11:15:59 2013 +0530
>>
>> ----------------------------------------------------------------------
>> setup/db/db/schema-40to410.sql | 4 ++++
>> 1 files changed, 4 insertions(+), 0 deletions(-)
>> ----------------------------------------------------------------------
>>
>>
>>
>> http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db/db/schema-40to410.sql
>> ----------------------------------------------------------------------
>> diff --git a/setup/db/db/schema-40to410.sql
>> b/setup/db/db/schema-40to410.sql
>> index 5fe7127..8c70c6a 100644
>> --- a/setup/db/db/schema-40to410.sql
>> +++ b/setup/db/db/schema-40to410.sql
>> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES
>> ('Network', 'DEFAULT', 'manage
>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>> 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic going
>> into specified list of zones is not metered');
>>
>> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT',
>> 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL', 'Traffic
>> going into specified list of zones is metered. For metering all traffic
>> leave this parameter empty');
>> +
>> +
>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>> VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
>> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name)
>> VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
>
>
> Seems have introduce a bug.
>
> With a fresh install of CS4.1 on CentOS (6.4), first startp of
> cloud-management service doesn't works.
>
> In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
>
> ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
> `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
> UUID(), 10, 'Ubuntu 12.04 (32-bit)')
> ERROR [utils.db.ScriptRunner] (Timer-1:)
> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
> Duplicate entry '163' for key 'PRIMARY'
> ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to execute
> upgrade script: /usr/share/cloudstack-management/setup/db/schema-40to410.sql
> com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
> Duplicate entry '163' for key 'PRIMARY'
> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
> at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
> at
> com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:173)
> at
> com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:233)
> at
> com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:358)
> at
> com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(ComponentContext.java:90)
> at
> com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
> at java.util.TimerThread.mainLoop(Timer.java:534)
> at java.util.TimerThread.run(Timer.java:484)
> ERROR [utils.component.ComponentContext] (Timer-1:) System integrity check
> failed. Refuse to startup
>
>
> Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04 32/64)
> are already exists.
>
>
> Milamber
>
>
>>
>>
>
>
Re: git commit: updated refs/heads/4.1 to f1c7f40
Posted by Milamber <mi...@apache.org>.
Le 04/04/2013 05:51, aprateek@apache.org a ecrit :
> Updated Branches:
> refs/heads/4.1 489010123 -> f1c7f4022
>
>
> bug CLOUDSTACK-1842: adding the missing os type in upgrade script
>
>
> Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
> Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/f1c7f402
> Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/f1c7f402
> Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/f1c7f402
>
> Branch: refs/heads/4.1
> Commit: f1c7f4022a406098ad23424d381d924f185ba456
> Parents: 4890101
> Author: Abhinandan Prateek<ap...@apache.org>
> Authored: Thu Apr 4 11:15:59 2013 +0530
> Committer: Abhinandan Prateek<ap...@apache.org>
> Committed: Thu Apr 4 11:15:59 2013 +0530
>
> ----------------------------------------------------------------------
> setup/db/db/schema-40to410.sql | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
> ----------------------------------------------------------------------
>
>
> http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f1c7f402/setup/db/db/schema-40to410.sql
> ----------------------------------------------------------------------
> diff --git a/setup/db/db/schema-40to410.sql b/setup/db/db/schema-40to410.sql
> index 5fe7127..8c70c6a 100644
> --- a/setup/db/db/schema-40to410.sql
> +++ b/setup/db/db/schema-40to410.sql
> @@ -1685,3 +1685,7 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Network', 'DEFAULT', 'manage
> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT', 'management-server', 'traffic.sentinel.exclude.zones' , '', 'Traffic going into specified list of zones is not metered');
>
> INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Usage', 'DEFAULT', 'management-server', 'traffic.sentinel.include.zones' , 'EXTERNAL', 'Traffic going into specified list of zones is metered. For metering all traffic leave this parameter empty');
> +
> +
> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)');
> +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)');
Seems have introduce a bug.
With a fresh install of CS4.1 on CentOS (6.4), first startp of
cloud-management service doesn't works.
In catalina.out, a upgrade DB 4.0 to 4.1 are made and:
ERROR [utils.db.ScriptRunner] (Timer-1:) Error executing: INSERT INTO
`cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163,
UUID(), 10, 'Ubuntu 12.04 (32-bit)')
ERROR [utils.db.ScriptRunner] (Timer-1:)
com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
Duplicate entry '163' for key 'PRIMARY'
ERROR [cloud.upgrade.DatabaseUpgradeChecker] (Timer-1:) Unable to
execute upgrade script:
/usr/share/cloudstack-management/setup/db/schema-40to410.sql
com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
Duplicate entry '163' for key 'PRIMARY'
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:193)
at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
at
com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:173)
at
com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:233)
at
com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:358)
at
com.cloud.utils.component.ComponentContext.initComponentsLifeCycle(ComponentContext.java:90)
at
com.cloud.servlet.CloudStartupServlet$1.run(CloudStartupServlet.java:50)
at java.util.TimerThread.mainLoop(Timer.java:534)
at java.util.TimerThread.run(Timer.java:484)
ERROR [utils.component.ComponentContext] (Timer-1:) System integrity
check failed. Refuse to startup
Inside the cloud database, guest_os with id 163 and 164 (ubuntu 12.04
32/64) are already exists.
Milamber
>
>