Skip to main content
Kofax

MarkView All Components - What are the steps for creating multiple instances of a middle-tier Web application?

Summary

The MarkView Installer (versions 4.7 through 5.10.x) installs all middle-tier servers under a single j2ee directory. How do I create multiple OC4J instances? 3963

Applies To

  • ERP System: ( Oracle, Peoplesoft)
  • MarkView Version: (5.x and below)

Behavior

  • For performance reasons, it is sometimes better to run multiple instances of the MarkView Application Server Viewer Module.

Known Causes

  • The MarkView Installer installs only one copy of each of the specified MarkView middle tier applications. Consequently, by default, only one instance (process) of each MarkView middle tier application will run when you invoke the start-all script.

Resolution

  • Unfortunately, you can't run multiple instances of a middle tier application simply by starting the same copy twice.
    To setup the system to run multiple instances of the -MarkView Application Server Viewer Module-, follow these steps:
    1. Log in to the middle tier host that is running MarkView Application Server Viewer Module- as the user who owns the MarkView Application Server Viewer Module- module.
    2. Change directory to OC4J?home directory where oc4j.jar is located. The OC4J home directory is in the j2ee/home subdirectory of the directory in which you unzipped the oc4j_extended.zip file. For example, suppose you unzipped the oc4j_extended.zip file into the /usr/markview/oc4j directory. In this case, the OC4J home directory would be /usr/markview/oc4j/j2ee/home, so the change directory command would be as follows:
      $ cd /usr/markview/oc4j/j2ee/home
    3. Make a copy of the MarkView Application Server Viewer Module- directory tree; for example, to do this on UNIX or Linux, issue the following command:
      $ cp -rp config-mvas-vm config-mvas-vm2
    4. Change directory to the top of the copied tree:
      $ cd config-mvas-vm2
    5. Edit the following configuration files:
      • Edit the rmi.xml file, setting the rmi-server port to an unused port number
      • Edit the http-web-site.xml file, setting the web-site port to an unused port number
      • Edit the jms.xml file, setting the jms-server port to an unused port number
    6. The copied Web application may not log messages to the same log file as the original Web application. Therefore, you must edit the following files, setting the log file to an unused pathname:
      • rmi.xml
      • jms.xml
      • server.xml
        In all these files, you should see a section that looks something like the following:
        <log>
        <file path="../log/mvas-vm-rmi2.log">

        Modify the pathname assigned to path, specifying a previously unused pathname.? (Do not specify a pathname that another application is already using.)
    7. Return to the parent directory (the J2EE home directory) to modify the instance startup scripts. Create a copy of the start-up script for - MarkView Application Server Viewer Module-; for example:
      $ cd..
      $ cp start-mvas-vm.sh start-mvas-vm2.sh
    8. Using a text editor, edit the renamed start-up script: (for example, start-mvas-vm2.sh), changing the value assigned to the app_name variable. For example, you might change app_name from
      app_name=mvas-vm
      to
      app_name=mvas-vm2
    9. Add start-mvas-vm2.sh to the list of scripts invoked by the start-all.sh script; for example, change the following:
      for i in `ls start-mvas-vm.sh start-mvas-bcg.sh start-mvas-dtm.sh start-graphics.sh start-sfas-mm.sh`; do ./$i ; done
      so that it becomes:
      for i in `ls start-mvas-vm.sh start-mvas-bcg.sh start-mvas-dtm.sh start-graphics.sh start-sfas-mm.sh start-mvas-vm2.sh`; do ./$i ; done
    10. Create a copy of the stop script for your Web application; for example:
      $ cp stop-mvas-vm.sh stop-mvas-vm2.sh
    11. Using a text editor, edit the renamed stop script: (for example, stop-mvas-vm2.sh). Set the value of the pid_file variable to reference the new instance, for example, change the following:
      pid_file=$log_dir/mvas-vm.pid
      to:
      pid_file=$log_dir/mvas-vm2.pid
    12. While still editing the renamed stop script, change the RMI port value to the new RMI port that you assigned in Step 5; for example, suppose in Step 5 that you set the RMI port to 23798. In that case, you would change the following:
      nohup java -jar admin.jar ormi://localhost:23791
      to:
      nohup java -jar admin.jar ormi://localhost:23798
    13. Add stop-mvas-vm2.sh to the list of scripts invoked by the stop-all.sh script. For example, change the following:
      for i in `ls stop-mvas-vm.sh stop-mvas-bcg.sh stop-mvas-dtm.sh stop-graphics.sh stop-sfas-mm.sh`; do ./$i ; done to become:
      for i in `ls stop-mvas-vm.sh stop-mvas-bcg.sh stop-mvas-dtm.sh stop-graphics.sh stop-sfas-mm.sh stop-mvas-vm2.sh`; do ./$i ; done

Keywords: OC4J, load, balance, performance