Project

General

Profile

Revision 8265

Refer to metacat.war deployments since those are now the default. https://projects.ecoinformatics.org/ecoinfo/issues/6082

View differences:

install.rst
58 58
3. Log in to PostgreSQL and create the 'metacat' user
59 59
4. Download Metacat from the `Metacat Download Page`_ and extract the archive
60 60
5. ``sudo mkdir /var/metacat; sudo chown -R <tomcat_user> /var/metacat``
61
6. ``sudo cp <metacat_package_dir>/knb.war <tomcat_app_dir>``
61
6. ``sudo cp <metacat_package_dir>/metacat.war <tomcat_app_dir>``
62 62
7. ``sudo /etc/init.d/tomcat6 restart``
63 63
8. Configure Metacat through the Web interface
64 64

  
......
98 98
================== ===========================================================
99 99
File               Description
100 100
================== ===========================================================
101
knb.war            The Metacat Web archive file (WAR) 
102
knb                Sample Web definition file used by Apache on Ubuntu/Debian 
101
metacat.war        The Metacat Web archive file (WAR) 
102
metacat-site       Sample Web definition file used by Apache on Ubuntu/Debian 
103 103
                   Linux systems. 
104
knb.ssl            Sample SSL definition file used by Apache on Ubuntu/Debian 
104
metacat-site-ssl   Sample SSL definition file used by Apache on Ubuntu/Debian 
105 105
                   Linux systems.
106 106
jk.conf            Sample JkMount configuration file used by Apache on 
107 107
                   Ubuntu/Debian Linux systems. 
......
278 278
        ServerName dev.nceas.ucsb.edu 
279 279
        ErrorLog /var/log/httpd/error_log 
280 280
        CustomLog /var/log/httpd/access_log common 
281
        ScriptAlias /cgi-bin/ "/var/www/cgi-knb/" 
282
        <Directory /var/www/cgi-knb/> 
281
        ScriptAlias /cgi-bin/ "/var/www/cgi-bin/" 
282
        <Directory /var/www/cgi-bin/> 
283 283
          AllowOverride None 
284 284
          Options ExecCGI 
285 285
          Order allow,deny 
286 286
          Allow from all 
287 287
        </Directory> 
288
        ScriptAlias /knb/cgi-bin/ "/var/www/webapps/knb/cgi-bin/" 
289
        <Directory "/var/www/webapps/knb/cgi-bin/"> 
288
        ScriptAlias /metacat/cgi-bin/ "/var/www/webapps/metacat/cgi-bin/" 
289
        <Directory "/var/www/webapps/metacat/cgi-bin/"> 
290 290
          AllowOverride None 
291 291
          Options ExecCGI 
292 292
          Order allow,deny 
293 293
          Allow from all 
294 294
        </Directory> 
295
        JkMount /knb ajp13 
