Installation

PageSeeder installation and upgrade instructions

Installing Publisher

Warning!

Installing the publisher as a separate server is NOT NECESSARY AS PART OF A NORMAL PAGESEEDER INSTALLATION and is not usually recommended.

Because the Publish Engine is often called upon to run CPU-intensive tasks such as document composition or transformation, it has been designed for deployment on server hardware different from the main host hardware. This helps to avoids Publish tasks degrading the productivity of other users on the PageSeeder server.

To do this requires that the Publish Engine API be deployed on to a physical server running a Java/Web Application Server (Tomcat, Jetty). The API is in a file called ps-publisher-x.zip and it MUST BE THE SAME VERSION AS THE CORRESPONDING PAGESEEDER SERVER. For further information about Web Application Server, see the following section.

  1. To deploy, simply unzip the contents of the ZIP file in the Webapp directory and restart the Web Application Server. The unzipped folder should be renamed to ps-publisher if required.
  2. The PageSeeder server can then be configured to communicate with this Publish Engine. This is not required if you are just using the engine to run scripts locally for development. To do it, add the following line:
    publishEngineUrl=http\://[your_server]\:[your_port]/ps-publisher/PublishEngine
    

    to this file

    webapp/WEB-INF/config/global.properties
    

    Then restart the PageSeeder server.

Note

If an existing Project has a custom Publish script, copy them to the same location under the ps-publisher folder (i.e. Everything under "template/[your style owner] should be copied to ps-publisher/WEB-INF/template/[your style owner]).

Installing Jetty

Jetty is an open-source project providing an HTTP server, HTTP client and Web Application container. For further information or to download: http://docs.codehaus.org/display/JETTY/Jetty+Wiki .

For this documentation, all reference will be to Jetty 6.1.18.

Jetty as a service on Windows

After downloading Jetty 6.1.18 for windows, simply unzip to the desired installation directory and configure it before running Jetty as a Windows service.

To do this, modify the file located at:

[jetty dir]/bin/jetty-service.conf

For this example, Jetty has been configured to use port 8080 by adding the following line to the file:

wrapper.java.additional.3=-Djetty.port=8080

To have the log file rolled over daily, simply modify the line:

wrapper.app.parameter.1=../etc/jetty.xml

into

wrapper.app.parameter.1=../etc/jetty-logging.xml ../etc/jetty.xml

Finally, to install Jetty as a service, open a command line window pointing at the bin directory and type the following:

Jetty-Service.exe -i jetty-service.conf

In the Services window Jetty6-Service should now be visible.

Jetty as a service on Linux

PageSeeder on Linux requires the following to be installed:

  1. If Java JDK 1.6.0 is not installed then install it (see JDK 6 SE - http://java.sun.com/javase/downloads  ). Installation example:
    $ cd /usr/java $ wget -O jdk1.6.0_06.bin <
    download-url> $ ./jdk1.6.0_06.bin
    
  2. Download the latest Jetty@Eclipse 7.x version from http://www.eclipse.org/jetty  and extract it to /usr/jetty-7.x.
  3. Copy /usr/jetty-7.x/bin/jetty.sh to /etc/init.d/jetty
  4. Make /etc/init.d/jetty executable:
    chmod +x /etc/init.d/jetty
  5. Modify the top couple of lines in /etc/init.d/jetty to same as below:
    # To get the service to restart correctly on reboot, uncomment below (3 lines):
    # chkconfig: 345 99 99
    # description: Jetty 7 webserver
    # processname: jetty
  6. Add jetty into system service start: 
    chkconfig --add jetty
    chkconfig --del jetty
    chkconfig --add jetty
  7. Turn jetty service on:
    chkconfig jetty on
  8. Add below into /etc/init.d/jetty to set up environment:
    JETTY_HOME=/usr/jetty-7.x
    JAVA_HOME=/usr/java/jdk1.6.0_06
    JAVA=$JAVA_HOME/bin/java
    JETTY_USER=root
  9. (Optional) Add below into /etc/init.d/jetty to set up environment:
    JAVA_OPTIONS="-Xmx512m -Xmn512m -XX:+CMSClassUnloadingEnabled"
  10. (Optional) Bug in this release that service jetty start won't work unless the /etc/init.d/jetty is modified to add cd "$JETTY_HOME" to the two places below:
    su - "$JETTY_USER" -c "
              cd "$JETTY_HOME"
              ${RUN_CMD[*]} --daemon &
              disown \$!
              echo \$! > '$JETTY_PID'"
          else
            cd "$JETTY_HOME"
            "${RUN_CMD[@]}" &

    FOR REFERENCE: 
    https://bugs.eclipse.org/bugs/show_bug.cgi?id=309691 
  11. (Optional) If you do not wish to run Jetty on the default port (e.g. 8080) then edit the line below in file: /usr/jetty-7.2.2/etc/jetty.xml and change the 8080: <Set name="port"><Property name="jetty.port" default="8080"/></Set>

Running the Publish Engine

  1. Deploy the Publish Engine on Jetty by unzipping the ps-publisher-x.zip file in the webapp directory. On Windows, it should be something like [install dir]/jetty-6.1.18/webapps, and on Linux, it should be /usr/jetty-7.x/webapps. The unzipped folder name should be renamed to ps-publisher if required.
  2. Edit the file ps-publisher/WEB-INF/config/publish.properties and
    1. add the pageseederHost property with your Pageseeder Server URL host
      (e.g. pageseederHost=myps.mycompany.com)
    2. if your Pageseeder Server is not running on port 80 also add the pageseederPort property
      (e.g. pageseederPort=8080)
  3. Restart the jetty service (use the Services window on Windows or the command service jetty restart on Linux).
  4. The Publish Engine is now running. To ensure it is accessible, simply open a browser window at the location http://[publish server]:8080/ps-publisher. The login screen should be seen and login can be performed using a PageSeeder administrator account.

Turning off Request Logging (Jetty 6.x only)

Requests are logged by default on Jetty 6.x in a separate log file in the same directory. As these files may get big, request logging can be turned off by modifying the configuration jetty.xml in the config directory ([install dir]/etc on Windows and jetty-6.x/etc on linux). Simply remove or comment out the lines referring to the Request Logger as follows.

Around line 110:

<Item>
  <New id="RequestLog" class="org.mortbay.jetty.handler.RequestLogHandler"/>
</Item>

And around line 190:

<Ref id="RequestLog">
  <Set name="requestLog">
    <New id="RequestLogImpl" class="org.mortbay.jetty.NCSARequestLog">
      <Set name="filename"><SystemProperty name="jetty.logs" default="./logs"/>/yyyy_mm_dd.request.log</Set>
      <Set name="filenameDateFormat">yyyy_MM_dd</Set>
      <Set name="retainDays">90</Set>
      <Set name="append">true</Set>
      <Set name="extended">false</Set>
      <Set name="logCookies">false</Set>
      <Set name="LogTimeZone">GMT</Set>
    </New>
  </Set>
</Ref>

All these lines should be commented out or removed. Then, save the file and restart the service.

Created on , last edited on