Page 1 of 3

Disable Sendmail doesn't work

Posted: Tue Jun 24, 2008 1:37 pm
by philip
Hi,

I'm using OpenEMM 5.5.0 and trying to disable sendmail. I get following error:

Code: Select all

CAUGHT EXCEPTION:
Traceback (most recent call last):
  File "/home/openemm/bin/scripts/smenable.py", line 105, in ?
    main (sys.argv[0], sys.argv[1:])
  File "/home/openemm/bin/scripts/smenable.py", line 87, in main
    ctrl = SMCtrl ()
  File "/home/openemm/bin/scripts/smenable.py", line 35, in __init__
    self.db = agn.DBase ()
AttributeError: 'module' object has no attribute 'DBase'
Similar error occurres when starting openEMM.

python-mysql module missing?

Posted: Wed Jun 25, 2008 10:37 am
by maschoff
It seems that the python-mysql bridge is missing. please check with

#python -c 'import MySQLdb'

If no output is returned the module is present, but if you get something like

Traceback (most recent call last):
File "<string>", line 1, in ?
ImportError: No module named MySQLdb

you did not install the module

Posted: Wed Jun 25, 2008 11:40 am
by philip
Thanks, that solved the problem in the first time..

but now I get the following message:

"Failed to setup database interface"

Everything else works fine, except of sending mails as sendmail is still enabled.

I'm using Debian 3.1 with exim MTA..

Posted: Wed Jun 25, 2008 2:04 pm
by maschoff
Is MySQL up and running and did you dump openemm.sql into database "openemm"?

Posted: Wed Jun 25, 2008 2:09 pm
by philip
Yes, mySQL is running and openemm.sql is imported.

I'm using MySQL version 5.0.51

openEMM is starting like this:

Code: Select all

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.
Failed to setup database interface
Unable to determinate status for sendmail usages, assuming sendmail is enabled
Stopping obsolete sendmail processes:   done.
Starting sendmails:   listener  admin queue exim abandoned: unknown, malformed, or incomplete option -NNEVER
 mail queue exim abandoned: unknown, malformed, or incomplete option -NNEVER
 done.
Start /home/openemm/bin/scripts/slrtscn.py .. done.
Resin httpd start at Wed Jun 25 13:04:04 UTC 2008
Now I can login and work with openEMM but no mails are sent.

Thanks for Your support!

I have the same problem

Posted: Mon Jun 30, 2008 3:56 pm
by bknaus
I have the same problem. OpenEMM 5.5.0 (Gentoo).

Code: Select all

$ ./bin/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.
Failed to setup database interface
Unable to determinate status for sendmail usages, assuming sendmail is enabled
Stopping obsolete sendmail processes:   done.
Starting sendmails:   listener  admin queue  mail queue  done.
Start /home/openemm/bin/scripts/slrtscn.py .. done.
openemm@java-tools-mwonline ~ $ Resin httpd start at Mon Jun 30 16:47:00 CEST 2008
Backend works fine, admin and test mails will be send, but sending mails to newsletter recipient doesn't work.

missing package?

Posted: Tue Jul 01, 2008 8:45 am
by maschoff
The Python interface to MySQL seems to be missing. Are you sure that you installed the python-mysql package (SuSe name: python-mysql, Red Hat name: MySQL-python)?

Posted: Mon Jul 21, 2008 12:12 pm
by kwadrat
@philip, @bknaus:
I've got the same, have you solved this problem?

Posted: Mon Jul 21, 2008 12:20 pm
by philip
No, sorry. I switched to Windows machines so I didn't investigate further on.

Have you tried different versions of Java?

Good luck an please report any success.

me too, no solution yet?

Posted: Thu Aug 07, 2008 6:28 pm
by Toot
I'm trying to migrate from a sendmail v5.4.0 linux to v5.5.0 linux with sendmail disabled (it's a mail server using postfix).

I'm installing without sendmail which originally pooped out at the openemm rpm install saying sendmail-cf dependency couldn't be found. I --nodeps installed that, copied & upgraded the database successfully (apart from my new db has a password, old one didn't). Installed v5.5.0 apparently successfully, starting gives several errors:

Code: Select all

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.
Failed to setup database interface
Unable to determinate status for sendmail usages, assuming sendmail is enabled
Stopping obsolete sendmail processes:   done.
Starting sendmails:   listener  admin queue  mail queue  done.
postfix/postfix-script: fatal: the Postfix mail system is already running
Start /home/openemm/bin/scripts/slrtscn.py .. done.
$ Resin httpd start at Thu Aug  7 18:15:14 BST 2008
and running ~/bin/sendmail-disable.sh says:

Code: Select all

Failed to setup database interface
and in case it's relevant, as I didn't re-install mysql...

Code: Select all

mysql  Ver 14.7 Distrib 4.1.20, for redhat-linux-gnu (i686) using readline 4.3
what's wrong?!?!

Posted: Fri Aug 08, 2008 10:41 am
by ud
Looks like your mysql is not running (as you upgrade from a previous version, I assume that the database itself is available.)

-- ud

Posted: Fri Aug 08, 2008 5:22 pm
by Toot
ud wrote:Looks like your mysql is not running (as you upgrade from a previous version, I assume that the database itself is available.)

-- ud
Thanks for the reply. As far as I can tell, mysql is running fine:

Code: Select all

mysql> select count(*) from customer_1_tbl;
+----------+
| count(*) |
+----------+
|      664 |
+----------+
1 row in set (0.01 sec)
Maybe it's because this instance has a password? On the old system, I'd type mysql openemm and I'm in, on the new system I need to type mysql -p openemm and enter the password. Where is that set?

Thanks again for your help.

Resolved: Need to update user name and pwd in scripts/agn.py

Posted: Wed May 06, 2009 12:59 pm
by sapeksh
I was facing the same issue after migrating OpenEMM to a new server. This time while creating the DB user 'agnitas' I chose a password other than openemm (default).

File: /home/openemm/bin/scripts/agn.py has variables where you can update the value of the DB Host, User and Password. Changed this and triedsendmail-enable.sh and it worked.

If this still does not work, make sure that there is DB connectivity using the default values Host: localhost, User : agnitas and pwd : openemm.

Though it is too late since the last response on this post to help him, however posting it for new users like me.

Posted: Wed May 06, 2009 4:25 pm
by maschoff
For clarity we will move the parameters out of agn.py to emm.properties in the next release.

Posted: Thu Nov 26, 2009 4:22 pm
by horhe2
I've similar problem after autoupgrading from 5.5.1 .
./smenable displays message:
"Failed to setup database interface"
In files cms/properties and emm.properties connection to DB are set.
I have no idea how to debug the problem.