Current time: 11-24-2024, 09:45 AM Hello There, Guest! (LoginRegister)


Post Reply 
Email von Subdomains mit Dovecot
Author Message
blub Offline
Junior Member
*

Posts: 21
Joined: Jan 2008
Reputation: 0
Post: #1
Exclamation Email von Subdomains mit Dovecot
Hi Forum,

Ich möchte euch an einem kleinen Fix teilhaben lassen. Die SQL Anweisungen in der Wiki um Dovecot zu installieren sind meiner Meinung nicht ganz richtig, um Mails von Subdomains zu empfangen oder um sich also Subdomain Mailuser einzuloggen. Ich habe den SQL Code etwas erweitert.

Ändeurngen in dovecot-sql-domain.conf password_query
Code:
SELECT md5( mail_pass ) AS
PASSWORD FROM mail_users
INNER JOIN domain ON mail_users.domain_id = domain.domain_id
left JOIN domain_aliasses da ON sub_id = da.alias_id
WHERE mail_acc = '%n'
AND (
(
domain.domain_name = '%d'
AND sub_id =0
and mail_type = 'normal_mail'
)
OR (
da.alias_name = '%d'
and mail_type = 'alias_mail'
)
)
[/code]
Ändeurngen in dovecot-sql-domain.conf user_query
Code:
SELECT concat( '/var/mail/virtual/', ifnull( da.alias_name, domain.domain_name ) , '/', mail_acc ) AS home, '1001' AS uid, '8' AS gid
FROM mail_users
INNER JOIN domain ON mail_users.domain_id = domain.domain_id
LEFT JOIN domain_aliasses da ON sub_id = da.alias_id
WHERE mail_acc = '%n'
AND (
(
domain.domain_name = '%d'
AND sub_id =0
AND mail_type = 'normal_mail'
)
OR (
da.alias_name = '%d'
AND mail_type = 'alias_mail'
)
)

Bitte testet den Code, bei mir läuft er.

Ich hoffe ich konnte hiermit jemandem helfen.

Gruß,
Blub Tongue
(This post was last modified: 01-27-2008 06:47 AM by blub.)
01-27-2008 06:46 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Messages In This Thread
Email von Subdomains mit Dovecot - blub - 01-27-2008 06:46 AM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)