OpenEMM Support Forum Index OpenEMM Support
Use this forum to get and provide free help regarding OpenEMM
 
 TOP   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

openemm on debian lenny

 
Post new topic   Reply to topic    OpenEMM Support Forum Index -> Bounce Management
View previous topic :: View next topic  
Author Message
bashnia



Joined: 10 Nov 2009
Posts: 1

PostPosted: Tue Nov 10, 2009 9:38 am    Post subject: openemm on debian lenny Reply with quote

Hello, All!
Sorry for my English.
This is how was installed and configured my server, if long - sorry again:
---
1. download of prebuilded vmware image of Debian "Lenny" netinst

http://download.thoughtpolice.co.uk/debian-500-i386-netinst.zip.torrent

2. configuration of hostname and ip on newly started virtual machine

a) ip - configured via dhcp
b) echo "spnx02" > /etc/hostname
c) vi /etc/hosts

127.0.0.1 localhost
127.0.1.1 spnx02.domain.com spnx02

d) disable ipv6

vi /etc/modprobe.d/00local

alias net-pf-10 off
alias ipv6 off

e) reboot or write new hostname via sysctl

3. packages:

I prefer classic syslogd:

# apt-get remove rsyslog
# apt-get install sysklogd

installation of necessary packeges:

# apt-get install mysql-server python-mysqldb sendmail chkconfig
# chkconfig sendmail off

turn off sendmail at start - openemm will start it

4. download jre and openemm

jdk-6u17-linux-i586.bin
OpenEMM-6.RC2-bin.tar.gz

5. jdk Installation

# cp jdk-6u17-linux-i586.bin /tmp
# cd /tmp
# chmod u+x jdk-6u17-linux-i586.bin
# ./jdk-6u17-linux-i586.bin
# mkdir -p /opt/openemm.org/software
# mv jdk1.6.0_17 /opt/openemm.org/software
# ln -s jdk1.6.0_17 java
# /opt/openemm.org/software/java/bin/java -version
java version "1.6.0_17"
Java(TM) SE Runtime Environment (build 1.6.0_17-b04)
Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)

6. openemm installation

# groupadd openemm
# useradd -m -g openemm -d /home/openemm -c "OpenEMM 6.x.y" openemm

# cp OpenEMM-6.RC2-bin.tar.gz /home/openemm/
# cd /home/openemm
# tar xzvpf /home/openemm/OpenEMM-6.RC2-bin.tar.gz
# mkdir -p /usr/share/doc/OpenEMM-6.RC2
# mv USR_SHARE/* /usr/share/doc/OpenEMM-6.RC2

7. syslog

Check /etc/syslog.conf and change the path for the mail log from /var/log/mail.log to /var/log/maillog

vi /etc/cron.weekly/sysklogd
-------------
savelog -g adm -m 640 -u root -c 4 $LOG >/dev/null
change to
savelog -g adm -m 644 -u root -c 4 $LOG >/dev/null
-------------

Change permission for maillog

# /etc/init.d/sysklogd restart
Restarting system log daemon....
# chmod 644 /var/log/maillog

8. mysql

create CMS database:
# mysqladmin -u root -p create openemm_cms
# cd /usr/share/doc/OpenEMM-6.RC2/
# mysql -u root -p openemm_cms < openemm_cms.sql

Create openemm database:
# mysqladmin -u root -p create openemm
redirection and bounce urls
# vi openemm-6.RC2.sql
replace "http://localhost:8080" with "http://spnx02.domain.com:8080"
replace the empty mailloop string '' directly after the redirection url with news.domain.com
# mysql -u root -p openemm < openemm-6.RC2.sql

9. well, let's start openemm
# su - openemm
$ Openemm.sh start
$ netstat -ln
openemm@spnx02:~$ OpenEMM.sh start
Start /home/openemm/bin/scripts/bav-update.py .. done.
Start /home/openemm/bin/scripts/bav-trigger.py .. done.
Start /home/openemm/bin/scripts/bavd.py .. done.
Start /home/openemm/bin/bav -L INFO .. done.
Start /home/openemm/bin/scripts/update.py bounce account .. done.
xmlback: error while loading shared libraries: libxml2.so.2: cannot open shared object file: No such file or directory
Start /home/openemm/bin/scripts/pickdist.py .. done.
Stopping obsolete sendmail processes: done.
Starting sendmails: listener client queue mqueue-client admin queue mail queue done.
Start /home/openemm/bin/scripts/slrtscn.py .. done.
Resin httpd start at Tue Nov 10 01:55:25 EST 2009
openemm@spnx02:~$ netstat -ln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 127.0.0.1:8900 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:5166 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:8080 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN
udp 0 0 0.0.0.0:68 0.0.0.0:*
Active UNIX domain sockets (only servers)
Proto RefCnt Flags Type State I-Node Path
unix 2 [ ACC ] STREAM LISTENING 4664 /var/run/acpid.socket
unix 2 [ ACC ] STREAM LISTENING 14189 /var/run/sendmail/mta/smcontrol
unix 2 [ ACC ] STREAM LISTENING 4804 /var/run/mysqld/mysqld.sock
unix 2 [ ACC ] STREAM LISTENING 13881 /home/openemm/var/run/bav.sock
openemm@spnx02:~$ OpenEMM.sh stop
Ctrl+D
# apt-get install libxml2

