Current time: 04-27-2024, 12:38 PM Hello There, Guest! (LoginRegister)


Thread Closed 
[HowTo] Replace courier with dovecot
Author Message
hjansen Offline


Posts: 3
Joined: May 2007
Reputation: 0
Post: #49
RE: [HowTo] Replace courier with dovecot
Nice tutorial but i got crazy this night because whatever i did i could not create an e-mail adresse with an alias_domain. So the creation itself worked but i could not login because of a "Wrong password"

After debugging for a while i figured out that there is no sql query for alias domains so i could try to change my password and try to login forover.

Before somebody else get crazy, too here are my changes:

/etc/dovecot/dovecot-sql-aliasdomain.conf
Code:
driver = mysql
connect = host=localhost dbname=ispcp user=ispcp_dovecot password=mypass
password_query = SELECT md5(mail_pass) as password FROM (mail_users INNER JOIN domain_aliasses ON mail_users.sub_id = domain_aliasses.alias_id) INNER JOIN domain ON mail_users.domain_id = domain.domain_id WHERE mail_acc='%n' and domain_aliasses.alias_name ='%d';
user_query = SELECT concat('/var/mail/virtual/', domain_aliasses.alias_name, '/',mail_acc) as home, '1001' as uid, '8' as gid FROM (mail_users INNER JOIN domain_aliasses ON mail_users.sub_id = domain_aliasses.alias_id) INNER JOIN domain ON mail_users.domain_id = domain.domain_id WHERE mail_acc='%n' and domain_aliasses.alias_name ='%d';

/etc/dovecot/dovecot.conf
Code:
base_dir = /var/run/dovecot/
protocols = imap pop3
disable_plaintext_auth = no
listen=*
syslog_facility = mail
login_greeting = Dovecot ready.
mail_location = maildir:/var/mail/virtual/%d/%n
mail_extra_groups = mail
protocol imap {
}
namespace private {
  prefix = INBOX.
  inbox = yes
}
protocol pop3 {
  pop3_uidl_format = %u-%v
}
protocol lda {
  postmaster_address = postmaster@hostingchannel.de
  auth_socket_path = /var/run/dovecot/auth-master
}
auth default {
  mechanisms = plain login digest-md5
  passdb sql {
   args = /etc/dovecot/dovecot-sql-domain.conf
  }
  userdb sql {
   args = /etc/dovecot/dovecot-sql-domain.conf
  }
  passdb sql {
   args = /etc/dovecot/dovecot-sql-aliasdomain.conf
  }
  userdb sql {
   args = /etc/dovecot/dovecot-sql-aliasdomain.conf
  }
  passdb sql {
   args = /etc/dovecot/dovecot-sql-subdomain.conf
  }
  userdb sql {
   args = /etc/dovecot/dovecot-sql-subdomain.conf
  }
  socket listen {
   client {
    path = /var/spool/postfix/private/auth
    mode = 0660
    user = postfix
    group = postfix
   }
   master {
    path = /var/run/dovecot/auth-master
    mode = 0660
    user = vmail
    group = mail
   }
  }
  user = vmail
}
plugin {
}

If my lines are ok please somebody add them to the wiki

[/code]
02-11-2008 09:15 AM
Find all posts by this user
Thread Closed 


Messages In This Thread
RE: [HowTo] Replace courier with dovecot - hjansen - 02-11-2008 09:15 AM

Forum Jump:


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