cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-9074) Support shared networking in NiciraNVP Plugin
Date Mon, 07 Dec 2015 14:06:11 GMT

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-9074?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15044991#comment-15044991
] 

ASF GitHub Bot commented on CLOUDSTACK-9074:
--------------------------------------------

Github user serg38 commented on the pull request:

    https://github.com/apache/cloudstack/pull/1094#issuecomment-162532791
  
    This index comes from schema-40to410.sql:
    
    CREATE TABLE `cloud`.`nicira_nvp_router_map` (
    
      `id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
    
      `logicalrouter_uuid` varchar(255) NOT NULL UNIQUE COMMENT 'nicira uuid of logical router',
    
      `network_id` bigint unsigned NOT NULL UNIQUE COMMENT 'cloudstack id of the network',
    
      PRIMARY KEY (`id`),
    
      CONSTRAINT `fk_nicira_nvp_router_map__network_id` FOREIGN KEY (`network_id`) REFERENCES
`networks`(`id`) ON DELETE CASCADE
    
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8; 
    
    
    
    
    
    
    
    There might be variation how UNIQUE attribute is enforced in different versions of MySQL.
    
    In 5.5 it generate unique index  `logicalrouter_uuid`
    
    To take it out the correct statement is
    
    ALTER TABLE `cloud`.`nicira_nvp_router_map` 
    DROP INDEX `logicalrouter_uuid` ;
    
    Can you check if schema-40to410.sql got applied in your environment? What version of MySQL
do you use?
    
    The drop index logicalrouter_uuid should come from schema-470to471.sql (or later upgrade
script)but not from schema-410to420-cleanup.sql.
    
    
    
    From:  Remi Bergsma <notifications@github.com>
    Reply-To:  apache/cloudstack <reply@reply.github.com>
    Date:  Sunday, December 6, 2015 at 11:59 AM
    To:  apache/cloudstack <cloudstack@noreply.github.com>
    Cc:  Sergey Levitskiy <serg38l@hotmail.com>
    Subject:  Re: [cloudstack] CLOUDSTACK-9074: Support shared networking in NiciraNVP Plugin
(#1094)
    
    
    Guys, I cannot build a cloud from this branch any more. The build itself works, but the
database deployment gives an SQL error: Can't DROP 'logicalrouter_uuid'; check that column/key
exists
    
    Details:
    [INFO] --- exec-maven-plugin:1.2.1:java (create-schema) @ cloud-developer ---
    log4j:WARN No appenders could be found for logger (org.springframework.core.env.StandardEnvironment).
    log4j:WARN Please initialize the log4j system properly.
    log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
    ========> WARNING: Provided file does not exist: /data/git/cs1/cloudstack/developer/../utils/conf/db.properties.override
    ========> WARNING: Provided file does not exist: /data/git/cs1/cloudstack/developer/developer-prefill.sql.override
    ========> Initializing database=cloud with host=localhost port=3306 username=cloud
password=cloud
    ============> Running query: drop database if exists `cloud`
    ============> Running query: create database `cloud`
    ============> Running query: GRANT ALL ON cloud.* to 'cloud'@`localhost` identified
by 'cloud'
    ============> Running query: GRANT ALL ON cloud.* to 'cloud'@`%` identified by 'cloud'
    ========> Initializing database=cloud_usage with host=localhost port=3306 username=cloud
password=cloud
    ============> Running query: drop database if exists `cloud_usage`
    ============> Running query: create database `cloud_usage`
    ============> Running query: GRANT ALL ON cloud_usage.* to 'cloud'@`localhost` identified
by 'cloud'
    ============> Running query: GRANT ALL ON cloud_usage.* to 'cloud'@`%` identified by
'cloud'
    ========> Processing SQL file at /data/git/cs1/cloudstack/developer/target/db/create-schema.sql
    ========> Processing SQL file at /data/git/cs1/cloudstack/developer/target/db/create-schema-premium.sql
    ========> Processing SQL file at /data/git/cs1/cloudstack/developer/target/db/templates.sql
    ========> Processing SQL file at /data/git/cs1/cloudstack/developer/developer-prefill.sql
    ========> Processing upgrade: com.cloud.upgrade.DatabaseUpgradeChecker
    [WARNING]
    java.lang.reflect.InvocationTargetException
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:606)
            at org.codehaus.mojo.exec.ExecJavaMojo$1.run(ExecJavaMojo.java:297)
            at java.lang.Thread.run(Thread.java:745)
    Caused by: com.cloud.utils.exception.CloudRuntimeException: Unable to execute upgrade
script: /data/git/cs1/cloudstack/developer/target/db/db/schema-410to420-cleanup.sql
            at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:290)
            at com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:425)
            at com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:474)
            at com.cloud.upgrade.DatabaseCreator.main(DatabaseCreator.java:217)
            ... 6 more
    Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Can't DROP 'logicalrouter_uuid';
check that column/key exists
            at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
            at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
            at com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:281)
            ... 9 more
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 19.639s (Wall Clock)
    [INFO] Finished at: Sun Dec 06 09:07:53 GMT 2015
    [INFO] Final Memory: 43M/259M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:java (create-schema)
on project cloud-developer: An exception occured while executing the Java class. null: InvocationTargetException:
Unable to execute upgrade script: /data/git/cs1/cloudstack/developer/target/db/db/schema-410to420-cleanup.sql:
Can't DROP 'logicalrouter_uuid'; check that column/key exists -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR]
    [ERROR] For more information about the errors and possible solutions, please read the
following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
    Not sure if it is related. Tried cleaning everything (VMs, git repo, storage) but same
result.
    
    —
    Reply to this email directly or view it on GitHub.
    
      
    



> Support shared networking in NiciraNVP Plugin
> ---------------------------------------------
>
>                 Key: CLOUDSTACK-9074
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-9074
>             Project: CloudStack
>          Issue Type: Improvement
>      Security Level: Public(Anyone can view this level - this is the default.) 
>    Affects Versions: 4.7.0
>            Reporter: Nicolas Vazquez
>             Fix For: 4.7.0
>
>
> h3. Introduction
> Currently NiciraNVP plugin supports only Isolated networking. In this mode of operations
networks are assigned to individual Cloudstack accounts and on NSX side are completely isolated
on the L3 level. Many use cases especially in corporate environment call for shared networking
mode support. In some circumstances there also may be a need to translate shared NSX network
over to a physical VLAN via L2 NSX gateway.
> Features that will be introduced to support Cloudstack shared networks in two modes of
NiciraNVP plugin:
> * Shared networks mapped to a physical VLAN with L2 NSX gateway
> * Shared networks within the same L3 NSX domain. Multiple L3 NSX domains will be supported.
> h3. Features
> h4. 1) Shared networking model support
> # Support native Cloudstack shared network in NiciraNVP plugin.
> # Current code that implements isolated networking mode support will stay intact.
> # Designate network service offering by configuring VirtualNetworking provider with NiciraNVP.
> # Static/Source NAT is not used and ignored if defined in the network offering.
> # Nicira_vvp_router_map table will support non-unique logical routers to implement L3
NSX routing domains where multiple Cloudstack networks are attached to the same logical router.
> # Shared network with NSX based Virtual networking will go through the following states:
> ## Allocated
> ## Implementing
> ## Implemented
> ## Destroy
> h4. 2) Support NSX L2 gateways for L2 based VLANs mapped to a physical network
> # Optional L2gatewayserviceuuid parameter for NiciraNVP controller
> # VLAN ID of a Shared network represents VLAN to pass through L2 gateway similar to native
Cloudstack shared networking
> # NSX workflow for network allocation
> ## Check if l2gatewayservice defined
> ## Create record in networks table
> ### NiciraNvpGuestNetworkGuru as Guru_name
> ### Lswitch as broadcast_doamin
> ### Vlan://vlan_id as broadcast_uri
> ## Create record in VLAN table
> # NSX workflow for network implementation
> ## Check if l2gatewayservice defined and valid
> ## Create logical switch
> ## Map logical switch to L2gateway service assigning shared network VLAN ID
> # NSX workflow for NIC management and/or hypervisor support
> ## No changes from current implementation
> h4. 3) Support NSX L3 multiple routing domains
> # VLAN ID of a Shared network represents an UUID of a NSX virtual router of a particular
routing domain. We will support UUID style notation for VLAN ID. l3gatewayservice option is
not used in shared networking
> # It is assumed that if connectivity to the physical networking is required then logical
router is configured and connected to the physical network in advance. NiciraNVP plugin will
not perform any task beyond basic connectivity to the logical router
> # Support NSX L3 multiple routing domains
> # NSX workflow for network allocation
> ## Create record in networks table
> ### NiciraNvpGuestNetworkGuru as Guru_name
> ### Lswitch as broadcast_domain
> ### NULL as broadcast_uri
> ## Create record in VLAN table
> ## Create record in nicira_nvp_router_map table
> # NSX workflow for network implementation
> ## Check if logical router exists on NSX side which UUID matches the one defined during
shared network creation. This mode is activated if VLAN ID supplied in UUID style notation
> ## Create logical switch
> ## Attach logical switch to the logical router
> ## Assign shared network default gateway to the inside port of the logical router
> # NSX workflow for NIC management and/or hypervisor support
> ## No changes from current implementation
> h4. 4) API Changes
> # Existing API addNiciraNvpDevices will be updated
> ## Adding 1 new optional parameter – l2gatewayserviceuuid
> ## Adding 1 new response tag – l2gatewayserviceuuid
> # Existing API listNiciraNvpDevices will be updated
> ## Adding 1 new response tag – l2gatewayserviceuuid
> # Existing API listNics will be updated
> ## Adding 2 new optional response tag – nsxlogicalswitch, nsxlogicalswitchport



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message