diff --git a/5-integrations/sogo-centos-6-iredmail-mysql.md b/5-integrations/sogo-centos-6-mysql.md similarity index 68% rename from 5-integrations/sogo-centos-6-iredmail-mysql.md rename to 5-integrations/sogo-centos-6-mysql.md index 5c9a68bf..bf7c900f 100644 --- a/5-integrations/sogo-centos-6-iredmail-mysql.md +++ b/5-integrations/sogo-centos-6-mysql.md @@ -2,7 +2,7 @@ ## Requirements -* A working iRedMail server on CentOS 6. +* A working iRedMail server (MySQL backend) on CentOS 6. ## Install SOGo @@ -27,7 +27,7 @@ gpgcheck=0 * Install SOGo and dependences: ``` -# yum install sogo sope49-gdl1-mysql +# yum install sogo sope49-gdl1-mysql sogo-activesync libwbxml ``` ## Create SQL database to store SOGo data @@ -55,42 +55,49 @@ Default SOGo config file is `/etc/sogo/sogo.conf`: OCSSessionsFolderURL = "mysql://sogo:password@localhost:3306/sogo/sogo_sessions_folder"; SOGoIMAPServer = "127.0.0.1"; + SOGoDraftsFolderName Drafts + SOGoSentFolderName Sent + SOGoTrashFolderName Trash SOGoMailingMechanism = smtp; SOGoSMTPServer = 127.0.0.1; - // Enable managesieve service SOGoSieveServer = sieve://127.0.0.1:4190; SOGoSieveScriptsEnabled = YES; SOGoForceExternalLoginWithEmail = YES; SOGoAppointmentSendEMailNotifications = YES; + SOGoFoldersSendEMailNotifications YES + SOGoACLsSendEMailNotifications YES - SOGoUserSources = + SOGoUserSources = ( - { - type = sql; - id = directory; - viewURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_view"; - canAuthenticate = YES; - isAddressBook = YES; - userPasswordAlgorithm = md5; - prependPasswordScheme = YES; - //LoginFieldNames = username; - //MailFieldNames = username; - //IMAPLoginFieldName = username; - //DomainFieldName = domain; - } + { + type = sql; + id = directory; + viewURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_view"; + canAuthenticate = YES; + isAddressBook = YES; + userPasswordAlgorithm = md5; + prependPasswordScheme = YES; + } ); ``` +## Start SOGo and dependent services + +``` +service sogod start +service httpd restart +service memcached start +``` ## How to configure client applications -### Configure Apple iCal.app for calendar +### Apple Devices -http://[host]/SOGo/dav/[user]/ +URL for calendar service: `http://[host]/SOGo/dav/[user]/` ## TODO @@ -99,19 +106,13 @@ http://[host]/SOGo/dav/[user]/ * Addition settings: ``` -defaults write sogod OCSEMailAlarmsFolderURL mysql://vmail:PASSWORD@localhost:3306/vmail/sogo_alarms_folder +defaults write sogod OCSEMailAlarmsFolderURL mysql://sogo:password@localhost:3306/sogo/sogo_alarms_folder defaults write sogod SOGoTimeZone "Europe/Berlin" -defaults write sogod SOGoAppointmentSendEMailNotifications YES -defaults write sogod SOGoFoldersSendEMailNotifications YES -defaults write sogod SOGoACLsSendEMailNotifications YES defaults write sogod SOGoMailingMechanism smtp defaults write sogod SOGoSMTPServer 127.0.0.1 defaults write sogod SOGoMemcachedHost 127.0.0.1 -defaults write sogod SOGoDraftsFolderName Drafts -defaults write sogod SOGoSentFolderName Sent -defaults write sogod SOGoTrashFolderName Trash defaults write sogod SOGoIMAPServer localhost defaults write sogod SOGoPasswordChangeEnabled YES defaults write sogod SOGoSieveScriptsEnabled YES diff --git a/9-troubleshooting/turn.on.debug.mode.in.amavisd.md b/9-troubleshooting/turn.on.debug.mode.in.amavisd.md new file mode 100644 index 00000000..4ca4dfc8 --- /dev/null +++ b/9-troubleshooting/turn.on.debug.mode.in.amavisd.md @@ -0,0 +1,13 @@ +# How to turn on debug mode in Amavisd + +In Amavisd config file `/etc/amavisd/amavisd.conf`, change `$log_level`, then restart amavis service. + +``` +$log_level = 5; # verbosity 0..5, -d +``` + +If you want to debug SpamAssassin, please update `$sa_debug` also: + +``` +$sa_debug = 1; +``` diff --git a/9-troubleshooting/turn.on.debug.mode.in.openldap.md b/9-troubleshooting/turn.on.debug.mode.in.openldap.md new file mode 100644 index 00000000..d39356ee --- /dev/null +++ b/9-troubleshooting/turn.on.debug.mode.in.openldap.md @@ -0,0 +1,12 @@ +# How to turn on debug mode in OpenLDAP + +In OpenLDAP config file `slapd.conf`, update parameter `loglevel` to value `256`, then restart OpenLDAP service. + * On RHEL/CentOS and OpenBSD, it's `/etc/openldap/slapd.conf` + * On Debian/Ubuntu, it's `/etc/ldap/slapd.conf` + * On FreeBSD, it's `/usr/local/etc/openldap/slapd.conf` + +
+loglevel 256 ++ +OpenLDAP is configured by iRedMail to log into `/var/log/openldap.log` by default. diff --git a/99-faq/ldap.add.alias.domain.md b/99-faq/ldap.add.alias.domain.md new file mode 100644 index 00000000..2c267cd3 --- /dev/null +++ b/99-faq/ldap.add.alias.domain.md @@ -0,0 +1,43 @@ +# How to add an alias domain name (LDAP backend) + +## What an alias domain is used for? + +Let's say you have a mail domain `example.com` hosted on your iRedMail server, +if you add domain name `domain.ltd` as an alias domain of `example.com`, all +emails sent to `username@domain.ltd` will be delivered to user +`username@example.com`'s mailbox. + +## Add alias domain with iRedAdmin-Pro + +With iRedAdmin-Pro, you can simply add alias domain name in domain profile page, +under tab `Aliases`. Screenshot:
+``` dn: mail=demolist@demo.iredmail.org,ou=Groups,domainName=demo.iredmail.org,o=domains,dc=iredmail,dc=org accountStatus: active cn: demolist @@ -15,7 +23,7 @@ enabledService: deliver enabledService: displayedInGlobalAddressBook mail: demolist@demo.iredmail.org objectClass: mailList -+``` Now switch to `ou=Users` under you domain LDAP dn in left panel. @@ -34,7 +42,8 @@ Now switch to `ou=Users` under you domain LDAP dn in left panel. You can add as many `memberOfGroup=xxx` as you want, which means this user is assigned to many mail lists. Here's sample to add external users as mail list members: -
+ +``` dn: memberOfGroup=demolist@demo.iredmail.org,ou=Externals,domainName=demo.iredmail.org,o=domains,dc=iredmail,dc=org accountstatus: active enabledservice: mail @@ -43,18 +52,34 @@ mail: user01@external.com mail: user02@external.com memberofgroup: demolist@demo.iredmail.org objectclass: mailExternalUser -+``` __IMPORTANT NOTE__: If you don't have any mail list member, Postfix will report error like below: -
+ +``` Aug 1 15:45:42 mail postfix/smtpd[6024]: NOQUEUE: reject: RCPT from unknown[1.1.1.1]: 550 5.1.1+``` -__Note:__ You can restrict who can send email to this mailing list by adding LDAP attribute `accessPolicy`. For example: -: Recipient address rejected: User unknown in virtual mailbox table; from= to= proto=ESMTP helo=<[2.2.2.2]> -
+## Mail list access policies + +You can restrict who can send email to this mailing list by adding LDAP attribute `accessPolicy`. For example: + +``` dn: mail=demolist@demo.iredmail.org,ou=Groups,domainName=demo.iredmail.org,o=domains,dc=iredmail,dc=org accesspolicy: domain --Available access policies are listed here (public, domain, subdomain, membersOnly, moderatorsOnly, memebersAndModeratorsOnly):
Let's say you have a mail domain example.com
hosted on your iRedMail server,
+if you add domain name domain.ltd
as an alias domain of example.com
, all
+emails sent to username@domain.ltd
will be delivered to user
+username@example.com
's mailbox.
With iRedAdmin-Pro, you can simply add alias domain name in domain profile page,
+under tab Aliases
. Screenshot: http://www.iredmail.org/images/iredadmin/domain_profile_alias.png
Login to phpLDAPadmin (https://[your_server]/phpldapadmin
) as LDAP root dn
+(cn=Manager,dc=xx,dc=xx
)
Find the LDAP object of your mail domain which you want to add alias +domain in left panel of phpLDAPadmin, click the ldap object, phpLDAPadmin will +show detailed LDAP attributes/values of this domain in right panel.
+Add a new LDAP attribute domainAliasName
to this domain account, set value
+to the alias domain (e.g. domain.com
). Save your change.
Now you should add addition mail address for all mail users, lists, aliases.
+For example, if you have mail user user@example.com
, you should add addition
+email address user@domain.ltd
for this user. Steps:
Find the LDAP object of mail account which you want to add addition email
+address in left panel of phpLDAPadmin, for example, user user@example.com
,
+click the ldap object, phpLDAPadmin will show detailed LDAP attributes/values
+in right panel.
Add a new LDAP attribute shadowAddress
to this mail account, set value to
+user@domain.ltd
. WARNING: You must user the same username part as
+original email address.
Save your change.
+If you have several mail accounts (mail users, lists, aliases), you have to +add addition email address for them all.