Categories: Install Notes, Service Control Scripts

Pages: 1 2 3 4 5 6 7 >>

08/18/04

Permalink 07:56:23 am, by admin Email , 531 words   English (US)
Categories: Apache, Install Notes

AWStats

AWStats
http://awstats.sourceforge.net/

Goal: Install AWStats 5.9 on a Sun Cobalt server and configure to auto
generate reports for all virtual domains hosted on the server.

Note: Also tested on FreeBSD 4.9-RELEASE with AWStats 6.1

1. Verify Apache version ...

> httpd -v
Server version: Apache/1.3.20 Sun Cobalt (Unix)
Server built:   Jul 23 2001 14:55:10

On FreeBSD used:

> /www/apache/bin/httpd -v
Server version: Apache/1.3.26 (Unix)
Server built:   Aug 27 2002 01:38:46

2. Verify shared module support ...

> httpd -l
Compiled-in modules:
  http_core.c
  mod_so.c
  mod_perl.c
suexec: enabled; valid wrapper /usr/sbin/suexec

On FreeBSD:

>/www/apache/bin/httpd -l
Compiled-in modules:
  http_core.c
  mod_so.c
suexec: disabled; invalid wrapper /www/apache/bin/suexec

In both cases we're looking for the presence of mod_so.c

3 . Download and unpack AWStats software ...

> cd /root
> mkdir archive
> cd archive
> wget http://unc.dl.sourceforge.net/sourceforge/awstats/awstats-5.9.tgz

FreeBSD was missing the wget command so I did the download like this:

> lynx -source http://unc.dl.sourceforge.net/sourceforge\
/awstats/awstats-6.1.tgz > awstats-6.1.tgz

Now unpack the distribution:

> tar -xvzf awstats-5.9.tgz
> cd awstats-5.9

or on FreeBSD: 

> tar -xvzf awstats-6.1.tgz
> cd awstats-6.1

4. Install AWStats software ...

> mv wwwroot /home/awstats
> cp tools/awstats_buildstaticpages.pl /home/awstats/cgi-bin

5. Install run script ...

> cd /root/archive
> wget http://www.reliablepenguin.com/clients/misc/awstats.run.pl

or on FreeBSD:

> lynx -source http://www.reliablepenguin.com/\
clients/misc/awstats.run.pl > awstats.run.pl

You might need to edit this script and adjust the SITE_BASE variable to match your install.

On FreeBSD the path to grep had to be changed to /usr/bin/grep at the start of the script.

Next do:

> chmod 755 awstats.run.pl
> cp awstats.run.pl /usr/local/sbin

6. Install config template ...

> cd /home/awstats/cgi-bin
> wget http://www.reliablepenguin.com/clients/misc/awstats.template.conf

or on FreeBSD:

> lynx -source http://www.reliablepenguin.com/\
clients/misc/awstats.template.conf > awstats.template.conf 

The template config file sets the following:

        LogFile="/home/sites/#SITE#/logs/web"

        LogType=W

        LogFormat=1

        SiteDomain="#SITE#"

        DNSLookup=0

        DirCgi="/awstats/cgi-bin"

        DirIcons="/awstats/icon"

For FreeBSD the template must be edited to set the following:

        LogFile="/www/logs/#SITE#-access.log"

7. Setup apache ....

Edit /etc/httpd/conf/httpd.conf and add the following lines
to the end of the file just before any virtual definitions:

   Alias /awstats/icon /home/awstats/icon
   Alias /awstats/js /home/awstats/js
   Alias /aswtats/css /home/awstats/css

On FreeBSD the httpd.conf file is located in /usr/www/apache/conf/

8. Setup logrotate ...

Edit /etc/logrotate.d/apache and add the indicated line.

        /var/log/httpd/access {
            prerotate
                /usr/local/sbin/split_logs web < /var/log/httpd/access
ADD -->         /usr/local/sbin/awstats.run.pl >> /var/log/awstats.log
            endscript
            missingok
            postrotate
                /usr/bin/killall -HUP httpd 2> /dev/null || true
            endscript
            daily
        }

The logrotate setup was not needed on the FreeBSD server. Instead a cronjob did the trick.

That does it!

Notes:
Basic awstats operations:

a. Initialize the database with logs ...

> /awstats.pl -config=your.domain -update

b. Run reports ...

> /home/awstats/cgi-bin/awstats_buildstaticpages.pl \
        -config=your.domain \
        -dir=/home/sites/your.domain/web/awstats/reports \
        -awstatsprog=/home/awstats/cgi-bin/awstats.pl

08/08/04

Permalink 03:49:30 pm, by admin Email , 119 words   English (US)
Categories: Install Notes, RedHat

Java Alternatives Settings

alternatives --verbose \
  --install /usr/bin/java  java \
    /usr/local/j2sdk1.4.2_04/bin/java 10 \
  --slave /usr/bin/rmiregistry rmiregistry \
    /usr/local/j2sdk1.4.2_04/bin/rmiregistry \
  --slave /usr/share/man/man1/rmiregistry.1 rmiregistry.1 \
    /usr/local/j2sdk1.4.2_04/man/man1/rmiregistry.1

alternatives --set java /usr/local/j2sdk1.4.2_04/bin/java

