Difference between revisions of "SUNScholar/Install DSpace/S08"

From Libopedia
Jump to navigation Jump to search
 
(113 intermediate revisions by one other user not shown)
Line 1: Line 1:
 
<center>
 
<center>
  '''[[SUNScholar/Install Dspace|Install DSpace - Index]]'''
+
  '''[[SUNScholar/Install DSpace/S09|NEXT - STEP 9]]'''
 
</center>
 
</center>
 +
===<font color="red">PLEASE NOTE:</font>===
 +
# *** ''This procedure is completely different from the official DSpace documentation, in that it applies best system admin practice for Unix based systems'' ***
 +
#This procedure does <u>NOT</u> require "mod_jk" or Apache2 port re-direction with firewall rules <u>or the Apache2 server</u>.
  
 
==Step 8. Enable the DSpace Java webapps on the Java Tomcat webapp server==
 
==Step 8. Enable the DSpace Java webapps on the Java Tomcat webapp server==
The DSpace webapps have been compiled in the '''/home/dspace/webapps''' folder but Tomcat only serves up webapps in the '''/var/lib/tomcat6/webapps''' folder.
+
The DSpace webapps have been compiled in the '''$HOME/webapps''' folder but Tomcat only serves up webapps in the '''/var/lib/tomcatX/webapps''' folder.
  
So, how do we get all the files into the Tomcat webapps folder ?
+
So, how do we get all the files into the Tomcat webapps folder?
  
There are several methods, but we are going to set it up so that if you change anything in the DSpace '''/home/dspace/webapps''' folder and re-compile then the changes automatically occur in the Tomcat '''/var/lib/tomcat6/webapps''' folder.
+
There are several methods. I selected what I call the "automatic linkage" method: if you change anything in the DSpace '''$HOME/webapps''' folder and then re-compile, the changes automatically occur in the Tomcat '''/var/lib/tomcatX/webapps''' folder.
  
We create the shortcuts to the DSpace webapps in the default Tomcat webapps folder by typing as follows:
+
''This method saves you from constantly having to copying webapps after a compile, which is always a risky business.''
  
sudo cd /var/lib/tomcat6/webapps
+
''It also saves you from having to change the Tomcat server configuration files, which is '''very definitely not recommended''' by the Debian/Ubuntu software package maintainers.''
  
  sudo ln -s /home/dspace/webapps/oai
+
==Requirements==
 +
  <font color="red">'''Please make sure that Tomcat is listening on port 80 first, before setting this up. See link below.</font>'''
 +
http://wiki.lib.sun.ac.za/index.php/SUNScholar/Prepare_Ubuntu/S05
 +
==[[SUNScholar/Install_DSpace/S08/Ubuntu-16.04|For Ubuntu 16.04 LTS]]==
 +
==[[SUNScholar/Install_DSpace/S08/Ubuntu-14.04|For Ubuntu 14.04 LTS]]==
 +
==[[SUNScholar/Install_DSpace/S08/Ubuntu-12.04|For Ubuntu 12.04 LTS]]==
 +
==References==
 +
* http://rspproject.wordpress.com/2011/03/22/running-dspace-on-a-root-url
  
sudo ln -s /home/dspace/webapps/solr
+
<center>
 
+
  '''[[SUNScholar/Install DSpace/S07|PREVIOUS - STEP 7]]'''
sudo ln -s /home/dspace/webapps/sword
+
</center>
 
 
sudo ln -s /usr/share/tomcat6-admin/manager
 
 
 
===Step 8.1 Configure the default ROOT webapp===
 
DSpace has two web interfaces, the XMLUI and the JSPUI. This procedure allows you to select which inteface will be used as the ROOT webapp. In other words, the one that does not need a /XMLUI or a /JSPUI URL addition.
 
 
 
Start by removing the default Tomcat ROOT webapp with the following command:
 
sudo rm -rf /var/lib/tomcat6/webapps/ROOT
 
Then apply one of the following.
 
*'''<font color="red">Please note: You can only choose one option.</font>'''
 
====Option A: Type the following to make the XMLUI the default interface.====
 
sudo cd /var/lib/tomcat6/webapps
 
 
 
sudo ln -s /home/dspace/webapps/xmlui ROOT
 
 
 
====Option B: Type the following to make the JSPUI the default interface.====
 
sudo cd /var/lib/tomcat6/webapps
 
 
 
sudo ln -s /home/dspace/webapps/jspui ROOT
 
 
 
Previously we ran both the XMLUI and JSPUI and now only run the XMLUI as the ROOT interface. The JSPUI seemed to consume a lot of memory.
 
 
 
[[File:Sunscholar-memory-year.png]]
 
 
 
===Step 8.2 Restart Tomcat Server===
 
Type the following.
 
sudo /etc/init.d/tomcat6 restart
 
 
 
==Example listing of DSpace Java webapps in the Tomcat webapp folder==
 
<pre>
 
root@ir1:/var/lib/tomcat6/webapps# ls -l
 
total 7732
 
lrwxrwxrwx 1 tomcat6 tomcat6      33 2011-07-04 20:54 manager -> /usr/share/tomcat6-admin/manager/
 
lrwxrwxrwx 1 tomcat6 tomcat6      25 2011-07-04 20:54 oai -> /home/dspace/webapps/oai/
 
drwxr-xr-x 7 tomcat6 tomcat6    4096 2012-02-27 14:00 probe
 
-rw-r--r-- 1 tomcat6 tomcat6 7909476 2012-02-27 14:00 probe.war
 
lrwxrwxrwx 1 tomcat6 tomcat6      27 2011-07-04 20:54 ROOT -> /home/dspace/webapps/xmlui/
 
lrwxrwxrwx 1 tomcat6 tomcat6      25 2011-12-12 13:48 solr -> /home/dspace/webapps/solr/
 
lrwxrwxrwx 1 tomcat6 tomcat6      27 2011-07-04 20:54 sword -> /home/dspace/webapps/sword/
 
</pre>
 
  '''[[SUNScholar/Install Dspace/S07|PREVIOUS]]'''
 
  
'''[[SUNScholar/Install Dspace/S09|NEXT]]'''
+
[[Category:Installation]]
 +
__NOTOC__

Latest revision as of 14:35, 30 October 2019

NEXT - STEP 9

PLEASE NOTE:

  1. *** This procedure is completely different from the official DSpace documentation, in that it applies best system admin practice for Unix based systems ***
  2. This procedure does NOT require "mod_jk" or Apache2 port re-direction with firewall rules or the Apache2 server.

Step 8. Enable the DSpace Java webapps on the Java Tomcat webapp server

The DSpace webapps have been compiled in the $HOME/webapps folder but Tomcat only serves up webapps in the /var/lib/tomcatX/webapps folder.

So, how do we get all the files into the Tomcat webapps folder?

There are several methods. I selected what I call the "automatic linkage" method: if you change anything in the DSpace $HOME/webapps folder and then re-compile, the changes automatically occur in the Tomcat /var/lib/tomcatX/webapps folder.

This method saves you from constantly having to copying webapps after a compile, which is always a risky business.

It also saves you from having to change the Tomcat server configuration files, which is very definitely not recommended by the Debian/Ubuntu software package maintainers.

Requirements

Please make sure that Tomcat is listening on port 80 first, before setting this up. See link below.
http://wiki.lib.sun.ac.za/index.php/SUNScholar/Prepare_Ubuntu/S05

For Ubuntu 16.04 LTS

For Ubuntu 14.04 LTS

For Ubuntu 12.04 LTS

References

PREVIOUS - STEP 7