September 10, 2010, 09:44:30 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Work on Kolab2/Gentoo-2.2 has stopped. The project has been deprecated (see board Kolab2/Gentoo).
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Send locally generated mails to a kolab user?  (Read 2749 times)
Strunzdesign
Newbie
*

Karma: 0
Posts: 9


View Profile Email
« on: June 23, 2008, 08:41:21 AM »

Hi,

normally, a "server" should have a some sort of "mail daemon", in order to report errors to the administrator or just to deliver mails. In my case, I've installed an asterisk (A PBX in software with answering machine and fax service). Within its "VoiceMail"-Plugin, I can specify a command to send mails to a registered user, in oder to notify him about new faxes or incoming voicemails.

The default entry here mentiones "sendmail":

/etc/asterisk/voicemail.conf
; You can override the default program to send e-mail if you wish, too
;
;mailcmd=/usr/sbin/sendmail -t

Do you have any hints what I should insert here in order to send voicemails to a user of the locally running kolab service? I have a "stock" kolab system, and here is just a "sendmail.postfix" file lying around...

Is this possible? And are there authentication issues? Would be cool to have my voicemails just within kolab directly.

Thank you very much!
Florian
Logged
Gunnar Wrobel
Administrator
Sr. Member
*****

Karma: 2
Posts: 331


275141552 gunnarwrobel@yahoo.de gunnarwrobel
View Profile WWW Email
« Reply #1 on: June 23, 2008, 08:57:01 AM »

That should definitely be possible. If it does not work for you now you should probably check if "mailwrapper" is correctly configured on your system. If you tell mailwrapper to use the postfix sendmail stuff this might be problematic as you probably need to ensure that the sending user (asterisk in you case) really exists. I tend to configure mailwrapper to use ssmtp which means that only the receiving user needs to exist. But I'm writing this without checking my actual config so it might not be 100% accurate. In any case mailwrapper will be your friend here. Wink

Cheers,

Gunnar
Logged
Strunzdesign
Newbie
*

Karma: 0
Posts: 9


View Profile Email
« Reply #2 on: June 23, 2008, 12:45:08 PM »

Hi Gunnar,

thank you for the hint about mailwrapper. It was already installed, but "sendmail" as a command was not available?! Check this:

Code:
powerstation ~ # equery check mailwrapper
[ Checking net-mail/mailwrapper-0.2.1 ]
!!! /usr/sbin/sendmail does not exist
!!! /etc/mail/mailer.conf has incorrect md5sum
 * 10 out of 12 files good
powerstation ~ # 

I have no idea why these both files are gone, I swear I've never touched them ;-) However, kolab does not provide a template for them, so I have no iclue... are there some kolab-related ebuilds that do some magic here? (modify files...)

I'm going to re-emerge mailwrapper first...

However, my "incorrect md5sum" mailer.conf:
Code:
powerstation ~ # cat /etc/mail/mailer.conf
# $Header: /var/cvsroot/gentoo-x86/mail-mta/postfix/files/mailer.conf,v 1.5 2005/07/05 01:04:50 ticho Exp $
# $OpenBSD: mailer.conf,v 1.3 2000/04/06 18:24:19 millert Exp $

# Execute the "real" sendmail program from postfix,
# named /usr/sbin/sendmail.postfix
#
sendmail        /usr/sbin/sendmail.postfix
send-mail       /usr/sbin/sendmail.postfix
mailq           /usr/sbin/sendmail.postfix
newaliases      /usr/sbin/sendmail.postfix
rmail           /usr/bin/rmail.postfix
powerstation ~ #   
... anything obvious here that is related to some ebuild-magic? ;-)

Thanks,
Florian
Logged
Strunzdesign
Newbie
*

Karma: 0
Posts: 9


View Profile Email
« Reply #3 on: June 23, 2008, 01:03:58 PM »

Hi again,

okay, some postfix issues now. Asterisk sends the email, but postfix throws an error:

