Annotation of doc/build/install.html, revision 1.17

1.17    ! harris41    1: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
        !             2:  "http://www.w3.org/TR/html4/loose.dtd">
1.11      harris41    3: <!-- The LearningOnline Network with CAPA -->
1.17    ! harris41    4: <!-- $Id: install.html,v 1.16 2002/04/23 13:04:54 harris41 Exp $ -->
1.11      harris41    5: <html>
                      6: <head>
                      7: <title>LON-CAPA Installation</title>
1.12      harris41    8: <!-- pdfahref install.pdf -->
                      9: <!-- button INSTALL -->
1.11      harris41   10: </head>
1.12      harris41   11: <body bgcolor='#ffffff'>
                     12: <!-- preamble start -->
                     13: <br />&nbsp;
                     14: <p>
                     15: You will need to check all the following things to ensure proper
                     16: installation of your LON-CAPA system.
                     17: <ul>
1.13      harris41   18: <li><a href="#wwwuser">
                     19: Creating a user 'www'</a></li>
                     20: <li><a href="#shadow">
1.12      harris41   21: Make a LON-CAPA system work with shadow passwords</a></li>
1.13      harris41   22: <li><a href="#install">
                     23: Installing LON-CAPA files</a></li>
                     24: <li><a href="#checkrpms">
                     25: Checking your Linux RPMs</a></li>
                     26: <li><a href="#mysql">
                     27: Configuring the MySQL database</a></li>
1.15      harris41   28: <li><a href="#testing">
                     29: Testing to see if the LON-CAPA server is operational</a></li>
1.12      harris41   30: </ul>
                     31: <br />&nbsp;
                     32: <!-- preamble end -->
                     33: <!-- maintext start -->
1.13      harris41   34: <a name="wwwuser" />
                     35: <h3>Creating a user 'www'</h3>
                     36: <p>
1.14      harris41   37: Execute the following command to create a user named 'www' on your
                     38: LON-CAPA server:
1.13      harris41   39: </p>
1.14      harris41   40: <table bgcolor="#aaaaaa" border="1"><tr><td>
                     41: <tt>/usr/sbin/useradd www</tt>
                     42: </td></tr></table>
1.13      harris41   43: <a name="shadow" />
1.12      harris41   44: <h3>Make a LON-CAPA system work with shadow passwords</h3>
                     45: <p>
1.14      harris41   46: <table border="1">
1.12      harris41   47: <tr><th>Step #</th><th>Description</th></tr>
                     48: <tr><td>
1.14      harris41   49: <font size="+1">1</font>
1.12      harris41   50: </td><td>
                     51: <p>Is your system using shadow passwords? (Note: LON-CAPA will
                     52: work with either MD5/non-MD5 configured systems).  If your
                     53: system is not using shadow passwords, then do not perform
                     54: any of the additional steps.  If your system is using shadow
                     55: passwords, then you will need to perform the additional steps below.
                     56: </p>
                     57: <p>
                     58: <strong>How to detect:</strong>
                     59: <br />command: <tt>cat /etc/passwd | grep ':x:'</tt>
                     60: </p>
                     61: <p>If there is output such as "<tt>root:x:0:0:root:/root:/bin/bash</tt>",
                     62: then your system is using shadow passwords and you will need to continue with
                     63: the steps below.
                     64: </p>
                     65: </td></tr>
                     66: <tr><td>
                     67: <font size='+1'>2</font>
                     68: </td><td>
                     69: <p><strong>Retrieve the mod_auth_external source</strong> by
                     70: running the following command
                     71: </p>
                     72: <p><tt>
                     73: wget http://www.wwnet.net/~janc/software/mod_auth_external-2.1.13.tar.gz
                     74: </tt>
                     75: </p>
                     76: </td></tr>
1.13      harris41   77: <tr><td>
                     78: <font size='+1'>3</font>
                     79: </td><td>
1.17    ! harris41   80: <p><strong>Unpack the mod_auth_external source</strong> by
        !            81: running the following command
        !            82: </p>
        !            83: <p>
        !            84: <tt>tar xzvf mod_auth_external-2.1.13.tar.gz</tt>
        !            85: </p>
        !            86: </td></tr>
        !            87: <tr><td>
        !            88: <font size='+1'>4</font>
        !            89: </td><td>
        !            90: <p><strong>Go to the <tt>pwauth</tt> directory</strong> by
        !            91: running the following command
        !            92: </p>
        !            93: <p>
        !            94: <tt>cd mod_auth_external-2.1.13/pwauth/</tt>
        !            95: </p>
        !            96: </td></tr>
        !            97: <tr><td>
        !            98: <font size='+1'>5</font>
        !            99: </td><td>
        !           100: <p><strong>Edit <tt>config.h</tt> and change SERVER_UIDS definition</strong>
        !           101: </p>
        !           102: <p>
        !           103: Determine the user id of 'www':
        !           104: <br /><tt>grep ^www /etc/passwd | cut -d':' -f3</tt>
        !           105: <br />
        !           106: Change the line
        !           107: <br /><tt>#define SERVER_UIDS 99       /* user "nobody" */</tt>
        !           108: <br />to be
        !           109: <br /><tt>#define SERVER_UIDS 513      /* user "www" */</tt>
        !           110: <br />where in this example 513 corresponds to the user id of 'www'.
