VAO VOSpace 2.0 implementation

The project archive

vospace-2.0-3031.tgz

The project source

svn+ssh://usvao-svn@svn.usvao.org/usvao/prototype/vospace/trunk/vospace-2.0/java/merged

Installation

The installation procedure is tested for Ubuntu 10.10 x64.

  1. Install the packages:
  2. sudo apt-get install mysql-server tomcat6
    (optional) sudo apt-get install rabbitmq-server swift
  3. Create the mysql database and load the data from the vospace-2.0/sql/vospace.sql file:
  4. mysql -u root -p
    create database vospace;
    exit;
    mysql -u root -p vospace < vospace.sql
    (You may need to change the mysql config my.cnf if installing on different host.)
    1. To add a virtual host to RabbitMQ and set permissions (optional, usually not needed):
    2. sudo /usr/sbin/rabbitmqctl add_vhost /vhost_name
      sudo /usr/sbin/rabbitmqctl set_permissions -p /vhost_name guest ".*" ".*" ".*"
      (No special user credentials are used for now)
  5. If you want to use the SWIFT file storage, install Swift according to the http://swift.openstack.org/development_saio.html (single server test installation) or http://swift.openstack.org/howto_installmultinode.html (multi-server cluster installation). Otherwise use the filesystem plugin.
    1. Currently VOSpace uses the pool of pre-generated SWIFT user accounts to assign to newly registered users. To create the user accounts in newly installed and set up SWIFT and add them to the database, there is a script in sql directory of the project: generate_swift_users.pl. Modify it according to the MySQL settings and the accounts pool needs.
  6. Set up the configuration in vospace.war/WEB-INF/classes/application.properties (if deploying the compiled war) or vospace-2.0/src/application.properties (if building the application to ..war)
  7. application.url - the accessible http url of the application
    storage.url - the url to the SWIFT proxy service (if using the SWIFT configuration)
    storage.local.root - the local filesystem folder (if using the local folder configuration)
    db.* - MySQL database configuration
    rabbitmq.* - RabbitMQ configuration (if using the MySQL+RabbitMQ plugin)
    metastore.class - the module for working with metadata. Currently only one is available.
    filestore.class - the module for file storage.
    jobsprocessor.class - the jobs manager module.
  8. (optionally build) and copy the configured vospace-2.0.war to /var/lib/tomcat6/webapps. The application will be automatically deployed.
  9. Direct your browser to http://<hostname>:8080/vospace-2.0 and login using the NCSA single sign-on system
  10. The VOSpace service is available at http://<hostname>:8080/vospace-2.0/rest/ url (f.e. http://localhost:8080/vospace-2.0/rest/nodes)

    Additionally to the single sign-on (OpenID) with OAuth, the REST service uses the X.509 certificates. To enable the certificates support:

  11. Uncomment the HTTPS connector section in the tomcat conf/server.xml file
  12. Create the tomcat keystore:
    1. $JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA -keystore \path\to\my\keystore
  13. Add the following attributes to the section:
    1. clientAuth="true"
    2. keystorePass="keystore_password"
    3. keystoreFile="file_full_path"
  14. The full description of how to enable the SSL in tomcat is at http://tomcat.apache.org/tomcat-7.0-doc/ssl-howto.html
  15. Add the NCSA root certificate to the JAVA keystore:
  16. http://dev.usvao.org/vao/wiki/SSOforPortals/TrustRoots
  17. The X.509 certificate can be obtained from NCSA after user registration at http://nvologin1.ncsa.uiuc.edu/public/welcome