Docstoc

Microsoft PowerPoint - EP_Installation

Document Sample
Microsoft PowerPoint - EP_Installation Powered By Docstoc
					Installation of EPrints software
     and test archive set up
                  Filbert Minj
  National Centre for Science Information
         Indian Institute of Science
           Bangalore – 560 012
     (E-Mail: filbert@ncsi.iisc.ernet.in)
 INDEST-NCSI Workshop on Institutional
                 Repositories,
     IISc, Bangalore, 27-29 July 2004
       Outline of Presentation
• Requirements (H/W, S/W)
• Go through the steps involved in installation
  of Eprints and dependent software
• Demo of Eprints Installation using script
        Requirements - H/W
• For demo purpose
  • Intel Pentium II processor with 64MB RAM
    will give reasonably good performance
• For production system
  • Intel P4 processor
  • 512MB RAM
  • 20Gb of disk space
             Requirements - S/W
•       GNU/Linux (http://www.gnu.org/) works
        just fine.
    •     In fact it is the development platform
    •     We have tested it on red Hat Linux 7.2, 8.0,
          9.0 and Fedora Core 1
•       The Apache WWW server
        (http://www.apache.org/httpd.html)
    Requirements - S/W Cont…
•   The Perl programming language,
    (http://www.perl.com/) also included with most
    GNU/Linux distributions.
•   The mod_perl (http://perl.apache.org/) module
    for Apache, which significantly increases the
    performance of Perl scripts.
•   The MySQL Database
    (http://www.mysql.com/), a free database
    system.
    Requirements - S/W Cont…
•    Some additional perl modules
     (http://www.cpan.org/modules/01modules.index
     .html)
    1.    MIME-Base64-3.01 module
    2.    XML-Parser-2.34 module
    3.    Unicode-String-2.06 module
    4.    CGI.pm-3.04 module
    5.    DBI-1.42 module
    6.    Data-ShowTable-3.3 module
    7.    Msql-Mysql-modules-1.2219
    8.    Parse-RecDescent-1.94
    9.    Tie-IxHash-1.21
    10.   ExtUtils::XSBuilder-0.25
    11.   libapreq2-2.02_02-dev (for Apache 2.0.x) or
          libapreq-1.3 (Apache 1.3.x)
    Requirements - S/W Cont…
•   The EPrints Software
    (http://software.eprints.org/download.php)
    itself.
         Requirements - Packages
• GCC (C/C++ Compiler)
   – Select Development Tools while installing Linux
• Perl
   – Select Development Tools while installing Linux
• Lynx – a text based Internet browser
   – Select Text based Internet
• Image Magic
   – Select Graphics
• LaTex
   – Select Authoring and Publishing
Installation Steps Follows…
   Options- Apache Installation
• Apache 1.3.x
  – mod_perl version 1.2x
  – libapreq-1.3
• Apache 2.0.x
  – mod_perl version 1.99.14 (tobe version 2)
  – libapreq2-2.02_02-dev
         Step-1Apache Installation
                 Cont…
•   tar -zxvf httpd-2.0.49.tar.gz
•   cd httpd-2.0.49
•   ./configure --prefix=/usr/local/apache2 --enable-so
•   make
•   make install
•   Edit /usr/local/apache2/conf/httpd.conf file, locate
    for a line #ServerName www.new.com:80.
    Replace www.new.com with IP address or
    hostname of your machine. Uncomment the line.
      Step-2 Mod_perl (1.99.x)
             installation
• tar -zxvf mod_perl-2.0-current.tar.gz
• cd mod_perl-1.99_14
• perl Makefile.PL
  MP_APXS=/usr/local/apache2/bin/apxs
• make
• make install
• Add a line with the text below in
  /usr/local/apache2/conf/httpd.conf file
   – LoadModule perl_module modules/mod_perl.so
     Step-3 MySQL Installation
• tar -zxvf mysql-standard-4.0.18-pc-linux-
  i686.tar.gz
• mv mysql-standard-4.0.18-pc-linux-i686 mysql
• /usr/sbin/groupadd mysql
   – Create mysql group
• /usr/sbin/useradd -g mysql mysql
   – Create mysql user to run MySQL server
• Go to mysql directory
   – (#cd mysql)
• scripts/mysql_install_db
   – Run script to install MySQL database
    Step-3 MySQL Installation
            Cont…
• chown -R mysql.mysql data
  – change the ownership and group of data
    directory to mysql
• chown -R root *
• chgrp -R mysql *
• bin/mysqld_safe --user=mysql &
  – Start MySQL server
    Step-4 MySQL perl module
• tar -zxvf Msql-Mysql-modules-1.2219.tar.gz
• cd Msql-Mysql-modules-1.2219
• perl Makefile.PL --noprompt --nomsql-install --
  nomsql1-install
• cd mysql
• perl Makefile.PL
• make
• make install
  Step-5 libapreq2-2.02_02-dev
             module
• tar -zxvf libapreq2-2.02_02-dev.tar.gz
• cd libapreq2-2.02-dev
• perl Makefile.PL --with-apache2-
  apxs=/usr/local/apache2/bin/apxs
• make
• make install
      Step-6 Installing other Perl
               modules
•   tar -zxvf modulename-version-no.tar.gz
•   cd modulename-version-no
•   perl Makefile.PL
•   make
•   make install
         Step-7 EPrints software
               Installation
• /usr/sbin/groupadd eprints
    – Create eprints group
• /usr/sbin/useradd -g eprints -d /opt/eprints2
    – Create eprints user
•   tar -zxvf eprints-2.3.4.tar.gz
•   cd eprints-2.3.4
•   ./configure --with-apache=2 --disable-diskfree
•   ./install.pl
 EPrints Archive configuration
• su –l eprints (become eprints user)
• bin/configure_archive
• Inputs to be given:
   – Archive ID:
      • This is unique internal ID in EPrints
      • This could be combination of alphabets and numbers starts
        with alphabets
      • Space char is not allowed
      • e.g. IISc, Indest, Demo, test etc.
   – Hostname: IP No. or hostname of your machine
     (e.g.:144.16.72.203 or www.iisc.ernet.in)
   – Webserver Port: Enter default
   – Alias: Enter default
    EPrints Archive configuration
               Cont…
• Administrator Email :
• Archive name:
    – Enter Archive name which will be displayed in the
      home page of Eprints Archive (e.g. ePrints@IISc)
•   Database name: Accept default
•   MySQL host: Accept default
•   MySQL Port: Accept default
•   MySQL Socket: Accept default
•   Database user: Enter eprints
•   Database password: Enter eprints
  EPrints Archive configuration
             Cont…
• Create Database: Enter default
• MySQL root password: Enter default (Enter
  password if MySQL password is set)
• Create config files: Enter default
• bin/create_tables <ArchiveID>
• unset LANG
• bin/import_subjects <ArchiveID>
  – Continue (yes/no): Enter yes
• bin/generate_static <ArchiveID>
   EPrints Archive configuration
              Cont…
• bin/generate_apacheconf
• bin/create_user <ArchiveID> <username> <email>
  admin <password>
   – e.g. bin/create_user iisc admin eprints@localhost admin
     admin
• bin/generate_views <ArchiveID>
   – Generates browse views
• bin/ indexer start
   – Starting indexer for full text search feature
• In case creation of archive fails then use the
  command below to erase the archive and repeat the
  steps archive configuration
• bin/erase_archive <ArchiveID>
     Editing httpd.conf file and
     starting apache web server
• Open /usr/local/apache2/conf/httpd.conf file
• Replace default user and group with eprints
• Add a line with the text below
  – Include /opt/eprints2/cfg/apache.conf
• /usr/local/apache2/bin/apachectl start
  – Start apache web server
Automatic Execution of required
           scripts
• When new documents added browse view
  has to generated from eprints account
• crontab –e
• mm(0-59) hh(0-23) dayofmo(1-31)
  monthofyear(1-12) dayofweek(0-6 with
  0=Sunday)       command
• * 1 * * * /opt/eprints2/bin/generate_views
  <ArchiveID>
   To operate the subscriptions
         (alert service)
• 0 0 * * * /opt/eprints/bin/subs_daily
• 15 0 * * 0 /opt/eprints/bin/subs_weekly
• 30 0 1 * * /opt/eprints/bin/subs_monthly
    Starting Apache and MySQL at
               boot time
•    cp /usr/local/apache2/bin/apachectl /etc/init.d/
    –   chkconfig --add apachectl
•    cp /usr/local/mysql/support-files/mysql.server
     /etc/init.d/
    –   chkconfig --add mysql.server
•    If the above chkconfig does not work
    –   cd /etc/rc3.d OR cd /etc/rc.d/rc3.d
    –   ln –s ../init.d/apachectl S85httpd
    –   ln –s ../init/mysql.server S99mysqld
Installing EPrints using Script
developed at NCSI (by Filbert
       and Ramnishath)
    Requirements for the script
• bash shell required (default shell in Linux)
• APACHE (HTTP Server) should not be
  running (if running please stop it using the
  command (#/etc/init.d/httpd stop)).
• MySQL should not be running. (if running
  please stop it using the command
  (#/etc/init.d/mysqld stop)).
     Requirements for the script
             Cont…
• Around 155 MB hard disk space should be
  available in any directory to copy and to make all
  the dependent software.
   – Note: Dependent software takes 35 MB hard disk
     space.
• Around 150 MB hard disk space should be
  available in /usr/local file system to install
  APACHE and MySQL.
   – Note: APACHE will get installed in /usr/local/apache2
     and MySQL will get installed in /usr/local/mysql
     directory.
     Requirements for the script
             Cont…
• Around 6 MB hard disk space should be
  available in root (/) file system to install
  EPrints software.
   – Note: EPrints software gets installed in
     /opt/eprints2.
  Installing EPrints using Script
• Run the script (./eprints_install.sh or sh
  eprints_install.sh)
• It will ask many inputs to given
• Takes around 30 minutes in a P-III machine

				
DOCUMENT INFO