Let's try again

openemm@spnx02:~$ OpenEMM.sh start
Start /home/openemm/bin/scripts/bav-update.py .. done.
Start /home/openemm/bin/scripts/bav-trigger.py .. done.
Start /home/openemm/bin/scripts/bavd.py .. done.
Start /home/openemm/bin/bav -L INFO .. done.
Start /home/openemm/bin/scripts/update.py bounce account .. done.
Start /home/openemm/bin/scripts/pickdist.py .. done.
Stopping obsolete sendmail processes: -15:2874 -15:2879 -15:2884 -15:2889 done.
Starting sendmails: listener client queue mqueue-client admin queue mail queue done.
Start /home/openemm/bin/scripts/slrtscn.py .. done.
httpd has already started
openemm@spnx02:~$ netstat -ln
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 127.0.0.1:8900 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:5166 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:8080 0.0.0.0:* LISTEN
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN
udp 0 0 0.0.0.0:68 0.0.0.0:*
Active UNIX domain sockets (only servers)
Proto RefCnt Flags Type State I-Node Path
unix 2 [ ACC ] STREAM LISTENING 4664 /var/run/acpid.socket
unix 2 [ ACC ] STREAM LISTENING 14952 /var/run/sendmail/mta/smcontrol
unix 2 [ ACC ] STREAM LISTENING 4804 /var/run/mysqld/mysqld.sock
unix 2 [ ACC ] STREAM LISTENING 13881 /home/openemm/var/run/bav.sock
openemm@spnx02:~$

looks good!

10. after login to web-interface everything works fine, cyryllic symbols too.
Note: http://www.openemm.org/wiki/Charsets:UTF-8

12. sendmail configuration:

# netstat -ln
...
tcp 0 0 127.0.0.1:25
...
Sendmail listen only on 127.0.0.1:25
Let's imroove it

# cd /etc/mail

in sendmail.mc