Code:
powerstation postfix # cat /var/log/mail/current
[...]
Jun 23 13:51:08 [postfix/cleanup] fatal: open database /etc/postfix/canonical.db: No such file or directory
Jun 23 13:51:09 [postfix/master] warning: process /usr/lib/postfix/cleanup pid 11053 exit status 1
Jun 23 13:51:09 [postfix/master] warning: /usr/lib/postfix/cleanup: bad command startup -- throttling
Jun 23 13:52:09 [postfix/cleanup] fatal: open database /etc/postfix/canonical.db: No such file or directory
Jun 23 13:52:10 [postfix/master] warning: process /usr/lib/postfix/cleanup pid 12014 exit status 1
Jun 23 13:52:10 [postfix/master] warning: /usr/lib/postfix/cleanup: bad command startup -- throttling
Jun 23 13:53:10 [postfix/cleanup] fatal: open database /etc/postfix/canonical.db: No such file or directory
Jun 23 13:53:11 [postfix/master] warning: process /usr/lib/postfix/cleanup pid 13035 exit status 1
Jun 23 13:53:11 [postfix/master] warning: /usr/lib/postfix/cleanup: bad command startup -- throttling
Jun 23 13:54:11 [postfix/cleanup] fatal: open database /etc/postfix/canonical.db: No such file or directory
Jun 23 13:54:12 [postfix/master] warning: process /usr/lib/postfix/cleanup pid 14001 exit status 1
Jun 23 13:54:12 [postfix/master] warning: /usr/lib/postfix/cleanup: bad command startup -- throttling
Jun 23 13:55:12 [postfix/cleanup] fatal: open database /etc/postfix/canonical.db: No such file or directory
Jun 23 13:55:13 [postfix/master] warning: process /usr/lib/postfix/cleanup pid 14960 exit status 1
Jun 23 13:55:13 [postfix/master] warning: /usr/lib/postfix/cleanup: bad command startup -- throttling
powerstation postfix #

... there is no /etc/postfix/canonical.db, but a /etc/postfix/canonical. However, it only consists of commented lines without any information.

I tried to copy it to canonical.db, but then I got another error message:

Quote
[...]
Jun 23 14:01:18 [postfix/cleanup] fatal: open database /etc/postfix/canonical.db: Invalid argument
[...]

Any ideas? :-)

Regards,
Florian
Logged
Gunnar Wrobel
Administrator
Sr. Member
*****

Karma: 2
Posts: 331


275141552 gunnarwrobel@yahoo.de gunnarwrobel
View Profile WWW Email
« Reply #4 on: June 23, 2008, 01:09:43 PM »

You can regenrate these with snippets like this

Code:
postmap /etc/postfix/canonical

But kolabconf should already do this (or at least part of this). So if your postfix is not working at the moment there might be more trouble ahead. Check your syslog for errors from kolabconf.

Cheers,

Gunnar
Logged
Strunzdesign
Newbie
*

Karma: 0
Posts: 9


View Profile Email
« Reply #5 on: June 23, 2008, 01:33:34 PM »

Hi Gunnar,

thanks, its working now :-)

I had to manually convert some files:

1.) canonical.db and relocated.db missing:
postmap /etc/postfix/canonical
postmap /etc/postfix/relocated

2.) /etc/mail/aliases.db missing:
powerstation mail # newaliases

Then it worked. Beforehand, I started kolabconf, but no errors in syslog. Unfortunately, no conversion of these three .db files as well...

Okay :-) I'm happy now ;-) But perhaps... couldn't these conversions be performed by kolabconf automatically?

Regards,
Florian
Logged
Gunnar Wrobel
Administrator
Sr. Member
*****

Karma: 2
Posts: 331


275141552 gunnarwrobel@yahoo.de gunnarwrobel
View Profile WWW Email
« Reply #6 on: June 23, 2008, 01:35:26 PM »

This is indeed a part that is already available in Kolab2/Gentoo-2.2 Smiley A lot of other stuff is still missing but that parts works...

Cheers,

Gunnar
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!