alternatives --verbose \
  --install /usr/bin/javac javac \
    /usr/local/j2sdk1.4.2_04/bin/javac 10 \
  --slave /usr/bin/jar jar \
    /usr/local/j2sdk1.4.2_04/bin/jar \
  --slave /usr/bin/rmic rmic \
    /usr/local/j2sdk1.4.2_04/bin/rmic \
  --slave /usr/share/man/man1/jar.1 jar.1 \
    /usr/local/j2sdk1.4.2_04/man/man1/jar.1 \
  --slave /usr/share/man/man1/rmic.1 rmic.1 \
    /usr/local/j2sdk1.4.2_04/man/man1/rmic.1

alternatives --set javac /usr/local/j2sdk1.4.2_04/bin/javac

07/31/04

Permalink 08:51:09 am, by admin Email , 27 words   English (US)
Categories: Linux, Install Notes

HylaFax

http://www.hylafax.org


wget --passive-ftp ftp://ftp.hylafax.org/source/hylafax-4.1.8.tar.gz
tar -xvzf hylafax-4.1.8.tar.gz
cd hylafax-4.1.8

./configure --nointeractive

make

make install

faxsetup
Permalink 08:50:18 am, by admin Email , 159 words   English (US)
Categories: Install Notes, RedHat

ImageMagick

Goal : Install ImageMagick with multi-page TIFF and JPEG support.

Target System : RedHat 8 and above

1. Create a archive directory.

> mkdir /root/archive

2. Install JPEG library from ftp://ftp.uu.net/graphics/jpeg/

> cd /root/archive
> wget --passive-ftp ftp://ftp.uu.net/graphics/jpeg/jpegsrc.v6b.tar.gz
> tar -xvzf jpegsrc.v6b.tar.gz
> cd jpeg-6b
> ./configure
> make
> make install

3. Install TIFF library from ftp://ftp.remotesensing.org/pub/libtiff/

> cd /root/archive
> wget --passive-ftp ftp://ftp.remotesensing.org/pub/libtiff/tiff-v3.6.1.tar.gz
> tar -xvzf tiff-v3.6.1.tar.gz
> wget --passive-ftp ftp://ftp.remotesensing.org/pub/libtiff/libtiff-lzw-compression-kit-1.5.tar.gz
> tar -xvzf libtiff-lzw-compression-kit-1.5.tar.gz
> cd libtiff-lzw-compression-kit-1.5
> cp tif_lzw.c ../tiff-v3.6.1/
> cd ../tiff-v3.6.1
> ./configure --noninteractive
> make
> make install

4. Install ImageMagick software from http://www.imagemagick.org

> cd /root/archive
> wget --passive-ftp ftp://ftp.imagemagick.org/pub/ImageMagick/ImageMagick-5.5.7-16.tar.gz
> tar -xvzf ImageMagick-5.5.7-16.tar.gz
> cd ImageMagick-5.5.7
> ./configure --enable-lzw --disable-installed --without-perl
> make
> make install

And that's it!


Permalink 08:48:54 am, by admin Email , 200 words   English (US)
Categories: Linux, Install Notes

LTSP

I. LTSP
-------

http://www.ltsp.org/

cd root
mkdir archive
cd archive

wget ftp://195.220.108.108/linux/fedora/core/development/i386/Fedora/RPMS/nasm-0.98.38-2.i386.rpm
rpm -i nasm-0.98.38-2.i386.rpm

cvs -d :pserver:anonymous@cvs.ltsp.org:/usr/local/cvsroot checkout -r LTSP-4_0_1 lbe

cd lbe
./build_all
mv opt/ltsp/ /opt/

II. TFTP-HPA
------------
cd /root/archive
wget http://www.kernel.org/pub/software/network/tftp/tftp-hpa-0.36.tar.gz
tar -xvzf tftp-hpa-0.36.tar.gz
cd tftp-hpa-0.36
./configure
make
make install


mkdir /opt/tftproot
cd /root/archive
wget http://www.reliablepenguin.com/clients/misc/tftpd.service
cp tftpd.service /etc/init.d/tftpd
chmod 755 /etc/init.d/tftpd

chkconfig --add tftpd
chkconfig --level 456 tftpd on

cd /root/archive/lbe/kernel
cp bzImage-2.4.22-ltsp-1 /opt/tftproot/

III. DHCPD
----------

http://www.isc.org/index.pl?/sw/dhcp/

cd /root/archive
wget ftp://ftp.isc.org/isc/dhcp/dhcp-3.0.1rc13.tar.gz

tar -xvzf dhcp-3.0.1rc13.tar.gz
cd dhcp-3.0.1rc13
./configure
make
make install

cd server
cp dhcpd.conf /etc

touch /var/state/dhcp/dhcpd.leases
wget http://www.reliablepenguin.com/clients/misc/dhcpd.service
cp dhcpd.service /etc/init.d/dhcpd
chmod 755 /etc/init.d/dhcpd
chkconfig --add dhcpd
chkconfig --level 456 dhcpd on

1 2 3 4 5 6 7 >>

July 2010
Sun Mon Tue Wed Thu Fri Sat
 << <   > >>
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

Reliable Penguin offers Linux Server Migrations, Systems Administration & Programming. Visit our main website at:

http://www.reliablepenguin.com

Search

Bookmark and Share

XML Feeds

blog software