change
DAEMON_OPTIONS(`Family=inet, Name=MTA-v4, Port=smtp, Addr=127.0.0.1')dnl
to
DAEMON_OPTIONS(`Family=inet, Name=MTA-v4, Port=smtp')dnl

---
Add the following line at the end of the file:

INPUT_MAIL_FILTER(`bav', `S=unix:/home/openemm/var/run/bav.sock, F=T')dnl

This will enable the dynamic mail loop required by the bounce management to process delayed bounces.

If file /etc/mail/relay-domains does not exist, create the file - for example by

touch relay-domains

and add a line at the end of the file which specifies your DNS entry for the sender hostname (FQDN). In our example it is

simply:

news.domain.com

Open file /etc/mail/mailertable and add a line at the end which activates the bounce management for that FQDN:

news.domain.com procmail:/home/openemm/conf/bav/bav.rc

----

# make
# su - openemm
$ OpenEMM.sh stop && OpenEMM.sh start
$ netstat -ln
tcp 0 0 0.0.0.0:25

11. My virtual server is behind main email appliance (smarthost).
So, let's change senmail.mc to use it.
Insert the following line before INPUT_MAIL.FILTER
define(`SMART_HOST',`spmail01.domain.com')dnl

spmail01 was configured to accept mail for news.domain.com and redirect it to spnx01.domain.com.
Also our public DNS was configured with MX record to accept mail for news.domain.com and A record to resolve our public as news.domain.com too.
this is my sendmail.mc on spnx02:

divert(-1)dnl
#-----------------------------------------------------------------------------
# $Sendmail: debproto.mc,v 8.14.3 2008-07-15 22:30:00 cowboy Exp $
#
# Copyright (c) 1998-2008 Richard Nelson. All Rights Reserved.
#
# cf/debian/sendmail.mc. Generated from sendmail.mc.in by configure.
#
# sendmail.mc prototype config file for building Sendmail 8.14.3
#
# Note: the .in file supports 8.7.6 - 9.0.0, but the generated
# file is customized to the version noted above.
#
# This file is used to configure Sendmail for use with Debian systems.
#
# If you modify this file, you will have to regenerate /etc/mail/sendmail.cf
# by running this file through the m4 preprocessor via one of the following:
# * make (or make -C /etc/mail)
# * sendmailconfig
# * m4 /etc/mail/sendmail.mc > /etc/mail/sendmail.cf
# The first two options are preferred as they will also update other files
# that depend upon the contents of this file.
#
# The best documentation for this .mc file is:
# /usr/share/doc/sendmail-doc/cf.README.gz
#
#-----------------------------------------------------------------------------
divert(0)dnl
#
# Copyright (c) 1998-2005 Richard Nelson. All Rights Reserved.
#
# This file is used to configure Sendmail for use with Debian systems.
#
define(`_USE_ETC_MAIL_')dnl
include(`/usr/share/sendmail/cf/m4/cf.m4')dnl
VERSIONID(`$Id: sendmail.mc, v 8.14.3-5 2008-07-15 22:30:00 cowboy Exp $')
OSTYPE(`debian')dnl
DOMAIN(`debian-mta')dnl
dnl # Items controlled by /etc/mail/sendmail.conf - DO NOT TOUCH HERE
undefine(`confHOST_STATUS_DIRECTORY')dnl #DAEMON_HOSTSTATS=
dnl # Items controlled by /etc/mail/sendmail.conf - DO NOT TOUCH HERE
dnl #
dnl # General defines
dnl #
dnl # SAFE_FILE_ENV: [undefined] If set, sendmail will do a chroot()
dnl # into this directory before writing files.
dnl # If *all* your user accounts are under /home then use that
dnl # instead - it will prevent any writes outside of /home !
dnl # define(`confSAFE_FILE_ENV', `')dnl
dnl #
dnl # Daemon options - restrict to servicing LOCALHOST ONLY !!!
dnl # Remove `, Addr=' clauses to receive from any interface
dnl # If you want to support IPv6, switch the commented/uncommentd lines
dnl #
FEATURE(`no_default_msa')dnl
dnl DAEMON_OPTIONS(`Family=inet6, Name=MTA-v6, Port=smtp, Addr=::1')dnl
DAEMON_OPTIONS(`Family=inet, Name=MTA-v4, Port=smtp')dnl
dnl DAEMON_OPTIONS(`Family=inet6, Name=MSP-v6, Port=submission, M=Ea, Addr=::1')dnl
DAEMON_OPTIONS(`Family=inet, Name=MSP-v4, Port=submission, M=Ea, Addr=127.0.0.1')dnl
dnl #
dnl # Be somewhat anal in what we allow
define(`confPRIVACY_FLAGS',dnl
`needmailhelo,needexpnhelo,needvrfyhelo,restrictqrun,restrictexpand,nobodyreturn,authwarnings')dnl
dnl #
dnl # Define connection throttling and window length
define(`confCONNECTION_RATE_THROTTLE', `15')dnl
define(`confCONNECTION_RATE_WINDOW_SIZE',`10m')dnl
dnl #
dnl # Features
dnl #
dnl # use /etc/mail/local-host-names
FEATURE(`use_cw_file')dnl
dnl #
dnl # The access db is the basis for most of sendmail's checking
FEATURE(`access_db', , `skip')dnl
dnl #
dnl # The greet_pause feature stops some automail bots - but check the
dnl # provided access db for details on excluding localhosts...
FEATURE(`greet_pause', `1000')dnl 1 seconds
dnl #
dnl # Delay_checks allows sender<->recipient checking
FEATURE(`delay_checks', `friend', `n')dnl
dnl #
dnl # If we get too many bad recipients, slow things down...
define(`confBAD_RCPT_THROTTLE',`3')dnl
dnl #
dnl # Stop connections that overflow our concurrent and time connection rates
FEATURE(`conncontrol', `nodelay', `terminate')dnl
FEATURE(`ratecontrol', `nodelay', `terminate')dnl
dnl #
dnl # If you're on a dialup link, you should enable this - so sendmail
dnl # will not bring up the link (it will queue mail for later)
dnl define(`confCON_EXPENSIVE',`True')dnl
dnl #
dnl # Dialup/LAN connection overrides
dnl #
include(`/etc/mail/m4/dialup.m4')dnl
include(`/etc/mail/m4/provider.m4')dnl
dnl #
dnl # Default Mailer setup
MAILER_DEFINITIONS
MAILER(`local')dnl
MAILER(`smtp')dnl
INPUT_MAIL_FILTER(`bav', `S=unix:/home/openemm/var/run/bav.sock, F=T')dnl

12. tryout emailing

steps:
1) create new campaign = test campaign
2) create new mailinglist = test maillist
3) create 4 recipients as normal users for test maillist, 1 inside my domin.com, 2 in other (public) domains, 1 with fake adress to catch bonces
4) create new template (test template) with sender and reply to email info@news.domain.com
5) create new bounce filter = test bounce filter, auto generated e-mail: ext_1@news.domain.com
6) create new mailing with test template, send

results:
all emails are out and recieved, I can see number of opened mails in statistics tab, well, not bad.


Last edited by bashnia on Sun Apr 25, 2010 8:29 pm; edited 2 times in total
Back to top
View user's profile Send private message
Adain



Joined: 26 Jan 2010
Posts: 1

PostPosted: Tue Jan 26, 2010 10:52 am    Post subject: Reply with quote

I will read time to time that....
_________________
Love you
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OpenEMM Support Forum Index -> Bounce Management All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


SourceForge.net Logo Powered by phpBB © 2001, 2005 phpBB Group