qmailanalog-web installation

January 9, 2008 by gregorgede · Leave a Comment
Filed under: Qmail 

1. get the files needed:

$ wget http://www.jptrainings.de/qmailanalog-web/INSTALL
$ wget http://www.jptrainings.de/qmailanalog-web/FGA
$ wget http://www.jptrainings.de/qmailanalog-web/qmail-savelog
$ wget http://www.jptrainings.de/qmailanalog-web/qmail-splitlog
$ wget http://www.jptrainings.de/qmailanalog-web/qmailanalog-web

2. read and follow instructions in INSTALL and FGA file

3. get and compile tai64nfrac :

$ wget http://archives.eyrie.org/software/system/tai64nfrac-1.4.tar.gz
$ tar xzfv tai64nfrac-1.4.tar.gz
$ cd
tai64nfrac-1.4
$ su -
$ make install

4. get and install qmailanalog from http://cr.yp.to/qmailanalog.html. if runnig RHEL or fedora you might need :

$ vi err-patch

and paste this :

— error.h.orig 2003-03-05 15:42:51.000000000 -0500
+++ error.h 2003-03-05 15:43:00.000000000 -0500
@@ -1,7 +1,7 @@
#ifndef ERROR_H
#define ERROR_H

-extern int errno;
+#include

extern int error_intr;
extern int error_nomem;

and then:

$ tar zxvf qmailanalog-0.70.tar.gz
$ cd qmailanalog-0.70
$ patch < /path/to/err-patch
$ make && make setup check

5. follow instruction from INSTALL file. cron job in /etc/crontab for qmail-splitlog is like these :

#qmailanalog-web
15 4,7,10,13,16,19,22 * * * root /usr/local/bin/qmail-splitlog /var/log/qmailanalogweb
06 2 * * * root /bin/chmod -R 755 /var/log/qmailanalogweb

6. don’t forget to chmod 755 qmail-splitlog and qmail-savelog and qmailanalog-web

database server informix 7.2 change ip on mandrake 10

January 8, 2008 by gregorgede · Leave a Comment
Filed under: Informix 

i’ve never play with informix before. but today i have to help my friend to change the ip of the informix server to comply our new network regulation. the informix server is currently listening on ip 192.168.11.12, the same ip as the eth0.

we have to change the eth0 ip to 172.16.10.12 according to the new regulation. as the ussual way to do the change, i edit what’s needed in file /etc/sysconfig/network-scripts/ifcfg-eth0 and restart the network service. ip changes work fine.
to make the informix listen on the new ip, i also restart the informix services. but it doesn’t work as expected….:(

i try google for some times to find answers about changing ip for informix server but no good result comes up. so i try look for some documentation in informix home dir and finally find some clue in file /home/informix/release/en_us/0333/SE_7.2. it has something to do with sqlhosts file. so i try:

$ locate sqlhosts

result is /home/informix/etc/sqlhosts, then i look into the file with vi and the answer was there.
here’s the contain of the file :

#demo_on onipcshm on_hostname on_servername
#demo_se seipcpip se_hostname sqlexec
dbserver sesoctcp db.domain.co.id sqlexec

then i do :

$ dig db.domain.co.id

the answer is 192.168.11.12. so i add this line in /etc/hosts file to tell informix to use the new ip

172.16.10.12 db.domain.co.id

then i tell the server to reboot. informix is now listening on the new ip and works fine as it was with the old ip.

Reblog this post [with Zemanta]

ADDING Microsoft SQL Server SUPPORT FOR PHP on RHEL4

January 7, 2008 by gregorgede · Leave a Comment
Filed under: PHP 

one of our programmer needs to access microsoft sql server from our php server, so i have to reinstall php to add this support (php-mssql), here’s what i do :

1. download freetds from

ftp://ftp.ibiblio.org/pub/Linux/ALPHA/freetds/stable/freetds-stable.tgz

2. build and install freetds :

$ tar xzfv freetds-stable.tgz
$ ls
$ cd freetds-0.64
$ ./configure –prefix=/usr/local/freetds –enable-msdblib
$ make
$ su -
$ make install
$make clean

3. build and install php

$ tar xjfv php-5.2.4.tar.bz2
$ cd php-5.2.4
$ ./configure –with-apxs2=/usr/local/apache2/bin/apxs –enable-magic-quotes –with-openssl –with-zlib –with-bz2 –enable-ftp –with-gd –enable-mbstring –with-mysql=/usr/include/mysql –with-mysqli=/usr/bin/mysql_config –with-freetype-dir –with-t1lib –with-jpeg-dir –with-mssql=/usr/local/freetds
$ make
$ su -
$ make install
$ make clean

4. check httpd.conf to make sure php5 module not loaded twice. then restart apache.

enabling or disabling spamassassin or clamav

January 5, 2008 by gregorgede · Leave a Comment
Filed under: spamassassin 

using qmail, qmail-scanner, spamassassin, clamav. sometimes when clamav causing error and needs update, the entire mail delivery will fail. while updating clamav, we can tell qmail-scanner not to use it so the mail delivery will continue without clamav. to enable or disable clamav or spamassassin find these lines in /var/qmail/bin/qmail-scanner-queue.pl :

my @scanners_installed=(”clamdscan_scanner”,”spamassassin”,”perlscan_scanner”);
my @scanners_default=(”clamdscan_scanner”,”spamassassin”,”perlscan_scanner”);

to enable only spamassassin, turn it to be :

my @scanners_installed=(”spamassassin”);
my @scanners_default=(”spamassassin”);

to enable only clamav, turn it to be :

my @scanners_installed=(”clamdscan_scanner“);
my @scanners_default=(”
clamdscan_scanner“);


save and then do this :

$ setuidgid qscand /var/qmail/bin/qmail-scanner-queue.pl -g
$ setuidgid qscand /var/qmail/bin/qmail-scanner-queue.pl -z

setting up default quota for new vpopmail user

January 5, 2008 by gregorgede · Leave a Comment
Filed under: Uncategorized 

i use vpopmail 5.4.7. we can set default quota for every newly created user by setting up a certain value in /home/vpopmail/etc/vlimits.default. For example, i want every new user to have only 5Mb quota and maximum 500 messages in their inbox. here what to put in vlimits.default:

default_quota 5242880
default_maxmsgcount 500

now everytime we add a new user without -q option, the new user will have 5Mb quota. we can also set quota for an entire domain in vlimits.default, actually the file is self-explanatory…:)

Next Page »