L1te:Stage 4 install

Contents

[hide]

Installing L1te from a Gentoo Stage 4 image

Hardware requirements

  • Lots of disk space

Here's how to install L1te from a Gentoo Stage 4 image.

  1. Fetch the stage 4 image from L1te
  2. Follow the Stage 4 instructions on Gentoo Wiki site

Following the instructions on step 2 will require you to follow a few guidelines I will set here:

I used the following partition scheme for a 160 gig drive:

/boot - 64M
swap - 1G
/ - 2G
/home - 5G
/usr - 10G
/var - 10G
/tmp - 5G
/var/lib/mysql - 70G
/var/lib/l1te - 40G

You will want much larger drives than the above. If storing mainly text reports, the /var/lib/mysql directory will need to be large. If storing mainly scanned images, the /var/lib/l1te directory will need to be large. A space of 500 gigs each is not unreasonable for a large installation.

I made the following directories LVM mounts:

/home
/usr
/var
/tmp
/var/lib/mysql
/var/lib/l1te

Please format them with ReiserFS (example: mkreiserfs /dev/vg/home). If you want to use a different file system (i.e. JFS, XFS, etc), you will have to make sure the filesystem tools are emerged as ReiserFS tools and ext3 tools are the only ones on the stage 4 image.

After everything is up and running, please do the following:

  • Change the root password (currently pass123). You could probably do this during the Stage 4 install too.
  • Set up the MySQL database password (currently blank. Do NOT leave it blank!!!)
  • Configure L1te for your install. Most of the settings you will change are in /var/www/localhost/config/config.php.

For Ultradata Clients

You will need to configure a few variables in the config.php file. This file will be in /var/www/localhost/config/config.php. Edit it with your favorite text editor and change these variables to match your site:

$ftp_host =         "192.168.1.1";
$reportdir =        "/data/xxCU/_HOLD_";
$ftp_user =         "ftpuser";
$ftp_passwd =       "ftppass";

For OSI Clients

The file uploads/new_osi_parse.php contains the OSI branch server to L1te code. This file will need two things:

  1. All of your branch servers mounted on the L1te server in a central spot.
    • Try /mnt/OSI/branchservername for each branch server
  2. The $osi_servers array will need updating with your branch server name and description
$osi_servers = array(
    array('server'   => 'branch1',
          'location' => 'Branch One'),
    array('server'   => 'branch2', 
          'location' => 'Branch Two'),
    array('server'   => 'branch3',
          'location' => 'Branch Three')
    );

Set up cron entries

This is where you will set up the frequency of how often report sources are checked.

Note that before you enable the crontabs for these jobs, run them a time or three on the command line to make sure they function as intended.

Execute sudo crontab -e and enter the following lines:

# for all clients
*/10 * * * * /usr/bin/php /var/www/localhost/htdocs/modules/dropbox/cron_dropbox.php >> /tmp/l1teparse.log
# for OSI clients only
*/20 * * * * /usr/bin/php /var/www/localhost/uploads/new_osi_parse.php 2>&1 >> /tmp/osi_parse_log

The log files should be checked for the first few days. After that, you can use logrotate on the log files.

Integrate the logins into your environment

There are a few template files in the config directory that can be used for integrating L1te into your environment. Currently there exists the following:

  • l1te_auth.php
    • This is a stand alone authentication model, which can be fed via another system. Several clients use this with values from their UNIX systems.
  • ldap_include.php
    • This will attempt to authenticate via an LDAP source. This file will need parameters configured, such as your LDAP server, your search domain, etc. It has been tested against Microsoft's Active Directory and OpenLDAP.

How to customize L1te logins into your environment

The following functions do the login / permission / etc tasks:

  • l1te_log_in($user, $pass)
    • Takes the username and password (in that order).
    • Returns true on login or false on failed login
  • l1te_in_group($user, $group)
    • Takes the user name and group name
    • Returns true if the user is in the group, false if not
  • l1te_get_employee_info($user)
    • Returns an array with the following data:
      • Employee Number (so an employee can pull up their own documents)
      • Display Name (for a more friendly approach)
      • Email address (currently unused)
  • l1te_check_member($member)
    • Checks to see if the member number supplied is in the employee database so only authorized employees can view sensitive documents
    • Returns false if the member number supplied is an employee
  • l1te_get_group_members($group)
    • Returns an array of all the users in the specified group (currently unused)
  • l1te_file_owner($uid)
    • Fetches the owner name from a user ID (currently unused)
  • l1te_get_permission($user)
    • Returns the specified user's permission level (0-9)
    • If not found, returns the default permission defined in config.php
  • l1te_log_out()
    • Logs the user out of L1te
  • failed_login($message)
    • Sends failed login messages to the error page

Save the resulting file in the config directory, and edit the config.php file to include your new file.

Views
Personal tools
Navigation
Toolbox