Changes between Version 105 and Version 106 of instructions

05/11/11 15:20:27 (8 years ago)
vjo (IP:



  • instructions

    v105 v106  
    33[wiki:Prerequisites Software prerequisites] 
    5 [wiki:buildInstructions Build ORCA from source] 
     5== Deploying an ORCA Actor Container in Emulation == 
    7 [ Understanding container configuration: ORCA_HOME, ORCA_LOCAL, and all that] 
     7Orca actors run within servlet containers (JVMs). This document is intended to assist you in getting a container up and running quickly, 
     8with instances of each of the three actors (Service Manager, Broker, and Aggregate Manager) operating in emulation mode. 
    9 [ Actor configuration] 
    11 == Deploying GENI-ORCA == 
    13 Orca actors run within containers (JVMs).  We assume that your orca container is a Tomcat web application server. 
    15 === Install Tomcat and create the initial database === 
    16 1. Follow instructions to setup [wiki:orca-home $ORCA_HOME directory structure] and [wiki:orca-tomcat configure Tomcat]. 
     10=== Emulation Mode Setup === 
     111. Follow the instructions in the setup section of the [wiki:orca-home $ORCA_HOME directory structure page.] 
     122. Download the attached [ sample emulation configuration] and extract it into $ORCA_HOME 
     133. Download our slightly-modified [source:/software/tomcat.tar.gz Tomcat] and extract it into $ORCA_HOME 
    17143. Make sure MySQL is running on your system. 
    2724These instructions help set up a local Tomcat container with an example inventory of substrate that allows ORCA to run in '''emulation''' mode. This step is highly recommended before running with real resources to make sure your setup is correct. 
    29 5. Give ANT more heap space. This can be added to ~/.profile 
    30 {{{ 
    31 $ export ANT_OPTS="-XX:MaxPermSize=512m -Xms40m -Xmx1024m" 
    32 }}} 
    34 === Generating the GENI-ORCA container configuration files === 
    36 The actor-independent configuration files for the container reside in [ ORCA_HOME].  These config files include a security configuration, with certificates and a keystore. 
    38 ==== 1.2 and following releases (Bella, Camano etc) ==== 
    40 Starting from release 1.2 ORCA '''no longer packages config/ or runtime/ directories into the webapp'''.  Note also that in the initial release of Bella (2.0) has a directory called webapp2/ for the new configuration framework.  If your source pool has a directory webapp2/, then '''use webapp2/ instead of webapp/''' in the instructions below.  
    42 1. Generate a security configuration.  
    44 {{{ 
    45 $ cd tools/config 
    46 $ ant security.create.admin.config 
    47 }}} 
    49 This command creates a directory called runtime/ in the current directory (tools/config) 
    50 and places the generated files in there.  '''NOTE:''' if there is an existing runtime/ directory, 
    51 first move it out of the way. 
    53 2. Define [ ORCA_HOME] and copy the configuration directories to $ORCA_HOME. 
    54 {{{ 
    55 $ export ORCA_HOME=/opt/orca 
    56 $ cp -r runtime $ORCA_HOME 
    57 $ cp -r scripts $ORCA_HOME 
    58 }}} 
    60273. Copy to $ORCA_HOME and then customize (if necessary; for emulation nothing should be necessary) the container configuration files ([] etc.) under webapp/config:   
    7542'''NOTE:''' About the config-all-local.xml configuration file: this file describes three actors (a broker, a slice manager and a Eucalyptus site authority) that go into the container. The authority actor automatically delegates 10 instances of virtual machines and 1000 instances of internal vlans to the broker. 
    77 ==== 1.1-alpha and previous releases ==== 
    79 If your filesystem 
    80 supports symbolic links, simply use the provided ant task: 
    82 {{{ 
    83 $ ant prepare.use 
    84 }}} 
    86 This task will generate the admin security configuration and place links to it in the relevant directories. It will also initialize and link other directories 
    87 needed to build/test drivers.  
    89 If your file system does not support symbolic links or you want more control over the process you can try the following steps: 
    91 1. Create the security configuration by going to tools/config and running 
    92 {{{ 
    93 $ cd tools/config 
    94 $ ant security.create.admin.config 
    95 }}} 
    97 '''NOTE:''' Make sure there is no existing runtime directory before you run this command unless you know what you are doing. 
    99 2. Copy or softlink the resulting runtime/ directory to the orca/webapp directory. 
    101 === Generating the GENI-ORCA web application === 
    104 1. Create the webapp with this command: 
    106 {{{ 
    107 $ cd $ORCA_SRC/webapp 
    108 $ mvn package 
    109 }}} 
    111 2. Deploy into an '''already running''' tomcat instance on the local machine by typing 
    113 {{{ 
    114 $ cd $ORCA_SRC/webapp 
    115 $ ant deploy 
    116 }}} 
    11845Before packaging the webapp, the webapp config directory should be populated with configuration files for ORCA_LOCAL, as described above.  Before deploying the webapp, the tomcat container should be configured with a proper ORCA_HOME populated with configuration files as described above.   
    120 3. Log into the portal at http://localhost:11080/orca ~~with username "admin" and no password~~, unless you changed the defaults. 
    12247'''NOTE:''' as of Bella 2.0 container administrator login/password credentials are located in []. 
    124 4. If the app did not come up as expected, then the container (ORCA_HOME) and actors (ORCA_LOCAL) are likely misconfigured.  There is no easy way to debug configuration errors.  Check the container logs in tomcat/logs/orca*.log.   You can add more information to these logs by editing the log4j properties in ORCA_HOME/config/, e.g., to add "%C %M %L" to the ConversionPattern to print the class, method, and line number for each log message.  It is also possible to load config.xml directives into the running web GUI, under the admin tab, which gives additional error reporting through the GUI.  Config processing is not atomic or idempotent: if config processing fails, some directives may have completed successfully. 
    126 '''Feature:''' in multi-container configurations claim processing for exported tickets (advertisements/delegations) must be done manually after the container stands up, since it requires inter-actor communication.  Go to the broker tab, create an inventory slice, and claim the delegation, using the GUID for the exported ticket, which is visible under the site tab (view exported resources). '''This does not apply to emulation mode example''' 
    128 '''Feature:''' if you restart tomcat, it will recover your previous container state.  If you redeploy, or undeploy and redeploy, it will reinitialize the container to its fresh state, and delete state about existing slices and reservations from the database.  Note also that tomcat does not always stop cleanly: sometimes it is necessary to kill the process.  This case may lead to problems on recovery due to an unidentified bug.  If you don't need to recover, then re-deploy.  If you want to be sure your tomcat is clean, you might first remove the tomcat/webapps/orca* directories before restarting the server and redeploying. 
    130 === Quick Start emulation mode test === 
     49=== Testing Emulation Mode === 
    13251Videos attached to this page show how the system works once it is installed (no audio). A simple test with the default actor configuration described above is to 
    13958 6. You can optionally close the reservation by selecting a check-box next to it and selecting 'Close' from the Action menu. 
    141 For a more sophisticated example that involves manually delegating resources from the site to the broker prior to creating a reservation through a slice manager: 
    142  1. Stop tomcat 
    143  2. Remove $ORCA_HOME/state_recovery.lock file (to make sure we wipe out inventory on the restart)  
    144  3. Remove Orca webapp from $ORCA_HOME/tomcat/webapps 
    145 {{{ 
    146 $ cd $ORCA_HOME/tomcat/webapps 
    147 $ rm -rf orca* 
    148 }}} 
    149  4. Start tomcat again 
    150  5. Edit $ORCA_SRC/webapp/actor_configs/config.xml file by commenting out the <rset> stanza in the topology section at the bottom: 
    151 {{{ 
    152                         <edge> 
    153                                 <from name="ndl-broker" type="broker" /> 
    154                                 <to name="euca-vm-site" type="site" /> 
    155 <!-- 
    156                                 <rset> 
    157                                         <type>unc.vm</type> 
    158                                         <units>10</units> 
    159                                 </rset> 
    160 --> 
    161                         </edge> 
    162 }}} 
    163  5. Package and deploy the webapp: 
    164 {{{ 
    165 $ cd $ORCA_SRC/webapp 
    166 $ mvn package; ant deploy 
    167 }}} 
    168  6. Login to ORCA portal 
    169  7. Go to 'site' tab. Click on 'Create Slice'. Give a slice a name (no whitespaces). Click 'Create' 
    170  8. Click on 'Export Resources'. Enter 10 (maximum available) number of units. Click 'Create'. This creates a delegation from the site to the broker.  
    171  9. Click on 'View Exported Resources' - you should see your new slice. Click on 'manage' link on the right.  
    172  10. In the screen with 'Reservation Details' copy into clipboard Reservation ID - we need to give this to the broker to claim this reservation. 
    173  11. Claim the reservation on the broker side. Go to 'broker' tab. Click on 'Claim Resources'. Paste the reservation ID into the appropriate field and click 'Claim' 
    174  12. Validate that the claim succeeded by clicking on 'View Inventory'  
    175  13. Follow steps 3, 4 and 5 of the previous example to create a user reservation. 
    17760=== Testing the sample XML-RPC controller in emulation mode ===