Background
This page documents the installation proceedure at SLAC.
Prereqs
Unix accounts
No log in. No password.
[yee@terapaths home]$ sudo /usr/sbin/luseradd terapaths -u 30000 -g terapaths
Java
From: here
[yee@terapaths installation]$ sudo mkdir /usr/java Password: [yee@terapaths installation]$ sudo mv jdk1.5.0_13/ /usr/java/
SJSAS
From here
[terapaths@terapaths installation]$ sh sjsas_pe-8_2-linux.bin sjsas_pe-8_2-linux.bin: sjsas_pe-8_2-linux.bin: cannot execute binary file [terapaths@terapaths installation]$ chmod ugo+x sjsas_pe-8_2-linux.bin
The Sun Java System Application Server Platform Edition components will be installed in the following directory, which is referred to as the "Installation Directory".To use this directory, press only the Enter key. To use a different directory, type in the full path of the directory to use followed by pressing the Enter key. Installation Directory [/home/terapaths/SUNWappserver] {"<" goes back, "!" exits}: The directory "/home/terapaths/SUNWappserver" does not exist. Do you want to create it now or choose another directory? 1. Create Directory 2. Choose New Enter the number corresponding to your choice [1] {"<" goes back, "!" exits} 1 The Sun Java System Application Server requires a Java 2 SDK. Please provide the path to a Java 2 SDK 1.4.1 or greater. Recommended version is 1.4.2 or greater. [/usr/java/jdk1.5.0_13] {"<" goes back, "!" exits} Supply the administrator user's password and override any of the other initial configuration settings as necessary. Administrator User [admin] {"<" goes back, "!" exits}: Administrator User's Password (8 chars minimum): Re-enter Password: Do you want to store administrator user name and password in user preference file [yes] {"<" goes back, "!" exits}? yes Administration Port [4848] {"<" goes back, "!" exits}: 53470 HTTP Port [8080] {"<" goes back, "!" exits}: 40860 HTTPS Port [8181] {"<" goes back, "!" exits}: 48580 Please choose installation options. Do you want to upgrade from previous Application Server version [no] {"<" goes back, "!" exits}?
Installation Successful. Next Steps: 1. Access the About Application Server PE 8 welcome page at: file:///home/terapaths/SUNWappserver/docs/about.html 2. Start the Application Server by executing: /home/terapaths/SUNWappserver/bin/asadmin start-domain domain1 3. Start the Admin Console: http://localhost:53470
Append to configuration file
// TeraPaths-specific permissions // Permission to NetworkDeviceController to create ClassLoaders for hardware drivers grant codeBase "file:${com.sun.aas.instanceRoot}/generated/ejb/j2ee-modules/terapathsNetworkDeviceControllers/-" { permission java.lang.RuntimePermission "createClassLoader"; }; grant codeBase "file:${com.sun.aas.instanceRoot}/applications/j2ee-modules/terapathsNetworkDeviceControllers/-" { permission java.lang.RuntimePermission "createClassLoader"; }; // Permissions needed by WAN proxy server(s) grant codeBase "file:${com.sun.aas.instanceRoot}/generated/ejb/j2ee-modules/terapathsESnetOSCARSProxy/-" { permission java.security.AllPermission; permission java.lang.RuntimePermission "getClassLoader"; permission java.lang.RuntimePermission "createClassLoader"; permission java.net.SocketPermission "*", "connect,accept,resolve"; permission java.io.FilePermission "<>", "read,write,delete"; }; grant codeBase "file:${com.sun.aas.instanceRoot}/applications/j2ee-modules/terapathsESnetOSCARSProxy/-" { permission java.security.AllPermission; permission java.lang.RuntimePermission "getClassLoader"; permission java.lang.RuntimePermission "createClassLoader"; permission java.net.SocketPermission "*", "connect,accept,resolve"; permission java.io.FilePermission "<>", "read,write,delete"; };
Change jvm settings, place within <java-config/>
tag at end.
<!-- this is to prevent the java.lang.OutOfMemoryError: PermGen space during deployment--> <jvm-options>-XX:MaxPermSize=256m</jvm-options> <!-- --> <!-- additional jvm options to fix file descriptor leak due to sockets not being closed (bug#:6321777) --> <jvm-options>-server</jvm-options> <jvm-options>-Dcom.sun.enterprise.web.connector.grizzly.useKeepAliveAlgorithm=true</jvm-options> <jvm-options>-Dcom.sun.enterprise.web.connector.grizzly.socketSoTimeout=30000</jvm-options> <jvm-options>-Dcom.sun.enterprise.web.connector.grizzly.maxKeepAliveRequests=250</jvm-options> <jvm-options>-Dcom.sun.enterprise.server.ss.ASQuickStartup=false</jvm-options> <!-- end of additional jvm options -->
MySQL
[root@terapaths installation]# rpm -Uhv MySQL-* error: Failed dependencies: MySQL conflicts with mysql-4.1.20-2.RHEL4.1.0.1.i386 [root@terapaths installation]# rpm -e mysql-4.1.20 error: Failed dependencies: libmysqlclient.so.14 is needed by (installed) cyrus-sasl-sql-2.1.19-14.i386 libmysqlclient.so.14(libmysqlclient_14) is needed by (installed) cyrus-sasl-sql-2.1.19-14.i386 [root@terapaths installation]# rpm -Uhv MySQL-server-community-5.0.45-0.rhel4.x86_64.rpm error: Failed dependencies: MySQL conflicts with mysql-4.1.20-2.RHEL4.1.0.1.i386 [root@terapaths installation]# rpm -e mysql-4.1.20 error: Failed dependencies: libmysqlclient.so.14 is needed by (installed) cyrus-sasl-sql-2.1.19-14.i386 libmysqlclient.so.14(libmysqlclient_14) is needed by (installed) cyrus-sasl-sql-2.1.19-14.i386 [root@terapaths installation]# rpm -e cyrus-sasl-sql-2.1.19 [root@terapaths installation]# rpm -e mysql-4.1.20
Change users
[root@terapaths installation]# mysql Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 3 Server version: 5.0.45-community MySQL Community Edition (GPL) Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> select User,Host from mysql.user -> ; +------+-----------+ | User | Host | +------+-----------+ | root | 127.0.0.1 | | root | localhost | | root | terapaths | +------+-----------+ 3 rows in set (0.01 sec)
mysql> create database terapaths; Query OK, 1 row affected (0.00 sec) mysql> GRANT ALL PRIVILEGES ON terapaths.* TO 'terapaths'@'localhost' IDENTIFIED BY '********'; Query OK, 0 rows affected (0.00 sec) mysql> select User,Host from mysql.user -> ; +-----------+-----------+ | User | Host | +-----------+-----------+ | root | 127.0.0.1 | | root | localhost | | terapaths | localhost | | root | terapaths | +-----------+-----------+ 4 rows in set (0.00 sec) mysql>
Database creation
Create the terapaths MySQL database by running terapaths-create-1.2.0.sql.
[terapaths@terapaths dist]$ pwd /home/terapaths/installation/dist [terapaths@terapaths dist]$ mysql -u terapaths -D terapaths -p < terapaths-create-1.2.0.sql Enter password: [terapaths@terapaths ~]$ mysql -u terapaths -p -D terapaths Enter password: Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 8 Server version: 5.0.45-community MySQL Community Edition (GPL) Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> show tables; +-----------------------+ | Tables_in_terapaths | +-----------------------+ | WANServiceURL | | bandwidthClasses | | diffServClasses | | hosts | | remoteLANServiceURL | | reservations | | routerDrivers | | routerManagers | | routers | | routes | | systemMessages | | terapathsDatabaseInfo | | users | | virtualRouterMembers | | virtualRouters | +-----------------------+ 15 rows in set (0.01 sec)
Edit terapaths-populate-1.2.0.sql to match your network host information and run it to populate the database.
3. Edit terapaths.properties to contain the database info and service module URLs for each host at which one or more terapaths modules will be deployed.
This configuration directs running terapaths modules where to contact other terapaths modules and/or the database.
4. Edit proxy.properties to match your WAN provider accounts (currently only ESnet/OSCARS is supported). --obsolete
5. Edit terapathsWebInterfaceDefaults to contain the defaults of your choice for the web interface.
Copy the file to the /home/terapaths directory of the host where terapathsWebInterface will be deployed.
The defaults can be changed at any time, even when the service is running.
This file overrides the build-in defaults.
6. Edit autodeploy-hosts to describe which modules to deploy at which hosts.
7. Run the 'terapaths-deploy' script.