1.13      harris41  111: </p>
1.17    ! harris41  112: </td></tr>
        !           113: <tr><td>
        !           114: <font size='+1'>6</font>
        !           115: </td><td>
        !           116: <p><strong>Compile the <tt>pwauth</tt> executable</strong> by
        !           117: running the following command
        !           118: </p>
        !           119: <p>
        !           120: <tt>make</tt>
        !           121: </p>
        !           122: </td></tr>
        !           123: <tr><td>
        !           124: <font size='+1'>7</font>
        !           125: </td><td>
        !           126: <p><strong>Install <tt>pwauth</tt></strong> by doing the following
        !           127: </p>
        !           128: <p>
        !           129: <tt>cp pwauth /usr/local/sbin/</tt>
        !           130: <br /><tt>chmod 6755 /usr/local/sbin/pwauth</tt>
        !           131: </p>
        !           132: <p>
        !           133: Edit (creating the file) /etc/pam.d/pwauth to have the contents:
        !           134: <pre>
        !           135:         auth       required     /lib/security/pam_pwdb.so shadow nullok
        !           136:         auth       required     /lib/security/pam_nologin.so
        !           137:         account    required     /lib/security/pam_pwdb.so
        !           138: </pre>
1.13      harris41  139: </p>
                    140: </td></tr>
                    141: </table>
                    142: </p>
                    143: <a name="install" />
                    144: <h3>Installing LON-CAPA files</h3>
                    145: <p>
                    146: Download the most current
                    147: <a href="http://install.lon-capa.org/versions/current/loncapa.tar.gz">
                    148: loncapa.tar.gz</a>.
                    149: </p>
1.14      harris41  150: <p>
                    151: The <strong>UPDATE</strong> command will refresh your filesystem with all
                    152: the latest LON-CAPA software.
                    153: </p>
                    154: <table bgcolor="#aaaaaa" border="1">
                    155: <tr><td><tt>./UPDATE</tt></td></tr>
                    156: </table>
1.13      harris41  157: <a name="checkrpms" />
                    158: <h3>Checking your Linux RPMs</h3>
                    159: <p>
1.14      harris41  160: The <strong>CHECKRPMS</strong> command will check the RPMs on your machine
                    161: against an FTP repository.
1.13      harris41  162: </p>
1.14      harris41  163: <table bgcolor="#aaaaaa" border="1">
1.13      harris41  164: <tr><td><tt>./CHECKRPMS</tt></td></tr>
1.12      harris41  165: </table>
1.13      harris41  166: <a name="mysql" />
                    167: <h3>Configuring the MySQL database</h3>
                    168: <p>
                    169: The following commands describe how to configure the MySQL database
                    170: on your LON-CAPA server.
1.12      harris41  171: </p>
1.14      harris41  172: <table bgcolor="#aaaaaa" border="1"><tr><td>
1.13      harris41  173: <pre>
                    174: Enter the mysql shell---
                    175: mysql -u root -p mysql
                    176: 
                    177: Run these commands---
                    178: CREATE DATABASE loncapa;
                    179: 
                    180: INSERT INTO user (Host, User, Password)
                    181: VALUES ('localhost','www',password('SOMEPASSWORD'));
                    182: 
                    183: GRANT ALL PRIVILEGES ON *.* TO www@localhost;
                    184: 
                    185: FLUSH PRIVILEGES;
                    186: 
                    187: shell> mysql -u root mysql
                    188: mysql> SET PASSWORD FOR root@localhost=PASSWORD('new_password');
                    189: </pre>
                    190: </td></tr></table>
1.15      harris41  191: <a name="testing" />
                    192: <h3>Testing to see if the LON-CAPA server is operational</h3>
                    193: <p>
                    194: The <strong>TEST</strong> command will check the installation software,
                    195: the perl libraries on your system, the MySQL database, and
                    196: will also automatically test the real-time operation of the 
                    197: LON-CAPA Apache web server.
                    198: </p>
                    199: <table bgcolor="#aaaaaa" border="1">
                    200: <tr><td><tt>./TEST</tt></td></tr>
                    201: </table>
1.16      harris41  202: <p>
                    203: Using the <strong>TEST</strong> command will likely
                    204: be an iterative process.
                    205: It is normal to expect that the <strong>TEST</strong> command
                    206: will recommend you perform various steps to ensure optimal
                    207: performance of your LON-CAPA server.
                    208: </p>
1.12      harris41  209: <!-- maintext end -->
1.11      harris41  210: </body>
                    211: </html>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>