Difference between revisions of "Recreating Playground"

From Digital Scholarship Group
Jump to navigation Jump to search
(more stuff2do)
Line 11: Line 11:
 
== Things we should or have installed ==
 
== Things we should or have installed ==
  
* Emacs — installed 2020-11-30 with `sudo yum install emacs-nox.x86_64`
+
* Emacs — installed 2020-11-30 with <tt>sudo yum install emacs-nox.x86_64</tt>
 
* Emacs/nxml — was automagically installed by above (and has nice colors! :-)
 
* Emacs/nxml — was automagically installed by above (and has nice colors! :-)
* make — installed 2020-11-30 with `sudo yum install make.x86_64`
+
* make — installed 2020-11-30 with <tt>sudo yum install make.x86_64</tt>
* Subversion — installed 2020-11-30 with `sudo yum install subversion.x86_64`
+
* Subversion — installed 2020-11-30 with <tt>sudo yum install subversion.x86_64</tt>
 
* libxml2/xmllint — libxml2-2.9.7-7.el8.x86_64 is already installed
 
* libxml2/xmllint — libxml2-2.9.7-7.el8.x86_64 is already installed
* libxslt/xsltproc — installed 2020-11-30 with `sudo yum install libxslt.x86_64`
+
* libxslt/xsltproc — installed 2020-11-30 with <tt>sudo yum install libxslt.x86_64</tt>
* ant — intsalled 2020-11-30 with `sudo yum install ant.noarch`
+
* ant — intsalled 2020-11-30 with <tt>sudo yum install ant.noarch</tt>
* screen — nope, Red Hat [https://access.redhat.com/solutions/4136481 recommends tmux] instead — installed 2020-11-30 with `sudo yum install tmux.x86_64`
+
* screen — nope, Red Hat [https://access.redhat.com/solutions/4136481 recommends tmux] instead — installed 2020-11-30 with <tt>sudo yum install tmux.x86_64</tt>
 
* Tomcat — no yum package found
 
* Tomcat — no yum package found
 
** downloaded the “Core” tarball off of https://tomcat.apache.org/download-90.cgi
 
** downloaded the “Core” tarball off of https://tomcat.apache.org/download-90.cgi
Line 27: Line 27:
 
** created symlinks for work/ temp/ and logs/ (just copying what we have on current production system)
 
** created symlinks for work/ temp/ and logs/ (just copying what we have on current production system)
 
** following instructions at https://tomcat.apache.org/tomcat-9.0-doc/setup.html ...
 
** following instructions at https://tomcat.apache.org/tomcat-9.0-doc/setup.html ...
* git — installed 2020-11-30 with `sudo yum install git.x86_64` (installed 46 dependencies, mostly Perl packages)
+
* git — installed 2020-11-30 with <tt>sudo yum install git.x86_64</tt> (installed 46 dependencies, mostly Perl packages)
* eXist — '''no yum package found'''
+
* eXist — no yum package found, so see detailed description below
 
* MariaDB ('''maybe'''? maybe not)
 
* MariaDB ('''maybe'''? maybe not)
 +
* CouchDB ('''maybe'''? maybe not)
 
* lessc (pkg = node-less) — no yum package found
 
* lessc (pkg = node-less) — no yum package found
 
** Ash checked, they recommend installing via npm
 
** Ash checked, they recommend installing via npm
** npm — installed 2020-12-02 with `sudo dnf install npm.x86_64`
+
** npm — installed 2020-12-02 with <tt>sudo dnf install npm.x86_64</tt>
** installed lessc with `sudo npm install less -g`
+
** installed lessc with <tt>sudo npm install less -g</tt>
 
* Perl — v 5.26.3 already installed
 
* Perl — v 5.26.3 already installed
* PHP — installed 2020-11-30 with `sudo yum install php.x86_64`
+
* PHP — installed 2020-11-30 with <tt>sudo yum install php.x86_64</tt>
 
* Python — I do not know if we want version 3.6 or 3.8 (or 2.7, which I doubt); see [https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/configuring_basic_system_settings/using-python3_configuring-basic-system-settings the RHEL8 doc]
 
* Python — I do not know if we want version 3.6 or 3.8 (or 2.7, which I doubt); see [https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/configuring_basic_system_settings/using-python3_configuring-basic-system-settings the RHEL8 doc]
 
* Awstats —'''not found'''
 
* Awstats —'''not found'''
* locate — already installed, but need to generate and cronify udpatedb; done 2020-11-30, I think. Ran `sudo /usr/bin/updatedb` and now `locate` seems to work. Symlinked /usr/bin/updatedb to /etc/cron.daily/updatedb. Hope that works. I think we check by loooking at timestamp of /var/lib/mlocate/mlocate.db.
+
* locate — already installed, but need to generate and cronify udpatedb; done 2020-11-30, I think. Ran <tt>sudo /usr/bin/updatedb</tt> and now <tt>locate</tt> seems to work. Symlinked /usr/bin/updatedb to /etc/cron.daily/updatedb. Hope that works. I think we check by loooking at timestamp of /var/lib/mlocate/mlocate.db.
* gcc — installed 2020-12-02 with `sudo dnf install gcc.x86_64`
+
* gcc — installed 2020-12-02 with <tt>sudo dnf install gcc.x86_64</tt>
  
=== Apache modules, etc. ===
+
=== Apache setup, modules, etc. ===
 
+
We (Syd & Ash) worked on configuring the web server for awhile, but were still having problems. Ernesto (user=nestochan) gave us a hand, performed some firewall magic, and now it is working. Need to find out what he did.
* mod_jk
 
 
* server side includes
 
* server side includes
 
* whatever we need for security and textbaseIP stuff
 
* whatever we need for security and textbaseIP stuff
* redirection stuff
+
** mod_jk
 +
** <tt>/etc/httpd/passwd/</tt>
 +
* redirection stuff (mostly part of configuration)
 +
 
 +
=== other things to be moved over ===
 +
* WWO
 +
* WWP website
 +
** including configuration files
 +
** include git repos per /var/www/html/WWP/lab/README-WWP
 +
* eXist applications (see [[WWP_eXist-DB_applications]])
 +
* either Awstats or something better
 +
** remember, /usr/local/bin/rgxg is used by Awstats
 +
* WordPress
 +
* /usr/local/bin/wwpwwwup.bash
 +
 
 +
==== things to be moved only to <tt>wwp-test</tt> ====
 +
* MediaWiki
 +
* CouchDB and the data produced for Cultures of Reception
 +
 
 +
==== things we need help with ====
 +
* MediaWiki (Karl)
 +
* WordPress (Karl)
 +
* documenting what was done to firewall (Ernesto)
 +
* mod_jk?
  
 
== eXist-DB ==
 
== eXist-DB ==

Revision as of 11:39, 18 December 2020

Installing CentOS and WWO onto playground

This page is notes for re-creating the WWO environment from RH 6.10 (wwp.neu.edu) to CentOS 8.2 (playground). It will serve as a guide to start, and then hopefully a useful description for future similar upgrades.

CentOS

Installing CentOS was essentially trivial. We used the CentOS-8.2.2004-x86_64-boot.iso.

It appears that yum has been superceded by dnf.

Things we should or have installed

  • Emacs — installed 2020-11-30 with sudo yum install emacs-nox.x86_64
  • Emacs/nxml — was automagically installed by above (and has nice colors! :-)
  • make — installed 2020-11-30 with sudo yum install make.x86_64
  • Subversion — installed 2020-11-30 with sudo yum install subversion.x86_64
  • libxml2/xmllint — libxml2-2.9.7-7.el8.x86_64 is already installed
  • libxslt/xsltproc — installed 2020-11-30 with sudo yum install libxslt.x86_64
  • ant — intsalled 2020-11-30 with sudo yum install ant.noarch
  • screen — nope, Red Hat recommends tmux instead — installed 2020-11-30 with sudo yum install tmux.x86_64
  • Tomcat — no yum package found
  • git — installed 2020-11-30 with sudo yum install git.x86_64 (installed 46 dependencies, mostly Perl packages)
  • eXist — no yum package found, so see detailed description below
  • MariaDB (maybe? maybe not)
  • CouchDB (maybe? maybe not)
  • lessc (pkg = node-less) — no yum package found
    • Ash checked, they recommend installing via npm
    • npm — installed 2020-12-02 with sudo dnf install npm.x86_64
    • installed lessc with sudo npm install less -g
  • Perl — v 5.26.3 already installed
  • PHP — installed 2020-11-30 with sudo yum install php.x86_64
  • Python — I do not know if we want version 3.6 or 3.8 (or 2.7, which I doubt); see the RHEL8 doc
  • Awstats —not found
  • locate — already installed, but need to generate and cronify udpatedb; done 2020-11-30, I think. Ran sudo /usr/bin/updatedb and now locate seems to work. Symlinked /usr/bin/updatedb to /etc/cron.daily/updatedb. Hope that works. I think we check by loooking at timestamp of /var/lib/mlocate/mlocate.db.
  • gcc — installed 2020-12-02 with sudo dnf install gcc.x86_64

Apache setup, modules, etc.

We (Syd & Ash) worked on configuring the web server for awhile, but were still having problems. Ernesto (user=nestochan) gave us a hand, performed some firewall magic, and now it is working. Need to find out what he did.

  • server side includes
  • whatever we need for security and textbaseIP stuff
    • mod_jk
    • /etc/httpd/passwd/
  • redirection stuff (mostly part of configuration)

other things to be moved over

  • WWO
  • WWP website
    • including configuration files
    • include git repos per /var/www/html/WWP/lab/README-WWP
  • eXist applications (see WWP_eXist-DB_applications)
  • either Awstats or something better
    • remember, /usr/local/bin/rgxg is used by Awstats
  • WordPress
  • /usr/local/bin/wwpwwwup.bash

things to be moved only to wwp-test

  • MediaWiki
  • CouchDB and the data produced for Cultures of Reception

things we need help with

  • MediaWiki (Karl)
  • WordPress (Karl)
  • documenting what was done to firewall (Ernesto)
  • mod_jk?

eXist-DB

`wget` the JAR file from [1]. WWP is currently using eXist v4.7.1, but will soon be upgrading to 5.x.

useradd --home-dir /opt/local/eXistDB --create-home --system existdb
chmod 0775 /usr/local/eXistDB
sudo su - existdb

Add environmental variables to .bash_profile:

export EXIST_HOME=/opt/local/eXistDB/eXist-current
export RUN_AS_USER=existdb

Then, in the terminal:

source ~/.bash_profile
java -jar /tmp/exist-4.5.0-setup.jar -console

As part of the install process, you'll be asked for a directory path for the newly-installed database. Use /opt/local/eXistDB/eXist-VERSION , where VERSION is the version number. Set the administrator password rather than leaving the field blank.

Create a symlink: `ln -s eXist-VERSION eXist-current`.

Navigate into eXist-current, aka $EXIST_HOME.

Create a backup of $EXIST_HOME/tools/jetty/etc/jetty-http.xml.orig, for example:

cp tools/jetty/etc/jetty-http.xml tools/jetty/etc/jetty-http.xml.orig

Edit the Jetty file and set the HTTP port to 8088 from 8080.

Create a backup of $EXIST_HOME/webapp/WEB-INF/web.xml, then edit it. Set `//init-param[param-name = ('xquery-submission', 'xupdate-submission')]` to "authenticated".

Create a backup of $EXIST_HOME/conf.xml Set `//serializer/@indent` to "no". Set `//indexer/@preserve-whitespace-mixed-content` to "yes". Add Saxon settings to `//transformer[@class eq 'net.sf.saxon.TransformerFactoryImpl']`:

<attribute name="http://saxon.sf.net/feature/recoveryPolicyName"
           value="recoverWithWarnings"
           type="string"/>
<attribute name="http://saxon.sf.net/feature/strip-whitespace"
           value="none"
           type="string"/>

Install eXist as a service

eXist comes with YAJSW, which acts as a wrapper daemon to run eXist automatically on server boot. YAJSW configuration files and scripts can be found at $EXIST_HOME/tools/yajsw.

Create a backup of $EXIST_HOME/tools/yajsw/conf/wrapper.conf. Change "wrapper.app.account" to `existdb\\existdb`. Previous installations have also changed "wrapper.java.command", "wrapper.console.title", "wrapper.ntservice.name", and "wrapper.daemon.pid.dir", but they aren't essential.

As root:

EXIST_HOME=/opt/local/eXistDB/eXist-current RUN_AS_USER=existdb /opt/local/eXistDB/eXist-current/tools/yajsw/bin/installDaemon.sh

You may have the option to run the eXist service through "non-privileged systemd" or "privileged systemV-init". Playground currently (2020-12-04) uses systemd. Not sure what previous installations have used.


November 2019 notes

“playground” is the name Ashley & Syd give to the box they are using for experimentations. (Currently for web stat packages.) This page describes a procedure for installing a CentOS (i.e., RedHat clone) OS on it quickly.

  • Remember to back up iptables and restore it
  • We re-set the clock with instructions from a website we found.