296
        JkMount /knb/* ajp13 
297
        JkMount /knb/metacat ajp13 
298
        JkUnMount /knb/cgi-bin/* ajp13 
299
        JkMount /*.jsp ajp13 
300 295
        JkMount /metacat ajp13 
301 296
        JkMount /metacat/* ajp13 
297
        JkMount /metacat/metacat ajp13 
298
        JkUnMount /metacat/cgi-bin/* ajp13 
299
        JkMount /*.jsp ajp13 
302 300
      </VirtualHost> 
303 301

  
304 302
  3. Copy the "workers.properties" file provided by Metacat into your Apache configuration directory (<apache_install_dir>/conf/).  Depending on whether you are installing from binary distribution or source, the workers.properties file will be in one of two locations:
......
352 350
  sudo a2dismod jk
353 351
  sudo a2enmod jk
354 352

  
355
4. Apache needs to know about the Metacat site. The helper file named "knb" has rules that tell Apache which traffic to route to Metacat. Set up the knb (Metacat) site by dropping the knb file into the sites-available directory and running a2ensite to enable the site:
353
4. Apache needs to know about the Metacat site. The helper file named "metacat-site" has rules that tell Apache which traffic to route to Metacat. Set up Metacat site by dropping the metacat-site file into the sites-available directory and running a2ensite to enable the site:
356 354

  
357 355
::
358 356

  
359
  sudo cp <metacat_helper_dir>/knb <apache_install_dir>/sites-available
360
  sudo a2ensite knb
357
  sudo cp <metacat_helper_dir>/metacat-site <apache_install_dir>/sites-available
358
  sudo a2ensite metacat-site
361 359
  
362 360
5. Disable the default Apache site configuration:
363 361

  
......
535 533
    sudo chown -R <tomcat_user> /var/metacat
536 534

  
537 535

  
538
3.  Install the Metacat WAR in the Tomcat web-application directory. For instructions on downloading the Metacat WAR, please see Downloading Metacat.  Typically, Tomcat will look for its application files (WAR files) in the <tomcat_home>/webapps directory (e.g., /usr/share/tomcat6/webapps). Your instance of Tomcat may be configured to look in a different directory. We will refer to the Tomcat application directory as <tomcat_app_dir>.  NOTE: The name of the WAR file (e.g., knb.war) provides the application context, which appears in the URL of the Metacat (e.g., http://yourserver.com/knb/). To change the context, simply change the name of the WAR file to the desired name before copying it.  To install the Metacat WAR:
536
3.  Install the Metacat WAR in the Tomcat web-application directory. For instructions on downloading the Metacat WAR, please see Downloading Metacat.  Typically, Tomcat will look for its application files (WAR files) in the <tomcat_home>/webapps directory (e.g., /usr/share/tomcat6/webapps). Your instance of Tomcat may be configured to look in a different directory. We will refer to the Tomcat application directory as <tomcat_app_dir>.  NOTE: The name of the WAR file (e.g., metacat.war) provides the application context, which appears in the URL of the Metacat (e.g., http://yourserver.com/metacat/). To change the context, simply change the name of the WAR file to the desired name before copying it.  To install the Metacat WAR:
539 537

  
540 538
  ::
541 539

  
542
    sudo cp <metacat_package_dir>/knb.war <tomcat_app_dir>
540
    sudo cp <metacat_package_dir>/metacat.war <tomcat_app_dir>
543 541

  
544 542

  
545 543
4. Restart Tomcat. Log in as the user that runs your Tomcat server (often "tomcat") and type:  
......
578 576

  
579 577
  ::
580 578

  
581
    cp <web_app_dir>/knb <backup_dir>/knb.<yyyymmdd>
582
    cp <web_app_dir>/knb.war <backup_dir>/knb.war.<yyyymmdd>
579
    cp <web_app_dir>/metacat <backup_dir>/metacat.<yyyymmdd>
580
    cp <web_app_dir>/metacat.war <backup_dir>/metacat.war.<yyyymmdd>
583 581

  
584 582
  Warning: Do not backup the files to the ``<web_app_dir>`` directory.  Tomcat will
585 583
  try to run the backup copy as a service.
......
588 586

  
589 587
  ::
590 588

  
591
    sudo cp <metacat_package_dir>/knb.war <tomcat_app_dir>
589
    sudo cp <metacat_package_dir>/metacat.war <tomcat_app_dir>
592 590

  
593 591
  Note: Typically, Tomcat will look for its application files (WAR files) in the
594 592
  ``<tomcat_home>/webapps`` directory. Your instance of Tomcat may be configured to
......
615 613
    http://yourserver.yourdomain.com/yourcontext/
616 614

  
617 615
You should substitute your context name for "yourcontext" in the URL above
618
(your context will be "knb" unless you change the name of the knb.war file to
616
(your context will be "metacat" unless you change the name of the metacat.war file to
619 617
something else). If everything is working correctly, you should be presented
620 618
with Metacat's Authorization Configuration screen. Note that if you do not have
621 619
Tomcat integrated with Apache you will probably have to type
......
648 646
  You will see the individual modules get built. You should see a "BUILD
649 647
  SUCCESSFUL" message at the end.
650 648

  
651
  You should see a new file named knb.war in your application deployment
649
  You should see a new file named metacat.war in your application deployment
652 650
  directory.
653 651

  
654 652
To run your new Metacat servlet, open a Web browser and type::
655 653

  
656 654
  http://yourserver.yourdomain.com/yourcontext/ 
657
  (e.g.  http://knb.ecoinformatics.org/knb/)
655
  (e.g.  http://knb.ecoinformatics.org/metacat/)
658 656

  
659
Your context will be "knb" unless you changed the name of the knb.war file to
657
Your context will be "metacat" unless you changed the name of the metacat.war file to
660 658
something else. The servlet may require a few seconds to start up, but once it
661 659
is running, you will be presented with the Authorization Configuration screen.
662 660

  
......
952 950

  
953 951
  ::
954 952
  
955
    Psql ���������U metacat ���������W ���������h localhost metacat
953
    psql -U metacat -W -h localhost metacat
956 954

  
957 955
10. Exit PostgreSQL:
958 956

  
......
986 984
  
987 985
  ::
988 986

  
989
    copy <metacat_package_dir>\knb.war C:\Program Files\tomcat\webapps
987
    copy <metacat_package_dir>\metacat.war C:\Program Files\tomcat\webapps
990 988

  
991 989
3.  Restart Tomcat: 
992 990

  
......
1012 1010

  
1013 1011
  ::
1014 1012

  
1015
    <web_app_dir>/knb to <backup_dir>/knb.<yyyymmdd>
1016
    <web_app_dir>/knb.war to <backup_dir>/knb.war.<yyyymmdd>
1013
    <web_app_dir>/metacat to <backup_dir>/metacat.<yyyymmdd>
1014
    <web_app_dir>/metacat.war to <backup_dir>/metacat.war.<yyyymmdd>
1017 1015

  
1018
  Warning: Do not backup the knb directory in the <web_app_dir> directory.
1016
  Warning: Do not backup the metacat directory in the <web_app_dir> directory.
1019 1017
  Tomcat will try to run the backup copy as a service.
1020 1018

  
1021 1019
3.  Copy the new Metacat WAR file in to Tomcat applications directory: 
1022 1020

  
1023 1021
  ::
1024 1022

  
1025
    copy knb.war C:\Program Files\tomcat\webapps
1023
    copy metacat.war C:\Program Files\tomcat\webapps
1026 1024

  
1027 1025
4.  Restart Tomcat: 
1028 1026
  

Also available in: Unified diff