Version 6 (modified by business@…, 11 years ago) (diff)


Set up dbNP instance on an NBX

Set up tomcat user

  • Login as manager
  • Create user tomcat:
    sudo adduser tomcat
  • Switch to user tomcat and its home directory
    sudo su - tomcat
  • Change default shell to bash:
    chsh -s /bin/bash
  • Check out deploy scripts and virtual host configurations
    svn checkout --username=anonymous
    svn checkout --username=anonymous
  • Download Tomcat (to find the newest version, go to, find it, click Download and look up the Core .tar.gz file)
    tar -zxvf apache-tomcat-7.0.16.tar.gz
  • Add CATALINA_OPTS parameter to default bash environment of Tomcat user (convenient when restarting Tomcat manually)
    echo "export CATALINA_OPTS=\"-Xms128m -Xmx2048m -XX:MaxPermSize=720m -XX:MaxHeapFreeRatio=70 -XX:MaxGCPauseMillis=10 -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled\"" >> ~/.bashrc
  • Return to your own (manager) shell
  • Copy the appropriate virtual host configuration from the SVN templates to the apache virtual host directory and adjust it to your wishes
    sudo cp /home/tomcat/vhost/dbnp.org_gscf-www.conf /etc/apache2/sites-available
    cd /etc/apache2/sites-enabled
    sudo ln -s ../sites-available/dbnp.org_gscf-www.conf
    sudo vi dbnp.org_gscf-www.conf
  • Restart Apache webserver
    /etc/init.d/apache2 reload